From c2ef41c822860c4989a7429b8db62e52387e6738 Mon Sep 17 00:00:00 2001 From: Kemal Hadimli Date: Mon, 16 Feb 2026 13:09:06 +0000 Subject: [PATCH 1/4] update spec for platform v2 --- .github/workflows/gen-client.yml | 2 +- client.gen.go | 41430 ++++++++++------------------- spec.json | 19776 ++++++-------- 3 files changed, 22204 insertions(+), 39004 deletions(-) diff --git a/.github/workflows/gen-client.yml b/.github/workflows/gen-client.yml index 5fce9ec..d64ec72 100644 --- a/.github/workflows/gen-client.yml +++ b/.github/workflows/gen-client.yml @@ -14,7 +14,7 @@ jobs: - name: Get Specs File run: | - curl -H "Authorization: token ${{ secrets.GH_CQ_BOT }}" https://raw.githubusercontent.com/cloudquery/cloud/main/platform/internal/servergen/spec.json -o spec.json + curl -H "Authorization: token ${{ secrets.GH_CQ_BOT }}" https://raw.githubusercontent.com/cloudquery/platform/main/platform/api/servergen/spec.json -o spec.json - name: Set up Go 1.x uses: actions/setup-go@v6 diff --git a/client.gen.go b/client.gen.go index e1c2e1f..cf18fd5 100644 --- a/client.gen.go +++ b/client.gen.go @@ -21,26 +21,16 @@ import ( ) const ( - BasicAuthScopes = "basicAuth.Scopes" BearerAuthScopes = "bearerAuth.Scopes" CookieAuthScopes = "cookieAuth.Scopes" ) -// Defines values for APIKeyRole. -const ( - APIKeyRoleAdminRead APIKeyRole = "admin:read" - APIKeyRoleAdminWrite APIKeyRole = "admin:write" - APIKeyRoleCi APIKeyRole = "ci" - APIKeyRoleGeneralRead APIKeyRole = "general:read" - APIKeyRoleGeneralWrite APIKeyRole = "general:write" - APIKeyRoleSchemaOnly APIKeyRole = "schema-only" -) - // Defines values for AlertSeverity. const ( - AlertSeverityHigh AlertSeverity = "high" - AlertSeverityLow AlertSeverity = "low" - AlertSeverityMedium AlertSeverity = "medium" + AlertSeverityCritical AlertSeverity = "critical" + AlertSeverityHigh AlertSeverity = "high" + AlertSeverityLow AlertSeverity = "low" + AlertSeverityMedium AlertSeverity = "medium" ) // Defines values for AlertState. @@ -51,27 +41,6 @@ const ( AlertStateUnknown AlertState = "unknown" ) -// Defines values for AssetViewRunType. -const ( - AssetViewRunTypeClientTable AssetViewRunType = "client_table" - AssetViewRunTypeS3Source AssetViewRunType = "s3_source" -) - -// Defines values for ConnectorStatus. -const ( - ConnectorStatusAuthenticated ConnectorStatus = "authenticated" - ConnectorStatusCreated ConnectorStatus = "created" - ConnectorStatusFailed ConnectorStatus = "failed" - ConnectorStatusRevoked ConnectorStatus = "revoked" -) - -// Defines values for ContentType. -const ( - ContentTypeImagejpeg ContentType = "image/jpeg" - ContentTypeImagepng ContentType = "image/png" - ContentTypeImagewebp ContentType = "image/webp" -) - // Defines values for ConversationCreateMode. const ( ConversationCreateModeAsk ConversationCreateMode = "ask" @@ -105,29 +74,16 @@ const ( ConversationSendMessageModeSql ConversationSendMessageMode = "sql" ) -// Defines values for CustomColumnColumnType. -const ( - CustomColumnColumnTypeBoolean CustomColumnColumnType = "Boolean" - CustomColumnColumnTypeDateTime CustomColumnColumnType = "DateTime" - CustomColumnColumnTypeFloat CustomColumnColumnType = "Float" - CustomColumnColumnTypeInteger CustomColumnColumnType = "Integer" - CustomColumnColumnTypeString CustomColumnColumnType = "String" -) - // Defines values for CustomColumnSortBy. const ( CustomColumnSortByColumnName CustomColumnSortBy = "column_name" - CustomColumnSortByColumnType CustomColumnSortBy = "column_type" CustomColumnSortByCreatedAt CustomColumnSortBy = "created_at" CustomColumnSortByCreatedBy CustomColumnSortBy = "created_by" CustomColumnSortByDescription CustomColumnSortBy = "description" CustomColumnSortById CustomColumnSortBy = "id" CustomColumnSortByLabel CustomColumnSortBy = "label" - CustomColumnSortByTableName CustomColumnSortBy = "table_name" - CustomColumnSortByTeamName CustomColumnSortBy = "team_name" CustomColumnSortByUpdatedAt CustomColumnSortBy = "updated_at" CustomColumnSortByValueExpr CustomColumnSortBy = "value_expr" - CustomColumnSortByValueType CustomColumnSortBy = "value_type" ) // Defines values for CustomColumnSortDirection. @@ -136,91 +92,35 @@ const ( CustomColumnSortDirectionDesc CustomColumnSortDirection = "desc" ) -// Defines values for CustomColumnValueType. -const ( - CustomColumnValueTypeExpression CustomColumnValueType = "expression" - CustomColumnValueTypeExternal CustomColumnValueType = "external" -) - -// Defines values for LocalUserProvider. +// Defines values for NotificationDestinationType. const ( - LocalUserProviderLocal LocalUserProvider = "local" - LocalUserProviderSaml LocalUserProvider = "saml" + NotificationDestinationTypeSlack NotificationDestinationType = "slack" + NotificationDestinationTypeWebhook NotificationDestinationType = "webhook" ) -// Defines values for OnboardingAWSAccountsType. -const ( - OnboardingAWSAccountsTypeAccount OnboardingAWSAccountsType = "account" - OnboardingAWSAccountsTypeOU OnboardingAWSAccountsType = "OU" - OnboardingAWSAccountsTypeRoot OnboardingAWSAccountsType = "root" -) - -// Defines values for PlatformCreateOrUpdatePolicyStatus. -const ( - PlatformCreateOrUpdatePolicyStatusActive PlatformCreateOrUpdatePolicyStatus = "active" - PlatformCreateOrUpdatePolicyStatusPaused PlatformCreateOrUpdatePolicyStatus = "paused" -) - -// Defines values for PlatformPolicyStatus. +// Defines values for NotificationDestinationCreateType. const ( - PlatformPolicyStatusActive PlatformPolicyStatus = "active" - PlatformPolicyStatusPaused PlatformPolicyStatus = "paused" + NotificationDestinationCreateTypeSlack NotificationDestinationCreateType = "slack" + NotificationDestinationCreateTypeWebhook NotificationDestinationCreateType = "webhook" ) -// Defines values for PlatformPolicyFrameworkSortBy. +// Defines values for NotificationDestinationDataType. const ( - PlatformPolicyFrameworkSortByDescription PlatformPolicyFrameworkSortBy = "description" - PlatformPolicyFrameworkSortById PlatformPolicyFrameworkSortBy = "id" - PlatformPolicyFrameworkSortByLabel PlatformPolicyFrameworkSortBy = "label" + NotificationDestinationDataTypeSlack NotificationDestinationDataType = "slack" + NotificationDestinationDataTypeWebhook NotificationDestinationDataType = "webhook" ) -// Defines values for PlatformPolicyRuleRisk. +// Defines values for NotificationDestinationListItemType. const ( - PlatformPolicyRuleRiskCritical PlatformPolicyRuleRisk = "critical" - PlatformPolicyRuleRiskHigh PlatformPolicyRuleRisk = "high" - PlatformPolicyRuleRiskLow PlatformPolicyRuleRisk = "low" - PlatformPolicyRuleRiskMedium PlatformPolicyRuleRisk = "medium" + NotificationDestinationListItemTypeSlack NotificationDestinationListItemType = "slack" + NotificationDestinationListItemTypeWebhook NotificationDestinationListItemType = "webhook" ) -// Defines values for PlatformPolicyRuleDetailSortBy. -const ( - PlatformPolicyRuleDetailSortByAccount PlatformPolicyRuleDetailSortBy = "account" - PlatformPolicyRuleDetailSortByCloud PlatformPolicyRuleDetailSortBy = "cloud" - PlatformPolicyRuleDetailSortByName PlatformPolicyRuleDetailSortBy = "name" - PlatformPolicyRuleDetailSortByRegion PlatformPolicyRuleDetailSortBy = "region" - PlatformPolicyRuleDetailSortByTags PlatformPolicyRuleDetailSortBy = "tags" -) - -// Defines values for PlatformPolicyRuleSortBy. -const ( - PlatformPolicyRuleSortByCategory PlatformPolicyRuleSortBy = "category" - PlatformPolicyRuleSortByDescription PlatformPolicyRuleSortBy = "description" - PlatformPolicyRuleSortByFrameworkId PlatformPolicyRuleSortBy = "framework_id" - PlatformPolicyRuleSortById PlatformPolicyRuleSortBy = "id" - PlatformPolicyRuleSortByName PlatformPolicyRuleSortBy = "name" - PlatformPolicyRuleSortByRisk PlatformPolicyRuleSortBy = "risk" - PlatformPolicyRuleSortByVersion PlatformPolicyRuleSortBy = "version" - PlatformPolicyRuleSortByViolations PlatformPolicyRuleSortBy = "violations" -) - -// Defines values for PlatformPolicySortBy. -const ( - PlatformPolicySortByCreatedAt PlatformPolicySortBy = "created_at" - PlatformPolicySortByCreatedBy PlatformPolicySortBy = "created_by" - PlatformPolicySortByDescription PlatformPolicySortBy = "description" - PlatformPolicySortByEvaluatedResources PlatformPolicySortBy = "evaluated_resources" - PlatformPolicySortByFilterId PlatformPolicySortBy = "filter_id" - PlatformPolicySortById PlatformPolicySortBy = "id" - PlatformPolicySortByName PlatformPolicySortBy = "name" - PlatformPolicySortByRuleViolations PlatformPolicySortBy = "rule_violations" - PlatformPolicySortByStatus PlatformPolicySortBy = "status" - PlatformPolicySortByUpdatedAt PlatformPolicySortBy = "updated_at" -) - -// Defines values for PlatformPolicySortDirection. +// Defines values for OnboardingAWSAccountsType. const ( - PlatformPolicySortDirectionAsc PlatformPolicySortDirection = "asc" - PlatformPolicySortDirectionDesc PlatformPolicySortDirection = "desc" + OnboardingAWSAccountsTypeAccount OnboardingAWSAccountsType = "account" + OnboardingAWSAccountsTypeOU OnboardingAWSAccountsType = "OU" + OnboardingAWSAccountsTypeRoot OnboardingAWSAccountsType = "root" ) // Defines values for PluginCategory. @@ -271,34 +171,34 @@ const ( PluginReleaseStagePreview PluginReleaseStage = "preview" ) -// Defines values for PluginReleaseStageCreate. +// Defines values for PluginTier. const ( - PluginReleaseStageCreateComingSoon PluginReleaseStageCreate = "coming-soon" - PluginReleaseStageCreateGa PluginReleaseStageCreate = "ga" - PluginReleaseStageCreatePreview PluginReleaseStageCreate = "preview" + PluginTierFree PluginTier = "free" + PluginTierOpenCore PluginTier = "open-core" + PluginTierPaid PluginTier = "paid" ) -// Defines values for PluginReleaseStageUpdate. +// Defines values for PolicyDomain. const ( - PluginReleaseStageUpdateComingSoon PluginReleaseStageUpdate = "coming-soon" - PluginReleaseStageUpdateDeprecated PluginReleaseStageUpdate = "deprecated" - PluginReleaseStageUpdateGa PluginReleaseStageUpdate = "ga" - PluginReleaseStageUpdatePreview PluginReleaseStageUpdate = "preview" + PolicyDomainCompliance PolicyDomain = "compliance" + PolicyDomainFinops PolicyDomain = "finops" + PolicyDomainGovernance PolicyDomain = "governance" + PolicyDomainOperations PolicyDomain = "operations" + PolicyDomainSecurity PolicyDomain = "security" ) -// Defines values for PluginTier. +// Defines values for PolicySeverity. const ( - PluginTierFree PluginTier = "free" - PluginTierOpenCore PluginTier = "open-core" - PluginTierPaid PluginTier = "paid" + PolicySeverityCritical PolicySeverity = "critical" + PolicySeverityHigh PolicySeverity = "high" + PolicySeverityLow PolicySeverity = "low" + PolicySeverityMedium PolicySeverity = "medium" ) -// Defines values for RBACDefaultRole. +// Defines values for PolicyStatus. const ( - RBACDefaultRoleAdminRead RBACDefaultRole = "admin:read" - RBACDefaultRoleAdminWrite RBACDefaultRole = "admin:write" - RBACDefaultRoleGeneralRead RBACDefaultRole = "general:read" - RBACDefaultRoleGeneralWrite RBACDefaultRole = "general:write" + PolicyStatusActive PolicyStatus = "active" + PolicyStatusPaused PolicyStatus = "paused" ) // Defines values for RBACPermissionSortBy. @@ -365,6 +265,17 @@ const ( ReportTemplateSortDirectionDesc ReportTemplateSortDirection = "desc" ) +// Defines values for RoleType. +const ( + RoleTypeAdminRead RoleType = "admin:read" + RoleTypeAdminWrite RoleType = "admin:write" + RoleTypeCI RoleType = "ci" + RoleTypeCustom RoleType = "custom" + RoleTypeGeneralRead RoleType = "general:read" + RoleTypeGeneralWrite RoleType = "general:write" + RoleTypeSchemaOnly RoleType = "schema-only" +) + // Defines values for SyncDestinationMigrateMode. const ( SyncDestinationMigrateModeForced SyncDestinationMigrateMode = "forced" @@ -420,9 +331,20 @@ const ( // Defines values for SyncRunStatusReason. const ( - SyncRunStatusReasonError SyncRunStatusReason = "error" - SyncRunStatusReasonOomKilled SyncRunStatusReason = "oom_killed" - SyncRunStatusReasonPartialSuccess SyncRunStatusReason = "partial_success" + SyncRunStatusReasonError SyncRunStatusReason = "error" + SyncRunStatusReasonIngestionFailed SyncRunStatusReason = "ingestion_failed" + SyncRunStatusReasonOomKilled SyncRunStatusReason = "oom_killed" + SyncRunStatusReasonPartialSuccess SyncRunStatusReason = "partial_success" +) + +// Defines values for SyncRunTableSortBy. +const ( + SyncRunTableSortByCompletedAt SyncRunTableSortBy = "completed_at" + SyncRunTableSortByErrors SyncRunTableSortBy = "errors" + SyncRunTableSortByName SyncRunTableSortBy = "name" + SyncRunTableSortByResources SyncRunTableSortBy = "resources" + SyncRunTableSortByRuntimeSeconds SyncRunTableSortBy = "runtime_seconds" + SyncRunTableSortByStartedAt SyncRunTableSortBy = "started_at" ) // Defines values for SyncRunWorkerPhase. @@ -471,6 +393,11 @@ const ( SyncTestConnectionStatusStarted SyncTestConnectionStatus = "started" ) +// Defines values for TableDataActionAction. +const ( + TableDataActionActionDelete TableDataActionAction = "delete" +) + // Defines values for TableSchemaColumnKind. const ( TableSchemaColumnKindAny TableSchemaColumnKind = "any" @@ -493,14 +420,6 @@ const ( TableSortDirectionDesc TableSortDirection = "desc" ) -// Defines values for TeamPlan. -const ( - TeamPlanEnterprise TeamPlan = "enterprise" - TeamPlanFree TeamPlan = "free" - TeamPlanPaid TeamPlan = "paid" - TeamPlanTrial TeamPlan = "trial" -) - // Defines values for UsageSummaryMetadataAggregationPeriod. const ( UsageSummaryMetadataAggregationPeriodDay UsageSummaryMetadataAggregationPeriod = "day" @@ -515,6 +434,12 @@ const ( UsageSummaryMetadataMetricsPaidRows UsageSummaryMetadataMetrics = "paid_rows" ) +// Defines values for UserProvider. +const ( + UserProviderLocal UserProvider = "local" + UserProviderSaml UserProvider = "saml" +) + // Defines values for PluginSortBy. const ( PluginSortByCreatedAt PluginSortBy = "created_at" @@ -535,18 +460,6 @@ const ( VersionSortByCreatedAt VersionSortBy = "created_at" ) -// Defines values for AddLocalUserJSONBodyRoles. -const ( - AddLocalUserJSONBodyRolesAdminRead AddLocalUserJSONBodyRoles = "admin:read" - AddLocalUserJSONBodyRolesAdminWrite AddLocalUserJSONBodyRoles = "admin:write" -) - -// Defines values for UpdateLocalUserJSONBodyRoles. -const ( - UpdateLocalUserJSONBodyRolesAdminRead UpdateLocalUserJSONBodyRoles = "admin:read" - UpdateLocalUserJSONBodyRolesAdminWrite UpdateLocalUserJSONBodyRoles = "admin:write" -) - // Defines values for ListPluginsParamsSortBy. const ( ListPluginsParamsSortByCreatedAt ListPluginsParamsSortBy = "created_at" @@ -560,24 +473,46 @@ const ( ListPluginVersionsParamsSortByCreatedAt ListPluginVersionsParamsSortBy = "created_at" ) -// Defines values for TogglePolicyParamsStatus. +// Defines values for ListPoliciesParamsSortBy. +const ( + ListPoliciesParamsSortByCreatedAt ListPoliciesParamsSortBy = "created_at" + ListPoliciesParamsSortByDomain ListPoliciesParamsSortBy = "domain" + ListPoliciesParamsSortByLastRunAt ListPoliciesParamsSortBy = "last_run_at" + ListPoliciesParamsSortByName ListPoliciesParamsSortBy = "name" + ListPoliciesParamsSortBySeverity ListPoliciesParamsSortBy = "severity" + ListPoliciesParamsSortByViolationCount ListPoliciesParamsSortBy = "violation_count" +) + +// Defines values for ListPoliciesParamsSortDir. +const ( + ListPoliciesParamsSortDirAsc ListPoliciesParamsSortDir = "asc" + ListPoliciesParamsSortDirDesc ListPoliciesParamsSortDir = "desc" +) + +// Defines values for ListPoliciesInGroupParamsSortBy. const ( - TogglePolicyParamsStatusActive TogglePolicyParamsStatus = "active" - TogglePolicyParamsStatusPaused TogglePolicyParamsStatus = "paused" + ListPoliciesInGroupParamsSortByName ListPoliciesInGroupParamsSortBy = "name" + ListPoliciesInGroupParamsSortByPolicyCount ListPoliciesInGroupParamsSortBy = "policy_count" ) -// Defines values for ExecuteAdHocQueryTeamParamsFilterMode. +// Defines values for ListPoliciesInGroupParamsSortDir. const ( - ExecuteAdHocQueryTeamParamsFilterModeColumn ExecuteAdHocQueryTeamParamsFilterMode = "column" - ExecuteAdHocQueryTeamParamsFilterModeSearch ExecuteAdHocQueryTeamParamsFilterMode = "search" - ExecuteAdHocQueryTeamParamsFilterModeSmart ExecuteAdHocQueryTeamParamsFilterMode = "smart" + ListPoliciesInGroupParamsSortDirAsc ListPoliciesInGroupParamsSortDir = "asc" + ListPoliciesInGroupParamsSortDirDesc ListPoliciesInGroupParamsSortDir = "desc" ) -// Defines values for ExecuteSavedQueryTeamParamsFilterMode. +// Defines values for ExecuteAdHocQueryParamsFilterMode. const ( - ExecuteSavedQueryTeamParamsFilterModeColumn ExecuteSavedQueryTeamParamsFilterMode = "column" - ExecuteSavedQueryTeamParamsFilterModeSearch ExecuteSavedQueryTeamParamsFilterMode = "search" - ExecuteSavedQueryTeamParamsFilterModeSmart ExecuteSavedQueryTeamParamsFilterMode = "smart" + ExecuteAdHocQueryParamsFilterModeColumn ExecuteAdHocQueryParamsFilterMode = "column" + ExecuteAdHocQueryParamsFilterModeSearch ExecuteAdHocQueryParamsFilterMode = "search" + ExecuteAdHocQueryParamsFilterModeSmart ExecuteAdHocQueryParamsFilterMode = "smart" +) + +// Defines values for ExecuteSavedQueryParamsFilterMode. +const ( + ExecuteSavedQueryParamsFilterModeColumn ExecuteSavedQueryParamsFilterMode = "column" + ExecuteSavedQueryParamsFilterModeSearch ExecuteSavedQueryParamsFilterMode = "search" + ExecuteSavedQueryParamsFilterModeSmart ExecuteSavedQueryParamsFilterMode = "smart" ) // Defines values for ListReportsParamsVisibility. @@ -595,32 +530,32 @@ const ( ListSyncUpgradesParamsSortByPrevVersion ListSyncUpgradesParamsSortBy = "prev_version" ) -// Defines values for TableListColumnsTeamParamsFilterMode. +// Defines values for TableListColumnsParamsFilterMode. const ( - TableListColumnsTeamParamsFilterModeColumn TableListColumnsTeamParamsFilterMode = "column" - TableListColumnsTeamParamsFilterModeSearch TableListColumnsTeamParamsFilterMode = "search" - TableListColumnsTeamParamsFilterModeSmart TableListColumnsTeamParamsFilterMode = "smart" + TableListColumnsParamsFilterModeColumn TableListColumnsParamsFilterMode = "column" + TableListColumnsParamsFilterModeSearch TableListColumnsParamsFilterMode = "search" + TableListColumnsParamsFilterModeSmart TableListColumnsParamsFilterMode = "smart" ) -// Defines values for TableColumnListValuesTeamParamsFilterMode. +// Defines values for TableColumnListValuesParamsFilterMode. const ( - TableColumnListValuesTeamParamsFilterModeColumn TableColumnListValuesTeamParamsFilterMode = "column" - TableColumnListValuesTeamParamsFilterModeSearch TableColumnListValuesTeamParamsFilterMode = "search" - TableColumnListValuesTeamParamsFilterModeSmart TableColumnListValuesTeamParamsFilterMode = "smart" + TableColumnListValuesParamsFilterModeColumn TableColumnListValuesParamsFilterMode = "column" + TableColumnListValuesParamsFilterModeSearch TableColumnListValuesParamsFilterMode = "search" + TableColumnListValuesParamsFilterModeSmart TableColumnListValuesParamsFilterMode = "smart" ) -// Defines values for TableListRowsTeamParamsFilterMode. +// Defines values for TableListRowsParamsFilterMode. const ( - TableListRowsTeamParamsFilterModeColumn TableListRowsTeamParamsFilterMode = "column" - TableListRowsTeamParamsFilterModeSearch TableListRowsTeamParamsFilterMode = "search" - TableListRowsTeamParamsFilterModeSmart TableListRowsTeamParamsFilterMode = "smart" + TableListRowsParamsFilterModeColumn TableListRowsParamsFilterMode = "column" + TableListRowsParamsFilterModeSearch TableListRowsParamsFilterMode = "search" + TableListRowsParamsFilterModeSmart TableListRowsParamsFilterMode = "smart" ) -// Defines values for TableRowByIdTeamParamsFilterMode. +// Defines values for TableRowByIdParamsFilterMode. const ( - TableRowByIdTeamParamsFilterModeColumn TableRowByIdTeamParamsFilterMode = "column" - TableRowByIdTeamParamsFilterModeSearch TableRowByIdTeamParamsFilterMode = "search" - TableRowByIdTeamParamsFilterModeSmart TableRowByIdTeamParamsFilterMode = "smart" + TableRowByIdParamsFilterModeColumn TableRowByIdParamsFilterMode = "column" + TableRowByIdParamsFilterModeSearch TableRowByIdParamsFilterMode = "search" + TableRowByIdParamsFilterModeSmart TableRowByIdParamsFilterMode = "smart" ) // Defines values for GetTeamUsageSummaryParamsMetrics. @@ -658,7 +593,7 @@ const ( GetGroupedTeamUsageSummaryParamsGroupBySyncId GetGroupedTeamUsageSummaryParamsGroupBy = "sync_id" ) -// APIKey API Key to interact with CloudQuery Cloud under specific team +// APIKey API Key to interact with CloudQuery Platform type APIKey struct { CreatedAt *time.Time `json:"created_at,omitempty"` @@ -681,8 +616,8 @@ type APIKey struct { LastAccessAt *time.Time `json:"last_access_at,omitempty"` // Name Name of the API key - Name APIKeyName `json:"name"` - Roles []APIKeyTeamRole `json:"roles"` + Name APIKeyName `json:"name"` + Roles []Role `json:"roles"` } // APIKeyID ID of the API key @@ -691,17 +626,6 @@ type APIKeyID = openapi_types.UUID // APIKeyName Name of the API key type APIKeyName = string -// APIKeyRole defines model for APIKeyRole. -type APIKeyRole string - -// APIKeyTeamRole defines model for APIKeyTeamRole. -type APIKeyTeamRole struct { - Role APIKeyRole `json:"role"` - - // Team The unique name for the team. - Team *TeamName `json:"team,omitempty"` -} - // Alert An alert instance that can be triggered by a query type Alert struct { // CreatedAt Timestamp when the alert was created @@ -812,30 +736,6 @@ type AlertUpdate struct { Severity *AlertSeverity `json:"severity,omitempty"` } -// AssetViewRun defines model for AssetViewRun. -type AssetViewRun struct { - // CreatedAt The time the run was created - CreatedAt time.Time `json:"created_at"` - - // ErrorMessage The error message if the run failed - ErrorMessage *string `json:"error_message,omitempty"` - - // FinishedAt The time the run was finished - FinishedAt *time.Time `json:"finished_at,omitempty"` - - // ID ID of the run - ID openapi_types.UUID `json:"id"` - - // TriggeredBy The user who triggered the run - TriggeredBy *string `json:"triggered_by,omitempty"` - - // Type Type of assetview run - Type AssetViewRunType `json:"type"` -} - -// AssetViewRunType Type of assetview run -type AssetViewRunType string - // AuditLogEvent defines model for AuditLogEvent. type AuditLogEvent struct { // CreatedAt The timestamp when the event was created @@ -856,10 +756,7 @@ type AuditLogEvent struct { // IsSuccess Whether the event was successful IsSuccess *bool `json:"is_success,omitempty"` - // TeamName The name of the team associated with the event - TeamName *string `json:"team_name"` - - // User CloudQuery User + // User User User User `json:"user"` // UserIpAddress The IP address of the user who performed the action @@ -904,193 +801,6 @@ type CompletedSingleAccountNotification struct { SyncRoleArn string `json:"sync_role_arn"` } -// Connector Connector definition -type Connector struct { - // CreatedAt Time the connector was created - CreatedAt time.Time `json:"created_at"` - - // ID unique ID of the connector - ID openapi_types.UUID `json:"id"` - - // Name Name of the connector - Name string `json:"name"` - - // Status The status of the connector - Status ConnectorStatus `json:"status"` - - // Type Type of the connector - Type string `json:"type"` -} - -// ConnectorAuthFinishRequestAWS AWS connector authentication request, filled in after the user has authenticated through AWS -type ConnectorAuthFinishRequestAWS struct { - // ExternalID External ID in the role definition. Optional. If not provided the previously suggested external ID will be used. Empty string will remove the external ID. - ExternalID *string `json:"external_id,omitempty"` - - // RoleARN ARN of role created by the user - RoleARN string `json:"role_arn"` -} - -// ConnectorAuthFinishRequestOAuth OAuth connector authentication request, filled in after the user has authenticated through OAuth -type ConnectorAuthFinishRequestOAuth struct { - // BaseURL Base of the URL the callback url was constructed from - BaseURL string `json:"base_url"` - - // Env Environment variables used in the spec. - Env *[]SyncEnvCreate `json:"env,omitempty"` - - // ReturnURL URL the user was redirected to (including new parameter values) after the OAuth flow is complete - ReturnURL string `json:"return_url"` - Spec *map[string]interface{} `json:"spec,omitempty"` -} - -// ConnectorAuthRequestAWS AWS connector authentication request to start the authentication process -type ConnectorAuthRequestAWS struct { - // Env Environment variables used in the spec. - Env *[]SyncEnvCreate `json:"env,omitempty"` - - // PluginKind Kind of the plugin - PluginKind string `json:"plugin_kind"` - - // PluginName Name of the plugin - PluginName string `json:"plugin_name"` - - // PluginTeam Team that owns the plugin we are authenticating the connector for - PluginTeam string `json:"plugin_team"` - - // PluginVersion Version of the plugin - PluginVersion *string `json:"plugin_version,omitempty"` - - // SkipDependentTables Whether to skip dependent tables, setting from the outer spec - SkipDependentTables *bool `json:"skip_dependent_tables,omitempty"` - - // SkipTables Tables to skip authentication, setting from the outer spec - SkipTables *[]string `json:"skip_tables,omitempty"` - Spec *map[string]interface{} `json:"spec,omitempty"` - - // Tables Tables to authenticate, setting from the outer spec - Tables *[]string `json:"tables,omitempty"` -} - -// ConnectorAuthRequestGCP GCP connector authentication request to start the authentication process -type ConnectorAuthRequestGCP struct { - // PluginKind Kind of the plugin - PluginKind string `json:"plugin_kind"` - - // PluginName Name of the plugin - PluginName string `json:"plugin_name"` - - // PluginTeam Team that owns the plugin we are authenticating the connector for - PluginTeam string `json:"plugin_team"` -} - -// ConnectorAuthRequestOAuth OAuth connector authentication request to start the authentication process -type ConnectorAuthRequestOAuth struct { - // BaseURL Base of the URL the callback url will be constructed from - BaseURL string `json:"base_url"` - - // Env Environment variables used in the spec. - Env *[]SyncEnvCreate `json:"env,omitempty"` - - // Flavor Override default flavor - Flavor *string `json:"flavor,omitempty"` - - // PluginKind Kind of the plugin - PluginKind string `json:"plugin_kind"` - - // PluginName Name of the plugin - PluginName string `json:"plugin_name"` - - // PluginTeam Team that owns the plugin we are authenticating the connector for - PluginTeam string `json:"plugin_team"` - - // PluginVersion Version of the plugin - PluginVersion *string `json:"plugin_version,omitempty"` - - // SkipDependentTables Whether to skip dependent tables, setting from the outer spec - SkipDependentTables *bool `json:"skip_dependent_tables,omitempty"` - - // SkipTables Tables to skip authentication, setting from the outer spec - SkipTables *[]string `json:"skip_tables,omitempty"` - Spec *map[string]interface{} `json:"spec,omitempty"` - - // Tables Tables to authenticate, setting from the outer spec - Tables *[]string `json:"tables,omitempty"` -} - -// ConnectorAuthResponseAWS AWS connector authentication response to start the authentication process -type ConnectorAuthResponseAWS struct { - // RedirectURL URL to redirect the user to, to authenticate - RedirectURL string `json:"redirect_url"` - - // RoleTemplateURL URL to the role template, to present to the user - RoleTemplateURL string `json:"role_template_url"` - - // SuggestedExternalID External ID suggested to enter into the role definition - SuggestedExternalID string `json:"suggested_external_id"` - - // SuggestedPolicyARNs List of AWS policy ARNs suggested to grant inside the role definition - SuggestedPolicyARNs []string `json:"suggested_policy_arns"` -} - -// ConnectorAuthResponseGCP GCP connector authentication response to start the authentication process -type ConnectorAuthResponseGCP struct { - // ServiceAccount CloudQuery GCP Service Account to grant access to - ServiceAccount string `json:"service_account"` -} - -// ConnectorAuthResponseOAuth OAuth connector authentication response to start the authentication process -type ConnectorAuthResponseOAuth struct { - // RedirectURL URL to redirect the user to, to authenticate - RedirectURL string `json:"redirect_url"` -} - -// ConnectorCreate Connector creation request -type ConnectorCreate struct { - // Name Name of the connector - Name string `json:"name"` - - // Type Type of the connector - Type string `json:"type"` -} - -// ConnectorCredentialsResponseAWS AWS connector credentials response -type ConnectorCredentialsResponseAWS struct { - AccessKeyId string `json:"access_key_id"` - CanExpire bool `json:"can_expire"` - Expires time.Time `json:"expires"` - SecretAccessKey string `json:"secret_access_key"` - SessionToken string `json:"session_token"` - Source string `json:"source"` -} - -// ConnectorCredentialsResponseOAuth OAuth connector credentials response -type ConnectorCredentialsResponseOAuth struct { - AccessToken string `json:"access_token"` - Expires *time.Time `json:"expires,omitempty"` -} - -// ConnectorID ID of the Connector -type ConnectorID = openapi_types.UUID - -// ConnectorIdentityResponseAWS AWS connector identity response -type ConnectorIdentityResponseAWS struct { - // RoleARN Role ARN to assume - RoleARN string `json:"role_arn"` -} - -// ConnectorStatus The status of the connector -type ConnectorStatus string - -// ConnectorUpdate defines model for ConnectorUpdate. -type ConnectorUpdate struct { - // Name Name of the connector - Name *string `json:"name,omitempty"` -} - -// ContentType The HTTP Content-Type of the image or asset -type ContentType string - // Conversation defines model for Conversation. type Conversation struct { CreatedAt time.Time `json:"created_at"` @@ -1170,9 +880,6 @@ type ConversationSendMessageMode string // CreateSyncDestinationTestConnectionV2 defines model for CreateSyncDestinationTestConnectionV2. type CreateSyncDestinationTestConnectionV2 struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // DestinationName Name of an existing destination DestinationName *string `json:"destination_name,omitempty"` @@ -1232,63 +939,32 @@ type CreatedBy struct { // CustomColumn A custom column that is configured manually by the user. type CustomColumn struct { - ColumnName string `json:"column_name"` - ColumnType *CustomColumnColumnType `json:"column_type,omitempty"` - CreatedAt time.Time `json:"created_at"` - CreatedBy CreatedBy `json:"created_by"` - Description *string `json:"description,omitempty"` + // ColumnName The name for the custom column. + ColumnName CustomColumnColumnName `json:"column_name"` + CreatedAt time.Time `json:"created_at"` + CreatedBy CreatedBy `json:"created_by"` + Description *string `json:"description,omitempty"` // CustomColumnID The unique ID for the custom column. CustomColumnID CustomColumnID `json:"id"` Label string `json:"label"` - // TableName Table this column applies to. - TableName string `json:"table_name"` - - // TeamName The unique name for the team. - TeamName TeamName `json:"team_name"` - - // ValueExpr Value expression. - // For value_type=expression, this is the actual SQL query. - // For value_type=external this is the default value. - ValueExpr *string `json:"value_expr,omitempty"` - ValueType CustomColumnValueType `json:"value_type"` + // ValueExpr The SQL expression for the custom column. + ValueExpr CustomColumnValueExpr `json:"value_expr"` } -// CustomColumnColumnType defines model for CustomColumnColumnType. -type CustomColumnColumnType string +// CustomColumnColumnName The name for the custom column. +type CustomColumnColumnName = string // CustomColumnCreateOrUpdate Create or update a custom column type CustomColumnCreateOrUpdate struct { - ColumnName string `json:"column_name"` - ColumnType *CustomColumnColumnType `json:"column_type,omitempty"` - Description *string `json:"description,omitempty"` - Label string `json:"label"` - - // TableName Table this column applies to. - TableName string `json:"table_name"` + // ColumnName The name for the custom column. + ColumnName CustomColumnColumnName `json:"column_name"` + Description *string `json:"description,omitempty"` + Label string `json:"label"` - // ValueExpr Value expression. - // For value_type=expression, this is the actual SQL query. - // For value_type=external this is the default value. - ValueExpr *string `json:"value_expr,omitempty"` - ValueType CustomColumnValueType `json:"value_type"` -} - -// CustomColumnDataImport Import data into the specified custom column -type CustomColumnDataImport struct { - Data []map[string]interface{} `json:"data"` -} - -// CustomColumnDataImportAccepted defines model for CustomColumnDataImportAccepted. -type CustomColumnDataImportAccepted struct { - // CreatedAt The time the data import was created - CreatedAt time.Time `json:"created_at"` -} - -// CustomColumnDataValues Edit one or more values within the specified custom column -type CustomColumnDataValues struct { - Data []map[string]interface{} `json:"data"` + // ValueExpr The SQL expression for the custom column. + ValueExpr CustomColumnValueExpr `json:"value_expr"` } // CustomColumnID The unique ID for the custom column. @@ -1300,8 +976,8 @@ type CustomColumnSortBy string // CustomColumnSortDirection defines model for CustomColumnSortDirection. type CustomColumnSortDirection string -// CustomColumnValueType defines model for CustomColumnValueType. -type CustomColumnValueType string +// CustomColumnValueExpr The SQL expression for the custom column. +type CustomColumnValueExpr = string // DeployedNotification defines model for DeployedNotification. type DeployedNotification struct { @@ -1314,14 +990,6 @@ type DeployedNotification struct { // DisplayName A human-readable display name type DisplayName = string -// DockerError Error Returned from the Docker Authorization Handler to the Docker Registry -type DockerError struct { - Details string `json:"details"` -} - -// Email defines model for Email. -type Email = openapi_types.Email - // FailedNotification defines model for FailedNotification. type FailedNotification struct { Reason string `json:"reason"` @@ -1367,7 +1035,7 @@ type FilterCreate struct { Expression FilterExpression `json:"expression"` Name string `json:"name"` - // Public Whether the filter is visible to all users in the team, or only to the user who created it + // Public Whether the filter is visible to all users, or only to the user who created it Public bool `json:"public"` Tags []FilterTag `json:"tags,omitempty"` } @@ -1391,38 +1059,6 @@ type FilterUpdate struct { Tags *[]FilterTag `json:"tags,omitempty"` } -// ImageURL defines model for ImageURL. -type ImageURL struct { - DownloadUrl string `json:"download_url"` - - // RequiredHeaders Required HTTP headers to include for the upload - RequiredHeaders map[string][]string `json:"required_headers"` - UploadUrl string `json:"upload_url"` -} - -// Invitation defines model for Invitation. -type Invitation struct { - CreatedAt time.Time `json:"created_at"` - Email Email `json:"email"` - Role string `json:"role"` - - // TeamName The unique name for the team. - TeamName TeamName `json:"team_name"` -} - -// InvitationWithToken defines model for InvitationWithToken. -type InvitationWithToken struct { - CreatedAt time.Time `json:"created_at"` - Email Email `json:"email"` - Role string `json:"role"` - - // TeamName The unique name for the team. - TeamName TeamName `json:"team_name"` - - // Token The token used to accept the invitation - Token openapi_types.UUID `json:"token"` -} - // ListMetadata defines model for ListMetadata. type ListMetadata struct { LastPage *int `json:"last_page,omitempty"` @@ -1458,9 +1094,6 @@ type ListPlugin struct { // Official True if the plugin is maintained by CloudQuery, false otherwise Official bool `json:"official"` - // PinnedVersion CloudQuery Pinned Plugin Version Info - PinnedVersion *ListPluginPinnedVersion `json:"pinned_version,omitempty"` - // PriceCategory Supported price categories for billing PriceCategory *PluginPriceCategory `json:"price_category,omitempty"` @@ -1493,23 +1126,6 @@ type ListPlugin struct { USDPerRow string `json:"usd_per_row"` } -// ListPluginPinnedVersion CloudQuery Pinned Plugin Version Info -type ListPluginPinnedVersion struct { - // Initialized Deprecated. Assume `true`. - // Deprecated: - Initialized bool `json:"initialized"` - - // Mirroring Deprecated. Assume `false`. - // Deprecated: - Mirroring bool `json:"mirroring"` - - // Name The version in semantic version format. - Name VersionName `json:"name"` - - // Range A version range in semantic version format. - Range VersionRange `json:"range"` -} - // ListPlugins defines model for ListPlugins. type ListPlugins = []ListPlugin @@ -1583,123 +1199,102 @@ type ListSyncLastRun struct { Warnings int64 `json:"warnings"` } -// LocalUser defines model for LocalUser. -type LocalUser struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - Email string `json:"email"` - Enabled bool `json:"enabled"` +// NotificationDestination Notification Destination +type NotificationDestination struct { + CreatedAt time.Time `json:"created_at"` - // ID ID of the User - ID openapi_types.UUID `json:"id"` - LastLoginAt *time.Time `json:"last_login_at,omitempty"` + // CustomMessage Optional custom message prepended to the alert when sending to Slack (only for slack type) + CustomMessage *string `json:"custom_message"` + Enabled bool `json:"enabled"` - // MFAConfigured Whether the user has MFA configured - MFAConfigured *bool `json:"mfa_configured,omitempty"` + // HTTPBody HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}. + HTTPBody *string `json:"http_body,omitempty"` + HTTPHeaders map[string]string `json:"http_headers,omitempty"` - // Name The unique name for the user. - Name *UserName `json:"name,omitempty"` + // NotificationDestinationID The unique ID for the notification destination. + NotificationDestinationID NotificationDestinationID `json:"id"` - // ProfileImageURL Profile image URL of user - ProfileImageURL *string `json:"profile_image_url,omitempty"` - Provider LocalUserProvider `json:"provider"` + // LastNotificationErrorCode Error code of the last notification error + LastNotificationErrorCode *string `json:"last_notification_error_code"` - // Roles Global roles for the user - Roles []string `json:"roles"` + // LastNotificationErrorMessage Error message of the last notification error + LastNotificationErrorMessage *string `json:"last_notification_error_message"` - // TrackingOptedIn Whether anonymous user tracking was opted into - TrackingOptedIn *bool `json:"tracking_opted_in,omitempty"` - UpdatedAt *time.Time `json:"updated_at,omitempty"` -} + // LastNotificationErrorTimestamp Timestamp of the last notification error + LastNotificationErrorTimestamp *time.Time `json:"last_notification_error_timestamp"` + Name string `json:"name"` -// LocalUserProvider defines model for LocalUserProvider. -type LocalUserProvider string + // SlackChannels List of Slack channel IDs (only for slack type) + SlackChannels *[]string `json:"slack_channels,omitempty"` -// LocalUserWithTeams defines model for LocalUserWithTeams. -type LocalUserWithTeams struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - Email string `json:"email"` - Enabled bool `json:"enabled"` - - // ID ID of the User - ID openapi_types.UUID `json:"id"` - LastLoginAt *time.Time `json:"last_login_at,omitempty"` + // SlackConnectionID Slack connection ID (only for slack type) + SlackConnectionID *openapi_types.UUID `json:"slack_connection_id"` - // MFAConfigured Whether the user has MFA configured - MFAConfigured *bool `json:"mfa_configured,omitempty"` + // Type Type of notification destination + Type NotificationDestinationType `json:"type"` + UpdatedAt time.Time `json:"updated_at"` + URL string `json:"url"` +} - // Name The unique name for the user. - Name *UserName `json:"name,omitempty"` +// NotificationDestinationType Type of notification destination +type NotificationDestinationType string - // ProfileImageURL Profile image URL of user - ProfileImageURL *string `json:"profile_image_url,omitempty"` - Provider LocalUserProvider `json:"provider"` +// NotificationDestinationCreate defines model for NotificationDestinationCreate. +type NotificationDestinationCreate struct { + // CustomMessage Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook) + CustomMessage *string `json:"custom_message,omitempty"` + Enabled bool `json:"enabled"` - // Roles Global roles for the user - Roles []string `json:"roles"` - Teams []MembershipWithTeamName `json:"teams"` + // HTTPBody HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}. + HTTPBody *string `json:"http_body,omitempty"` - // TrackingOptedIn Whether anonymous user tracking was opted into - TrackingOptedIn *bool `json:"tracking_opted_in,omitempty"` - UpdatedAt *time.Time `json:"updated_at,omitempty"` -} + // HTTPHeaders HTTP headers (required for webhook type, must not be set for slack type) + HTTPHeaders map[string]string `json:"http_headers,omitempty"` + Name string `json:"name"` -// MembershipWithTeam defines model for MembershipWithTeam. -type MembershipWithTeam struct { - Roles []string `json:"roles"` + // SlackChannels List of Slack channel IDs to send notifications to (required for slack type) + SlackChannels *[]string `json:"slack_channels,omitempty"` - // Team CloudQuery Team - Team Team `json:"team"` -} + // SlackConnectionID Slack connection ID (required for slack type) + SlackConnectionID *openapi_types.UUID `json:"slack_connection_id,omitempty"` -// MembershipWithTeamName defines model for MembershipWithTeamName. -type MembershipWithTeamName struct { - CreatedAt time.Time `json:"created_at"` - Roles []string `json:"roles"` + // Type Type of notification destination + Type *NotificationDestinationCreateType `json:"type,omitempty"` - // TeamName The unique name for the team. - TeamName TeamName `json:"team_name"` - UpdatedAt time.Time `json:"updated_at"` + // URL Webhook URL (required for webhook type, must not be set for slack type) + URL *string `json:"url,omitempty"` } -// MembershipWithUser defines model for MembershipWithUser. -type MembershipWithUser struct { - CustomRoles *[]RBACRole `json:"customRoles,omitempty"` - Roles []RBACDefaultRole `json:"roles"` +// NotificationDestinationCreateType Type of notification destination +type NotificationDestinationCreateType string - // User CloudQuery User - User User `json:"user"` -} +// NotificationDestinationData Notification Destination Data +type NotificationDestinationData struct { + // CustomMessage Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook) + CustomMessage *string `json:"custom_message,omitempty"` -// NotificationDestination Notification Destination -type NotificationDestination struct { - CreatedAt time.Time `json:"created_at"` - Enabled bool `json:"enabled"` - HTTPBody *string `json:"http_body,omitempty"` + // HTTPBody HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}. + HTTPBody *string `json:"http_body,omitempty"` + + // HTTPHeaders HTTP headers (required for webhook type, must not be set for slack type) HTTPHeaders map[string]string `json:"http_headers,omitempty"` - // NotificationDestinationID The unique ID for the notification destination. - NotificationDestinationID NotificationDestinationID `json:"id"` - Name string `json:"name"` - UpdatedAt time.Time `json:"updated_at"` - URL string `json:"url"` -} + // SlackChannels List of Slack channel IDs to send notifications to (required for slack type) + SlackChannels *[]string `json:"slack_channels,omitempty"` -// NotificationDestinationCreate defines model for NotificationDestinationCreate. -type NotificationDestinationCreate struct { - Enabled bool `json:"enabled"` - HTTPBody *string `json:"http_body,omitempty"` - HTTPHeaders map[string]string `json:"http_headers,omitempty"` - Name string `json:"name"` - URL string `json:"url"` -} + // SlackConnectionID Slack connection ID (required for slack type) + SlackConnectionID *openapi_types.UUID `json:"slack_connection_id,omitempty"` -// NotificationDestinationData Notification Destination Data -type NotificationDestinationData struct { - HTTPBody *string `json:"http_body,omitempty"` - HTTPHeaders map[string]string `json:"http_headers,omitempty"` - URL string `json:"url"` + // Type Type of notification destination + Type *NotificationDestinationDataType `json:"type,omitempty"` + + // URL Webhook URL (required for webhook type, must not be set for slack type) + URL *string `json:"url,omitempty"` } +// NotificationDestinationDataType Type of notification destination +type NotificationDestinationDataType string + // NotificationDestinationID The unique ID for the notification destination. type NotificationDestinationID = openapi_types.UUID @@ -1711,10 +1306,16 @@ type NotificationDestinationListItem struct { // NotificationDestinationID The unique ID for the notification destination. NotificationDestinationID NotificationDestinationID `json:"id"` Name string `json:"name"` - UpdatedAt time.Time `json:"updated_at"` - URL string `json:"url"` + + // Type Type of notification destination + Type NotificationDestinationListItemType `json:"type"` + UpdatedAt time.Time `json:"updated_at"` + URL string `json:"url"` } +// NotificationDestinationListItemType Type of notification destination +type NotificationDestinationListItemType string + // NotificationDestinationTestResponse Notification Destination Test Response type NotificationDestinationTestResponse struct { // HTTPBody Body of the HTTP response from the notification destination @@ -1735,11 +1336,56 @@ type NotificationDestinationTestResponse struct { // NotificationDestinationUpdate Update Notification Destination type NotificationDestinationUpdate struct { - Enabled *bool `json:"enabled,omitempty"` + // CustomMessage Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook) + CustomMessage *string `json:"custom_message,omitempty"` + Enabled *bool `json:"enabled,omitempty"` + + // HTTPBody HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}. HTTPBody *string `json:"http_body,omitempty"` HTTPHeaders *map[string]string `json:"http_headers,omitempty"` Name *string `json:"name,omitempty"` - URL *string `json:"url,omitempty"` + + // SlackChannels List of Slack channel IDs to send notifications to (only for slack type, must not be set for webhook) + SlackChannels *[]string `json:"slack_channels,omitempty"` + + // SlackConnectionID Slack connection ID (only for slack type, must not be set for webhook) + SlackConnectionID *openapi_types.UUID `json:"slack_connection_id,omitempty"` + URL *string `json:"url,omitempty"` +} + +// NotificationDetail A notification instance for a triggered alert, including one notification destination. Each notification destination for an alert will result in a separate notification item. +type NotificationDetail struct { + // CreatedAt Timestamp when the alert was created + CreatedAt time.Time `json:"created_at"` + + // ID Unique identifier for the alert + ID openapi_types.UUID `json:"id"` + + // LastEvaluatedAt Timestamp when the alert was last evaluated + LastEvaluatedAt *time.Time `json:"last_evaluated_at,omitempty"` + + // Message Alert message content + Message string `json:"message"` + + // NotificationDestination Notification Destination List Item + NotificationDestination *NotificationDestinationListItem `json:"notification_destination,omitempty"` + + // PolicyID Reference to the associated policy + PolicyID openapi_types.UUID `json:"policy_id"` + + // QueryID Reference to the associated query + QueryID openapi_types.UUID `json:"query_id"` + Severity AlertSeverity `json:"severity"` + State AlertState `json:"state"` + + // TotalViolations Number of violations that triggered the alert + TotalViolations int64 `json:"total_violations"` + + // TriggeredAt Timestamp when the alert was triggered + TriggeredAt *time.Time `json:"triggered_at,omitempty"` + + // UpdatedAt Timestamp when the alert was last updated + UpdatedAt time.Time `json:"updated_at"` } // OnboardingAWS AWS OpenID onboarding @@ -1849,96 +1495,16 @@ type OnboardingID = openapi_types.UUID // OrganizationalUnitID ID of an organizational unit in AWS type OrganizationalUnitID = string -// PlatformCreateOrUpdatePolicy defines model for PlatformCreateOrUpdatePolicy. -type PlatformCreateOrUpdatePolicy struct { - Description string `json:"description"` - FilterID *string `json:"filter_id,omitempty"` - FrameworkIDs []openapi_types.UUID `json:"framework_ids"` - Name string `json:"name"` - Status PlatformCreateOrUpdatePolicyStatus `json:"status"` -} - -// PlatformCreateOrUpdatePolicyStatus defines model for PlatformCreateOrUpdatePolicy.Status. -type PlatformCreateOrUpdatePolicyStatus string - -// PlatformPolicy defines model for PlatformPolicy. -type PlatformPolicy struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - - // CreatedBy Deprecated: Use created_by2 instead - CreatedBy *string `json:"created_by,omitempty"` - CreatedBy2 *CreatedBy `json:"created_by2,omitempty"` - Description string `json:"description"` - EvaluatedResources *int `json:"evaluated_resources,omitempty"` - FilterID *string `json:"filter_id,omitempty"` - FrameworkIDs []openapi_types.UUID `json:"framework_ids"` - ID openapi_types.UUID `json:"id"` - Name string `json:"name"` - RuleViolations *int `json:"rule_violations,omitempty"` - Status PlatformPolicyStatus `json:"status"` - UpdatedAt *time.Time `json:"updated_at,omitempty"` - UpdatedBy *CreatedBy `json:"updated_by,omitempty"` -} - -// PlatformPolicyStatus defines model for PlatformPolicy.Status. -type PlatformPolicyStatus string - -// PlatformPolicyFramework defines model for PlatformPolicyFramework. -type PlatformPolicyFramework struct { - Description *string `json:"description,omitempty"` - ID openapi_types.UUID `json:"id"` - Label string `json:"label"` +// PlatformDataSettings Platform data settings definition +type PlatformDataSettings struct { + // OwnershipTags List of tag names for asset ownership + OwnershipTags []string `json:"ownership_tags"` } -// PlatformPolicyFrameworkSortBy defines model for PlatformPolicyFrameworkSortBy. -type PlatformPolicyFrameworkSortBy string - -// PlatformPolicyRule defines model for PlatformPolicyRule. -type PlatformPolicyRule struct { - Category *string `json:"category,omitempty"` - Description *string `json:"description,omitempty"` - FrameworkID *openapi_types.UUID `json:"framework_id,omitempty"` - FrameworkName *string `json:"framework_name,omitempty"` - ID *openapi_types.UUID `json:"id,omitempty"` - LearnMoreLink *string `json:"learn_more_link,omitempty"` - Name *string `json:"name,omitempty"` - Remediation *string `json:"remediation,omitempty"` - Risk *PlatformPolicyRuleRisk `json:"risk,omitempty"` - Violations *int `json:"violations,omitempty"` -} - -// PlatformPolicyRuleRisk defines model for PlatformPolicyRule.Risk. -type PlatformPolicyRuleRisk string - -// PlatformPolicyRuleDetail defines model for PlatformPolicyRuleDetail. -type PlatformPolicyRuleDetail struct { - Account *string `json:"account,omitempty"` - Cloud *string `json:"cloud,omitempty"` - Name *string `json:"name,omitempty"` - Region *string `json:"region,omitempty"` - Tags *[]string `json:"tags,omitempty"` -} - -// PlatformPolicyRuleDetailSortBy defines model for PlatformPolicyRuleDetailSortBy. -type PlatformPolicyRuleDetailSortBy string - -// PlatformPolicyRuleSortBy defines model for PlatformPolicyRuleSortBy. -type PlatformPolicyRuleSortBy string - -// PlatformPolicySortBy defines model for PlatformPolicySortBy. -type PlatformPolicySortBy string - -// PlatformPolicySortDirection defines model for PlatformPolicySortDirection. -type PlatformPolicySortDirection string - -// PlatformPolicyViolationHistory defines model for PlatformPolicyViolationHistory. -type PlatformPolicyViolationHistory struct { - // CreatedAt Time the rule violations were logged. - CreatedAt time.Time `json:"created_at"` - ID openapi_types.UUID `json:"id"` - - // RuleViolations Number of rule violations logged. - RuleViolations int `json:"rule_violations"` +// PlatformDataSettingsUpdate Platform data settings partial update +type PlatformDataSettingsUpdate struct { + // OwnershipTags List of tag names for asset ownership + OwnershipTags *[]string `json:"ownership_tags,omitempty"` } // PlatformSettings Platform settings definition @@ -2030,82 +1596,6 @@ type PluginAsset struct { // PluginCategory Supported categories for plugins type PluginCategory string -// PluginCreate defines model for PluginCreate. -type PluginCreate struct { - // Category Supported categories for plugins - Category PluginCategory `json:"category"` - - // DisplayName The plugin's display name, as shown in the CloudQuery Hub. - DisplayName string `json:"display_name"` - - // FreeRowsPerMonth Deprecated. Use `price_category` instead. - // Deprecated: - FreeRowsPerMonth *int64 `json:"free_rows_per_month,omitempty"` - Homepage *string `json:"homepage,omitempty"` - - // Kind The kind of plugin, ie. source or destination. - Kind PluginKind `json:"kind"` - - // Logo URL to the plugin's logo. This will be shown in the CloudQuery Hub. - Logo *string `json:"logo,omitempty"` - - // Name The unique name for the plugin. - Name PluginName `json:"name"` - - // PriceCategory Supported price categories for billing - PriceCategory *PluginPriceCategory `json:"price_category,omitempty"` - - // Public Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the team. - Public bool `json:"public"` - - // ReleaseStage Official plugins can go through three release stages: Coming Soon, Preview, and GA. - // The Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready. - // Both Preview and GA plugins follow semantic versioning. The main differences between the two stages are: - // Preview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage. - ReleaseStage *PluginReleaseStageCreate `json:"release_stage,omitempty"` - Repository *string `json:"repository,omitempty"` - - // ShortDescription Short description of the plugin. This will be shown in the CloudQuery Hub. - ShortDescription string `json:"short_description"` - - // TeamName The unique name for the team. - TeamName TeamName `json:"team_name"` - - // Tier This field is deprecated, refer to `price_category` instead. - // This field is only kept for backward compatibility and may be removed in a future release. - // Supported tiers for plugins. - // - free: Free tier, with no paid tables. - // - paid: Paid tier. These plugins may have paid tables, but can also have free tables. They require login to access. - // - open-core: This option is deprecated, values will either be free or paid. - // Deprecated: - Tier *PluginTier `json:"tier,omitempty"` - - // USDPerRow Deprecated. Use `price_category` instead. - // Deprecated: - USDPerRow *string `json:"usd_per_row,omitempty"` -} - -// PluginDocsPage CloudQuery Plugin Documentation Page -type PluginDocsPage struct { - // Content The content of the documentation page. Supports markdown. - Content string `json:"content"` - - // Name The unique name for the plugin documentation page. - Name PluginDocsPageName `json:"name"` -} - -// PluginDocsPageCreate CloudQuery Plugin Documentation Page -type PluginDocsPageCreate struct { - // Content The content of the documentation page. Supports markdown. - Content string `json:"content"` - - // Name The unique name for the plugin documentation page. - Name PluginDocsPageName `json:"name"` -} - -// PluginDocsPageName The unique name for the plugin documentation page. -type PluginDocsPageName = string - // PluginKind The kind of plugin, ie. source or destination. type PluginKind string @@ -2127,18 +1617,6 @@ type PluginProtocols = []int // Preview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage. type PluginReleaseStage string -// PluginReleaseStageCreate Official plugins can go through three release stages: Coming Soon, Preview, and GA. -// The Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready. -// Both Preview and GA plugins follow semantic versioning. The main differences between the two stages are: -// Preview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage. -type PluginReleaseStageCreate string - -// PluginReleaseStageUpdate Official plugins can go through three release stages: Coming Soon, Preview, and GA. -// The Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready. -// Both Preview and GA plugins follow semantic versioning. The main differences between the two stages are: -// Preview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage. -type PluginReleaseStageUpdate string - // PluginSpecJSONSchema The specification of the plugin. This is a JSON schema that describes the configuration of the plugin. type PluginSpecJSONSchema = string @@ -2193,35 +1671,6 @@ type PluginTableColumn struct { Unique bool `json:"unique"` } -// PluginTableCreate CloudQuery Plugin Table -type PluginTableCreate struct { - Columns *[]PluginTableColumn `json:"columns,omitempty"` - - // Description Description of the table - Description *string `json:"description,omitempty"` - - // IsIncremental Whether the table is incremental - IsIncremental *bool `json:"is_incremental,omitempty"` - - // IsPaid Whether the table is paid - IsPaid *bool `json:"is_paid,omitempty"` - - // Name Name of the table - Name PluginTableName `json:"name"` - - // Parent Name of the parent table, if any - Parent *string `json:"parent,omitempty"` - - // PermissionsNeeded List of permissions needed to access this table, if any - PermissionsNeeded *[]string `json:"permissions_needed,omitempty"` - - // Relations Names of the tables that depend on this table - Relations *[]string `json:"relations,omitempty"` - - // Title Title of the table - Title *string `json:"title,omitempty"` -} - // PluginTableDetails defines model for PluginTableDetails. type PluginTableDetails struct { // Columns List of columns @@ -2263,81 +1712,11 @@ type PluginTableName = string // - open-core: This option is deprecated, values will either be free or paid. type PluginTier string -// PluginUIAsset CloudQuery Plugin UI Asset -type PluginUIAsset struct { - // Name The path and name of the asset - Name string `json:"name"` - - // UploadURL URL to upload the asset to - UploadURL string `json:"upload_url"` -} - -// PluginUIAssetUploadRequest CloudQuery Plugin UI Asset Upload Request -type PluginUIAssetUploadRequest struct { - // ContentType Content-type of the asset - ContentType *string `json:"content_type,omitempty"` - - // Name The path and name of the asset - Name string `json:"name"` -} - -// PluginUpdate defines model for PluginUpdate. -type PluginUpdate struct { - // Category Supported categories for plugins - Category *PluginCategory `json:"category,omitempty"` - - // DisplayName The plugin's display name, as shown in the CloudQuery Hub. - DisplayName *string `json:"display_name,omitempty"` - - // FreeRowsPerMonth Deprecated. Update `price_category` instead. - // Deprecated: - FreeRowsPerMonth *int64 `json:"free_rows_per_month,omitempty"` - Homepage *string `json:"homepage,omitempty"` - - // Logo URL to the plugin's logo. This will be shown in the CloudQuery Hub. - Logo *string `json:"logo,omitempty"` - - // PriceCategory Supported price categories for billing - PriceCategory *PluginPriceCategory `json:"price_category,omitempty"` - - // Public If plugin is not public, it won't be visible to other teams in the CloudQuery Hub. - Public *bool `json:"public,omitempty"` - - // ReleaseStage Official plugins can go through three release stages: Coming Soon, Preview, and GA. - // The Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready. - // Both Preview and GA plugins follow semantic versioning. The main differences between the two stages are: - // Preview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage. - ReleaseStage *PluginReleaseStageUpdate `json:"release_stage,omitempty"` - Repository *string `json:"repository,omitempty"` - - // ShortDescription Short description of the plugin. This will be shown in the CloudQuery Hub. - ShortDescription *string `json:"short_description,omitempty"` - - // Tier This field is deprecated, refer to `price_category` instead. - // This field is only kept for backward compatibility and may be removed in a future release. - // Supported tiers for plugins. - // - free: Free tier, with no paid tables. - // - paid: Paid tier. These plugins may have paid tables, but can also have free tables. They require login to access. - // - open-core: This option is deprecated, values will either be free or paid. - // Deprecated: - Tier *PluginTier `json:"tier,omitempty"` - - // USDPerRow Deprecated. Update `price_category` instead. - // Deprecated: - USDPerRow *string `json:"usd_per_row,omitempty"` -} - // PluginVersion defines model for PluginVersion. type PluginVersion struct { // Checksums The checksums of the plugin assets Checksums []string `json:"checksums"` - // ConnectorRequired Whether a connector is required for this plugin version - ConnectorRequired *bool `json:"connector_required,omitempty"` - - // ConnectorTypes List of connector types available for this plugin version - ConnectorTypes *[]string `json:"connector_types,omitempty"` - // CreatedAt The date and time the plugin version was created. CreatedAt time.Time `json:"created_at"` @@ -2407,12 +1786,6 @@ type PluginVersionDetails struct { // Checksums The checksums of the plugin assets Checksums []string `json:"checksums"` - // ConnectorRequired Whether a connector is required for this plugin version - ConnectorRequired *bool `json:"connector_required,omitempty"` - - // ConnectorTypes List of connector types available for this plugin version - ConnectorTypes *[]string `json:"connector_types,omitempty"` - // CreatedAt The date and time the plugin version was created. CreatedAt time.Time `json:"created_at"` @@ -2456,29 +1829,181 @@ type PluginVersionDetails struct { // PluginVersionList CloudQuery Plugin Version type PluginVersionList = PluginVersionBase -// PluginVersionUpdate defines model for PluginVersionUpdate. -type PluginVersionUpdate struct { - // Checksums The SHA-256 checksums of the plugin binaries, one per supported target. - Checksums *[]string `json:"checksums,omitempty"` +// Policy Policy +type Policy struct { + CreatedAt time.Time `json:"created_at"` + CreatedByUserID openapi_types.UUID `json:"created_by"` + Description string `json:"description"` - // Draft If a plugin version is in draft, it will not show to members outside the team or be counted as the latest version. Once draft is set to false, only certain fields can be updated. - Draft *bool `json:"draft,omitempty"` + // PolicyDomain Policy domain + PolicyDomain PolicyDomain `json:"domain"` - // Message Description of what's new or changed in this version (supports markdown) - Message *string `json:"message,omitempty"` + // PolicyID The unique ID for the policy. + PolicyID PolicyID `json:"id"` + Name string `json:"name"` - // PackageType The package type of the plugin binaries - PackageType *string `json:"package_type,omitempty"` + // NotificationDestinations List of notification destinations configured for the policy's alert + NotificationDestinations *[]NotificationDestinationListItem `json:"notification_destinations,omitempty"` - // Protocols The CloudQuery protocols supported by this plugin version (only protocol 3 is supported by new plugins). - Protocols *PluginProtocols `json:"protocols,omitempty"` + // PolicyGroups List of policy groups this policy belongs to + PolicyGroups *[]PolicyGroup `json:"policy_groups,omitempty"` - // Retracted If a plugin version is retracted, assets will still be available for download, but the version will be marked as retracted to discourage use. - Retracted *bool `json:"retracted,omitempty"` + // Query The SQL query string for the policy + Query string `json:"query"` - // SpecJsonSchema The specification of the plugin. This is a JSON schema that describes the configuration of the plugin. - SpecJsonSchema *PluginSpecJSONSchema `json:"spec_json_schema,omitempty"` - SupportedTargets *[]string `json:"supported_targets,omitempty"` + // QueryID The unique ID for the query. + QueryID QueryID `json:"query_id"` + + // RunAt Timestamp of the last evaluation run + RunAt *time.Time `json:"run_at"` + + // PolicySeverity Policy severity + PolicySeverity PolicySeverity `json:"severity"` + + // PolicyStatus Policy status + PolicyStatus PolicyStatus `json:"status"` + TeamName string `json:"team_name"` + UpdatedAt time.Time `json:"updated_at"` + UpdatedByUserID *openapi_types.UUID `json:"updated_by"` + + // ViolationCount Number of violations from the last evaluation + ViolationCount *int `json:"violation_count"` +} + +// PolicyCreate Create a policy (implicitly creates a query and an enabled alert) +type PolicyCreate struct { + Description *string `json:"description,omitempty"` + + // PolicyDomain Policy domain + PolicyDomain PolicyDomain `json:"domain"` + Name string `json:"name"` + + // NotificationDestinationIds Notification destination IDs to send alerts to + NotificationDestinationIds *[]openapi_types.UUID `json:"notification_destination_ids"` + + // PolicyGroupIds Policy group IDs to add this policy to + PolicyGroupIds *[]openapi_types.UUID `json:"policy_group_ids"` + Query string `json:"query"` + + // PolicySeverity Policy severity + PolicySeverity PolicySeverity `json:"severity"` +} + +// PolicyDomain Policy domain +type PolicyDomain string + +// PolicyEvaluationLog Policy evaluation log entry +type PolicyEvaluationLog struct { + Id openapi_types.UUID `json:"id"` + + // PolicyID The unique ID for the policy. + PolicyID PolicyID `json:"policy_id"` + RunAt time.Time `json:"run_at"` + ViolationCount int `json:"violation_count"` +} + +// PolicyGroup Policy Group +type PolicyGroup struct { + CreatedAt time.Time `json:"created_at"` + Description string `json:"description"` + Id openapi_types.UUID `json:"id"` + Name string `json:"name"` + UpdatedAt time.Time `json:"updated_at"` +} + +// PolicyGroupCreate Create a policy group +type PolicyGroupCreate struct { + Description *string `json:"description,omitempty"` + Name string `json:"name"` + + // PolicyIds Optional array of policy IDs to add to this group + PolicyIds *[]openapi_types.UUID `json:"policy_ids"` +} + +// PolicyGroupID defines model for PolicyGroupID. +type PolicyGroupID = openapi_types.UUID + +// PolicyGroupUpdate Update a policy group +type PolicyGroupUpdate struct { + Description *string `json:"description,omitempty"` + Name *string `json:"name,omitempty"` + + // PolicyIds Policy IDs to set for this group + PolicyIds *[]openapi_types.UUID `json:"policy_ids"` +} + +// PolicyGroupWithCounts defines model for PolicyGroupWithCounts. +type PolicyGroupWithCounts struct { + CreatedAt time.Time `json:"created_at"` + Description string `json:"description"` + Id openapi_types.UUID `json:"id"` + Name string `json:"name"` + + // PolicyCount Number of policies in this group + PolicyCount *int `json:"policy_count,omitempty"` + UpdatedAt time.Time `json:"updated_at"` + + // ViolationCountCritical Total violations from critical severity policies in this group + ViolationCountCritical *int `json:"violation_count_critical,omitempty"` + + // ViolationCountHigh Total violations from high severity policies in this group + ViolationCountHigh *int `json:"violation_count_high,omitempty"` + + // ViolationCountLow Total violations from low severity policies in this group + ViolationCountLow *int `json:"violation_count_low,omitempty"` + + // ViolationCountMedium Total violations from medium severity policies in this group + ViolationCountMedium *int `json:"violation_count_medium,omitempty"` +} + +// PolicyID The unique ID for the policy. +type PolicyID = openapi_types.UUID + +// PolicyMetrics Policy metrics summary +type PolicyMetrics struct { + // HighSeverityViolations Total violations from high or critical severity policies + HighSeverityViolations int `json:"high_severity_violations"` + + // TotalActiveViolations Total violations from active policies + TotalActiveViolations int `json:"total_active_violations"` + + // ViolationsThisWeek Total violations from evaluations in the last 7 days + ViolationsThisWeek int `json:"violations_this_week"` +} + +// PolicySeverity Policy severity +type PolicySeverity string + +// PolicyStatus Policy status +type PolicyStatus string + +// PolicyUpdate Update a policy +type PolicyUpdate struct { + Description *string `json:"description,omitempty"` + + // PolicyDomain Policy domain + PolicyDomain *PolicyDomain `json:"domain,omitempty"` + Name *string `json:"name,omitempty"` + + // NotificationDestinationIds Notification destination IDs to send alerts to + NotificationDestinationIds *[]openapi_types.UUID `json:"notification_destination_ids"` + + // PolicyGroupIds Policy group IDs to set for this policy + PolicyGroupIds *[]openapi_types.UUID `json:"policy_group_ids"` + Query *string `json:"query,omitempty"` + + // PolicySeverity Policy severity + PolicySeverity *PolicySeverity `json:"severity,omitempty"` +} + +// PolicyViolation Policy violation resource information +type PolicyViolation struct { + CqAccountName string `json:"_cq_account_name"` + CqPlatformId string `json:"_cq_platform_id"` + Cloud string `json:"cloud"` + Name string `json:"name"` + Region string `json:"region"` + ResourceTypeLabel string `json:"resource_type_label"` } // PromoteSyncDestinationTestConnection Sync Destination Definition @@ -2502,6 +2027,9 @@ type PromoteSyncDestinationTestConnection struct { // PromoteSyncSourceTestConnection Sync Source Definition type PromoteSyncSourceTestConnection struct { + // DestinationNames List of sync destination names associated with this source + DestinationNames *[]SyncDestinationNameField `json:"destination_names,omitempty"` + // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` @@ -2608,12 +2136,6 @@ type QueryUpdate struct { // QueryViewName The name of the view the query is saved to in the warehouse type QueryViewName = string -// RBACCustomRoleID The unique ID for the custom role. -type RBACCustomRoleID = openapi_types.UUID - -// RBACDefaultRole Default RBAC roles -type RBACDefaultRole string - // RBACPermission defines model for RBACPermission. type RBACPermission struct { CreatedAt time.Time `json:"created_at"` @@ -2653,19 +2175,6 @@ type RBACPermissionUpdate struct { Query *string `json:"query,omitempty"` } -// RBACRole Custom RBAC role -type RBACRole struct { - CreatedAt time.Time `json:"created_at"` - CreatedBy CreatedBy `json:"created_by"` - Description string `json:"description"` - - // RBACCustomRoleID The unique ID for the custom role. - RBACCustomRoleID RBACCustomRoleID `json:"id"` - Name string `json:"name"` - Permissions []RBACPermission `json:"permissions"` - UpdatedAt time.Time `json:"updated_at"` -} - // RBACRoleCreate defines model for RBACRoleCreate. type RBACRoleCreate struct { Description *string `json:"description,omitempty"` @@ -2686,17 +2195,6 @@ type RBACRoleUpdate struct { Permissions *[]RBACPermissionID `json:"permissions,omitempty"` } -// RegistryAuthToken JWT token for the image registry -type RegistryAuthToken struct { - AccessToken string `json:"access_token"` - Token string `json:"token"` -} - -// ReleaseURL defines model for ReleaseURL. -type ReleaseURL struct { - Url string `json:"url"` -} - // Report defines model for Report. type Report struct { // Content YAML body @@ -2773,13 +2271,33 @@ type RevokedNotification struct { Status interface{} `json:"status"` } +// Role Role +type Role struct { + CreatedAt time.Time `json:"created_at"` + CreatedBy CreatedBy `json:"created_by"` + Description string `json:"description"` + + // ID The unique ID for the role. + ID openapi_types.UUID `json:"id"` + Name string `json:"name"` + Permissions []RBACPermission `json:"permissions"` + Type RoleType `json:"type"` + UpdatedAt time.Time `json:"updated_at"` +} + +// RoleID The unique ID for the role. +type RoleID = openapi_types.UUID + +// RoleType defines model for RoleType. +type RoleType string + // SAMLConfig defines model for SAMLConfig. type SAMLConfig struct { // CanEnable Whether SAML can be enabled CanEnable bool `json:"can_enable"` // DefaultRoles Default roles for new users who are not in any group - DefaultRoles []string `json:"default_roles"` + DefaultRoles []Role `json:"default_roles"` // DisableAccessIfNoRoleGroup Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in. DisableAccessIfNoRoleGroup *bool `json:"disable_access_if_no_role_group,omitempty"` @@ -2796,32 +2314,29 @@ type SAMLConfig struct { // MetadataXML Metadata file contents from identity provider. Mutually exclusive with `metadata_url` MetadataXML *string `json:"metadata_xml,omitempty"` - // PlatformBaseURL Base URL to the platform. - PlatformBaseURL *string `json:"platform_base_url,omitempty"` - // PlatformCertificateDownloadURL Platform Certificate download URL PlatformCertificateDownloadURL string `json:"platform_certificate_download_url"` - // PlatformEntityID SAML Entity ID. Only available after `platform_base_url` is set. - PlatformEntityID *string `json:"platform_entity_id,omitempty"` + // PlatformEntityID SAML Entity ID. + PlatformEntityID string `json:"platform_entity_id"` - // PlatformMetadataDownloadURL URL to download platform metadata. Only available after `platform_base_url` is set. - PlatformMetadataDownloadURL *string `json:"platform_metadata_download_url,omitempty"` + // PlatformMetadataDownloadURL URL to download platform metadata. + PlatformMetadataDownloadURL string `json:"platform_metadata_download_url"` - // PlatformSSOURL SAML service URL. Only available after `platform_base_url` is set. - PlatformSSOURL *string `json:"platform_sso_url,omitempty"` + // PlatformSSOURL SAML service URL. + PlatformSSOURL string `json:"platform_sso_url"` // RoleGroupKey Role group key name RoleGroupKey *string `json:"role_group_key,omitempty"` // RoleMappings Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group. - RoleMappings map[string][]string `json:"role_mappings,omitempty"` + RoleMappings map[string][]Role `json:"role_mappings,omitempty"` } // SAMLConfigUpdate defines model for SAMLConfigUpdate. type SAMLConfigUpdate struct { // DefaultRoles Default roles for new users who are not in any group - DefaultRoles *[]string `json:"default_roles,omitempty"` + DefaultRoles *[]RoleID `json:"default_roles,omitempty"` // DisableAccessIfNoRoleGroup Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in. DisableAccessIfNoRoleGroup *bool `json:"disable_access_if_no_role_group,omitempty"` @@ -2838,14 +2353,50 @@ type SAMLConfigUpdate struct { // MetadataXML Metadata file contents from identity provider. Mutually exclusive with `metadata_url` MetadataXML *string `json:"metadata_xml,omitempty"` - // PlatformBaseURL Base URL to the platform. This should be set first. https recommended. - PlatformBaseURL *string `json:"platform_base_url,omitempty"` - // RoleGroupKey Role group key name RoleGroupKey *string `json:"role_group_key,omitempty"` // RoleMappings Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group. - RoleMappings *map[string][]string `json:"role_mappings,omitempty"` + RoleMappings *map[string][]RoleID `json:"role_mappings,omitempty"` +} + +// SlackChannel Slack Channel +type SlackChannel struct { + // Id Channel ID + Id string `json:"id"` + + // IsArchived Whether the channel is archived + IsArchived *bool `json:"is_archived,omitempty"` + + // IsPrivate Whether the channel is private + IsPrivate *bool `json:"is_private,omitempty"` + + // Name Channel name + Name string `json:"name"` +} + +// SlackConnection Slack Connection +type SlackConnection struct { + CreatedAt time.Time `json:"created_at"` + + // Id Slack connection ID + Id openapi_types.UUID `json:"id"` + + // SlackWorkspaceID Slack workspace (team) ID + SlackWorkspaceID string `json:"slack_workspace_id"` + + // TeamName Slack workspace (team) name + TeamName string `json:"team_name"` + UpdatedAt time.Time `json:"updated_at"` +} + +// SlackConnectionCreate Create Slack Connection +type SlackConnectionCreate struct { + // Code OAuth code from Slack authorization + Code string `json:"code"` + + // RedirectUri Redirect URI that was used when obtaining the OAuth code (required by Slack when exchanging the code) + RedirectUri *string `json:"redirect_uri,omitempty"` } // StartedNotification defines model for StartedNotification. @@ -2914,9 +2465,6 @@ type SyncCreate struct { // SyncDestination defines model for SyncDestination. type SyncDestination struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // CreatedAt Time when the source was created CreatedAt time.Time `json:"created_at"` @@ -2960,9 +2508,6 @@ type SyncDestination struct { // SyncDestinationCreate Sync Destination Definition type SyncDestinationCreate struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` @@ -2998,6 +2543,9 @@ type SyncDestinationMigrateMode string // SyncDestinationMigrateModeUpdate Migrate mode for the destination, for updating type SyncDestinationMigrateModeUpdate string +// SyncDestinationNameField Descriptive, unique name for the destination +type SyncDestinationNameField = string + // SyncDestinationTestConnection defines model for SyncDestinationTestConnection. type SyncDestinationTestConnection struct { // CompletedAt Time the test connection was completed @@ -3028,9 +2576,6 @@ type SyncDestinationTestConnection struct { // SyncDestinationTestConnectionCreate defines model for SyncDestinationTestConnectionCreate. type SyncDestinationTestConnectionCreate struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // DestinationName Name of an existing destination DestinationName *string `json:"destination_name,omitempty"` @@ -3122,9 +2667,6 @@ type SyncDestinationUpdateV2 struct { // SyncDestinationV2 defines model for SyncDestinationV2. type SyncDestinationV2 struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // CreatedAt Time when the source was created CreatedAt time.Time `json:"created_at"` @@ -3201,8 +2743,8 @@ type SyncGenericSortBy string // SyncIntegrationCreateV2 Create a new sync integration type SyncIntegrationCreateV2 struct { - // CPU CPU quota for the integration - CPU *string `json:"cpu,omitempty"` + // DestinationNames List of sync destination names associated with this integration + DestinationNames []SyncDestinationNameField `json:"destination_names"` // Disabled Whether the integration is disabled Disabled *bool `json:"disabled,omitempty"` @@ -3210,9 +2752,6 @@ type SyncIntegrationCreateV2 struct { // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` - // Memory Memory quota for the integration - Memory *string `json:"memory,omitempty"` - // Name Descriptive, unique name for the integration Name string `json:"name"` @@ -3225,13 +2764,13 @@ type SyncIntegrationCreateV2 struct { // SyncIntegrationExpandedV2 defines model for SyncIntegrationExpandedV2. type SyncIntegrationExpandedV2 struct { - // CPU CPU quota for the integration - CPU *string `json:"cpu,omitempty"` - // CreatedAt Time when the sync was created CreatedAt *time.Time `json:"created_at,omitempty"` CreatedBy *string `json:"created_by,omitempty"` + // Destinations List of sync destinations associated with this integration + Destinations *[]SyncDestinationV2 `json:"destinations,omitempty"` + // Disabled Whether the integration is disabled Disabled *bool `json:"disabled,omitempty"` @@ -3241,9 +2780,6 @@ type SyncIntegrationExpandedV2 struct { // LastRun Managed Sync List Entry Last Run Info LastRun *ListSyncLastRun `json:"last_run,omitempty"` - // Memory Memory quota for the integration - Memory *string `json:"memory,omitempty"` - // Name Descriptive, unique name for the integration Name string `json:"name"` @@ -3292,9 +2828,6 @@ type SyncIntegrationSourceUpdateV2 struct { // SyncIntegrationSourceV2 Integration Source Definition type SyncIntegrationSourceV2 struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // Env Environment variables for the plugin. All environment variables will be stored as secrets. Env []SyncEnv `json:"env"` @@ -3323,9 +2856,6 @@ type SyncIntegrationSourceV2 struct { // SyncIntegrationTestConnectionCreateV2 defines model for SyncIntegrationTestConnectionCreateV2. type SyncIntegrationTestConnectionCreateV2 struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // Env Environment variables for the plugin. All environment variables will be stored as secrets. Env *[]SyncEnvCreate `json:"env,omitempty"` @@ -3372,8 +2902,8 @@ type SyncIntegrationTestConnectionV2 struct { // SyncIntegrationUpdateV2 Update an existing integration type SyncIntegrationUpdateV2 struct { - // CPU CPU quota for the integration - CPU *string `json:"cpu,omitempty"` + // DestinationNames List of sync destinations associated with this integration + DestinationNames *[]SyncDestinationNameField `json:"destination_names,omitempty"` // Disabled Whether the integration is disabled Disabled *bool `json:"disabled,omitempty"` @@ -3381,12 +2911,6 @@ type SyncIntegrationUpdateV2 struct { // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` - // LastUpdateSource How was the source or destination been created or updated last - LastUpdateSource *SyncLastUpdateSource `json:"last_update_source,omitempty"` - - // Memory Memory quota for the integration - Memory *string `json:"memory,omitempty"` - // Schedule Cron schedule for the integration Schedule *string `json:"schedule,omitempty"` @@ -3396,22 +2920,19 @@ type SyncIntegrationUpdateV2 struct { // SyncIntegrationV2 An integration definition type SyncIntegrationV2 struct { - // CPU CPU quota for the integration - CPU *string `json:"cpu,omitempty"` - // CreatedAt Time when the sync was created CreatedAt *time.Time `json:"created_at,omitempty"` CreatedBy *string `json:"created_by,omitempty"` + // Destinations List of sync destinations associated with this integration + Destinations *[]SyncDestinationV2 `json:"destinations,omitempty"` + // Disabled Whether the integration is disabled Disabled *bool `json:"disabled,omitempty"` // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` - // Memory Memory quota for the integration - Memory *string `json:"memory,omitempty"` - // Name Descriptive, unique name for the integration Name string `json:"name"` @@ -3560,6 +3081,9 @@ type SyncRunTableProgress map[string]struct { Rows int64 `json:"rows"` } +// SyncRunTableSortBy defines model for SyncRunTableSortBy. +type SyncRunTableSortBy string + // SyncRunTableStat defines model for SyncRunTableStat. type SyncRunTableStat struct { // CompletedAt Time the table sync was completed @@ -3607,9 +3131,6 @@ type SyncSortDirection string // SyncSource defines model for SyncSource. type SyncSource struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // CreatedAt Time when the source was created CreatedAt time.Time `json:"created_at"` @@ -3653,9 +3174,6 @@ type SyncSource struct { // SyncSourceCreate Sync Source Definition type SyncSourceCreate struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` @@ -3714,9 +3232,6 @@ type SyncSourceTestConnection struct { // SyncSourceTestConnectionCreate defines model for SyncSourceTestConnectionCreate. type SyncSourceTestConnectionCreate struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // Env Environment variables for the plugin. All environment variables will be stored as secrets. Env *[]SyncEnvCreate `json:"env,omitempty"` @@ -3739,6 +3254,9 @@ type SyncSourceTestConnectionID = openapi_types.UUID // SyncSourceUpdate Sync Source Update Definition type SyncSourceUpdate struct { + // DestinationNames List of sync destination names associated with this source + DestinationNames *[]SyncDestinationNameField `json:"destination_names,omitempty"` + // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` @@ -3790,9 +3308,6 @@ type SyncTestConnectionStatus string // SyncTransformer defines model for SyncTransformer. type SyncTransformer struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // CreatedAt Time when the transformer was created CreatedAt time.Time `json:"created_at"` @@ -3824,9 +3339,6 @@ type SyncTransformer struct { // SyncTransformerCreate Sync Transformer Definition type SyncTransformerCreate struct { - // ConnectorID ID of the Connector - ConnectorID *ConnectorID `json:"connector_id,omitempty"` - // DisplayName A human-readable display name DisplayName *DisplayName `json:"display_name,omitempty"` @@ -3942,26 +3454,51 @@ type TableData struct { Rows [][]interface{} `json:"rows"` } +// TableDataAction Request body for performing actions on table data +type TableDataAction struct { + // Action The action to perform on the table data + Action TableDataActionAction `json:"action"` + + // Syncs Map of sync names to arrays of table names + Syncs map[string][]string `json:"syncs"` +} + +// TableDataActionAction The action to perform on the table data +type TableDataActionAction string + +// TableDataListItem Sync with its associated tables +type TableDataListItem struct { + // DisplayName Human-readable display name of the sync + DisplayName *string `json:"display_name,omitempty"` + + // Plugin Plugin path in CloudQuery registry + Plugin *SyncPluginPath `json:"plugin,omitempty"` + + // SyncName The unique name of the sync (source_name from synced_tables) + SyncName string `json:"sync_name"` + + // Tables List of tables synced by this integration with their deletion status + Tables []struct { + // DeletionPending Whether this table's data is marked for deletion + DeletionPending bool `json:"deletion_pending"` + + // Name The table name + Name string `json:"name"` + } `json:"tables"` +} + // TableGroupBy defines model for TableGroupBy. type TableGroupBy = string // TableListItem defines model for TableListItem. type TableListItem struct { // Name The name of the table. - Name TableName `json:"name"` - TotalRows *uint64 `json:"total_rows,omitempty"` + Name TableName `json:"name"` } // TableName The name of the table. type TableName = string -// TableRelation defines model for TableRelation. -type TableRelation struct { - Label string `json:"label"` - Query string `json:"query"` - Table string `json:"table_name"` -} - // TableRow defines model for TableRow. type TableRow map[string]interface{} @@ -4017,58 +3554,13 @@ type TableSortDirection string // Team CloudQuery Team type Team struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - - // DisplayName The team's display name - DisplayName string `json:"display_name"` - Internal bool `json:"internal"` - IsTrialActive bool `json:"is_trial_active"` - // Name The unique name for the team. Name TeamName `json:"name"` - - // Plan The plan the team is on (trial is deprecated) - Plan TeamPlan `json:"plan"` - PlanEndTime *time.Time `json:"plan_end_time,omitempty"` - TrialEndTime *time.Time `json:"trial_end_time,omitempty"` -} - -// TeamImage defines model for TeamImage. -type TeamImage struct { - // Checksum SHA1 checksum of image - Checksum string `json:"checksum"` - - // Name Name of image - Name string `json:"name"` - - // RequiredHeaders Required HTTP headers to include for the upload - RequiredHeaders map[string][]string `json:"required_headers"` - - // UploadURL URL to upload image - UploadURL *string `json:"upload_url,omitempty"` - - // URL URL to download image - URL string `json:"url"` -} - -// TeamImageCreate defines model for TeamImageCreate. -type TeamImageCreate struct { - // Checksum SHA1 checksum of image - Checksum string `json:"checksum"` - - // ContentType The HTTP Content-Type of the image or asset - ContentType ContentType `json:"content_type"` - - // Name Name of image - Name string `json:"name"` } // TeamName The unique name for the team. type TeamName = string -// TeamPlan The plan the team is on (trial is deprecated) -type TeamPlan string - // UsageSummary A usage summary for a team, summarizing the paid rows synced and/or cloud resource usage over a given time range. // Note that empty or all-zero values are not included in the response. type UsageSummary struct { @@ -4125,20 +3617,31 @@ type UsageSummaryValue struct { Timestamp time.Time `json:"timestamp"` } -// User CloudQuery User +// User User type User struct { CreatedAt *time.Time `json:"created_at,omitempty"` Email string `json:"email"` + // Enabled Whether the user is enabled + Enabled bool `json:"enabled"` + // ID ID of the User ID openapi_types.UUID `json:"id"` LastLoginAt *time.Time `json:"last_login_at,omitempty"` + // MFAConfigured Whether the user has MFA configured + MFAConfigured bool `json:"mfa_configured"` + // Name The unique name for the user. Name *UserName `json:"name,omitempty"` // ProfileImageURL Profile image URL of user - ProfileImageURL *string `json:"profile_image_url,omitempty"` + ProfileImageURL *string `json:"profile_image_url,omitempty"` + Provider UserProvider `json:"provider"` + Roles []Role `json:"roles"` + + // TrackingOptedIn Whether anonymous user tracking was opted into + TrackingOptedIn *bool `json:"tracking_opted_in,omitempty"` UpdatedAt *time.Time `json:"updated_at,omitempty"` } @@ -4148,14 +3651,60 @@ type UserID = openapi_types.UUID // UserName The unique name for the user. type UserName = string +// UserProvider defines model for UserProvider. +type UserProvider string + // VersionFilter A version filter in semantic version format with prefix ranges. type VersionFilter = string // VersionName The version in semantic version format. type VersionName = string -// VersionRange A version range in semantic version format. -type VersionRange = string +// ViolationsByDomain Violations grouped by domain +type ViolationsByDomain struct { + Items []ViolationsByDomainItem `json:"items"` + + // TotalViolations Total violations across all domains + TotalViolations int `json:"total_violations"` +} + +// ViolationsByDomainItem Violation count for a specific domain +type ViolationsByDomainItem struct { + // PolicyDomain Policy domain + PolicyDomain PolicyDomain `json:"domain"` + + // ViolationCount Number of violations for this domain + ViolationCount int `json:"violation_count"` +} + +// ViolationsHistory Violations history over time +type ViolationsHistory struct { + Items []ViolationsHistoryItem `json:"items"` + + // Metadata Metadata for violations history query + Metadata ViolationsHistoryMetadata `json:"metadata"` +} + +// ViolationsHistoryItem Violation count for a specific date +type ViolationsHistoryItem struct { + // Date Date of the violations + Date openapi_types.Date `json:"date"` + + // ViolationCount Number of violations on this date + ViolationCount int `json:"violation_count"` +} + +// ViolationsHistoryMetadata Metadata for violations history query +type ViolationsHistoryMetadata struct { + // EndDate End date of the query range + EndDate openapi_types.Date `json:"end_date"` + + // Interval Interval in days used for grouping + Interval string `json:"interval"` + + // StartDate Start date of the query range + StartDate openapi_types.Date `json:"start_date"` +} // AlertConfigured defines model for alert_configured. type AlertConfigured = bool @@ -4169,9 +3718,6 @@ type AlertMessageFilter = string // AlertStates defines model for alert_states. type AlertStates = []AlertState -// AssetViewRunTypes defines model for assetview_run_type. -type AssetViewRunTypes = []AssetViewRunType - // ColumnName The name of a table column. type ColumnName = string @@ -4187,9 +3733,6 @@ type CustomColumnSortDirections = []CustomColumnSortDirection // DownloadFile defines model for download_file. type DownloadFile = bool -// EmailBasic defines model for email_basic. -type EmailBasic = string - // Enabled defines model for enabled. type Enabled = bool @@ -4211,33 +3754,18 @@ type IncludeFips = bool // IncludePrereleases defines model for include_prereleases. type IncludePrereleases = bool -// IncludePrivate defines model for include_private. -type IncludePrivate = bool - // MigrationFilter Filter by migration type MigrationFilter = bool +// NotificationDestinationId The unique ID for the notification destination. +type NotificationDestinationId = NotificationDestinationID + // Page defines model for page. type Page = int64 // PerPage defines model for per_page. type PerPage = int64 -// PlatformPolicySortBys defines model for platform_policies_sort_bys. -type PlatformPolicySortBys = []PlatformPolicySortBy - -// PlatformPolicySortDirections defines model for platform_policies_sort_dirs. -type PlatformPolicySortDirections = []PlatformPolicySortDirection - -// PlatformPolicyFrameworkSortBys defines model for platform_policy_frameworks_sort_bys. -type PlatformPolicyFrameworkSortBys = []PlatformPolicyFrameworkSortBy - -// PlatformPolicyRuleDetailSortBys defines model for platform_policy_rule_details_sort_bys. -type PlatformPolicyRuleDetailSortBys = []PlatformPolicyRuleDetailSortBy - -// PlatformPolicyRuleSortBys defines model for platform_policy_rules_sort_bys. -type PlatformPolicyRuleSortBys = []PlatformPolicyRuleSortBy - // PluginExcludeReleaseStages defines model for plugin_exclude_release_stages. type PluginExcludeReleaseStages = []PluginReleaseStage @@ -4298,6 +3826,9 @@ type SyncNameFilter = string // SyncRunId ID of the SyncRun type SyncRunId = SyncRunID +// SyncRunTableSortBys defines model for sync_run_table_sort_bys. +type SyncRunTableSortBys = []SyncRunTableSortBy + // SyncSortBys defines model for sync_sort_bys. type SyncSortBys = []SyncSortBy @@ -4364,9 +3895,6 @@ type VersionSortBy string // BadRequest defines model for BadRequest. type BadRequest = FieldError -// Conflict Basic Error -type Conflict = BasicError - // Forbidden defines model for Forbidden. type Forbidden = FieldError @@ -4391,322 +3919,6 @@ type TooManyRequests = BasicError // UnprocessableEntity defines model for UnprocessableEntity. type UnprocessableEntity = FieldError -// ListAuditLogsParams defines parameters for ListAuditLogs. -type ListAuditLogsParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // UserId Filter by user ID - UserId *openapi_types.UUID `form:"user_id,omitempty" json:"user_id,omitempty"` - - // TeamName Filter by team name - TeamName *string `form:"team_name,omitempty" json:"team_name,omitempty"` - - // EventType Filter by event type - EventType *string `form:"event_type,omitempty" json:"event_type,omitempty"` - - // EntityDisplayName Filter by entity display name - EntityDisplayName *string `form:"entity_display_name,omitempty" json:"entity_display_name,omitempty"` - - // UserIpAddress Filter by user IP address - UserIpAddress *string `form:"user_ip_address,omitempty" json:"user_ip_address,omitempty"` - - // StartTime Filter by start time (inclusive) - StartTime *time.Time `form:"start_time,omitempty" json:"start_time,omitempty"` - - // EndTime Filter by end time (inclusive) - EndTime *time.Time `form:"end_time,omitempty" json:"end_time,omitempty"` - - // Search Search across user name, team name, event type, entity display name, and user IP address - Search *string `form:"search,omitempty" json:"search,omitempty"` -} - -// AssetViewListLogsParams defines parameters for AssetViewListLogs. -type AssetViewListLogsParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // AssetViewRunTypes AssetView run type filters - AssetViewRunTypes *AssetViewRunTypes `form:"type,omitempty" json:"type,omitempty"` -} - -// ManageRegisterPlatformJSONBody defines parameters for ManageRegisterPlatform. -type ManageRegisterPlatformJSONBody struct { - // APIKey Team API key to activate platform with - APIKey string `json:"api_key"` -} - -// ManageRegisterPlatformWithOfflineLicenseJSONBody defines parameters for ManageRegisterPlatformWithOfflineLicense. -type ManageRegisterPlatformWithOfflineLicenseJSONBody struct { - // License Offline license - License []byte `json:"license"` -} - -// ManageListAllTeamsParams defines parameters for ManageListAllTeams. -type ManageListAllTeamsParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` -} - -// ManageRemoveTeamMemberJSONBody defines parameters for ManageRemoveTeamMember. -type ManageRemoveTeamMemberJSONBody struct { - // UserID ID of the User - UserID openapi_types.UUID `json:"user_id"` -} - -// ManageListTeamMembersParams defines parameters for ManageListTeamMembers. -type ManageListTeamMembersParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // UserSearch Search by user name or email - UserSearch *string `form:"user_search,omitempty" json:"user_search,omitempty"` - - // Role Search by user role. Only for default roles. - Role *RBACDefaultRole `form:"role,omitempty" json:"role,omitempty"` - - // CustomRoleId Search by custom role. - CustomRoleId *RBACCustomRoleID `form:"custom_role_id,omitempty" json:"custom_role_id,omitempty"` -} - -// ManageAddTeamMemberJSONBody defines parameters for ManageAddTeamMember. -type ManageAddTeamMemberJSONBody struct { - CustomRoles *[]RBACCustomRoleID `json:"custom_roles,omitempty"` - Roles *[]RBACDefaultRole `json:"roles,omitempty"` - - // UserID ID of the User - UserID openapi_types.UUID `json:"user_id"` -} - -// ListLocalUsersParams defines parameters for ListLocalUsers. -type ListLocalUsersParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` -} - -// AddLocalUserJSONBody defines parameters for AddLocalUser. -type AddLocalUserJSONBody struct { - Email string `json:"email"` - Name string `json:"name"` - Password *string `json:"password,omitempty"` - - // Roles Global roles for the user - Roles []AddLocalUserJSONBodyRoles `json:"roles"` -} - -// AddLocalUserJSONBodyRoles defines parameters for AddLocalUser. -type AddLocalUserJSONBodyRoles string - -// UpdateLocalUserJSONBody defines parameters for UpdateLocalUser. -type UpdateLocalUserJSONBody struct { - Email *string `json:"email,omitempty"` - Enabled *bool `json:"enabled,omitempty"` - Name *string `json:"name,omitempty"` - Password *string `json:"password,omitempty"` - - // Roles Global roles for the user - Roles *[]UpdateLocalUserJSONBodyRoles `json:"roles,omitempty"` -} - -// UpdateLocalUserJSONBodyRoles defines parameters for UpdateLocalUser. -type UpdateLocalUserJSONBodyRoles string - -// ListPlatformVersionsParams defines parameters for ListPlatformVersions. -type ListPlatformVersionsParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - -// ListPluginsParams defines parameters for ListPlugins. -type ListPluginsParams struct { - // SortBy The field to sort by - SortBy *ListPluginsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // IncludeReleaseStages Include these release stages in the response - IncludeReleaseStages *PluginIncludeReleaseStages `form:"include_release_stages,omitempty" json:"include_release_stages,omitempty"` - - // ExcludeReleaseStages Exclude these release stages from the response - ExcludeReleaseStages *PluginExcludeReleaseStages `form:"exclude_release_stages,omitempty" json:"exclude_release_stages,omitempty"` -} - -// ListPluginsParamsSortBy defines parameters for ListPlugins. -type ListPluginsParamsSortBy string - -// ListPluginVersionsParams defines parameters for ListPluginVersions. -type ListPluginVersionsParams struct { - // SortBy The field to sort by - SortBy *ListPluginVersionsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // IncludeDrafts Whether to include draft versions - IncludeDrafts *IncludeDrafts `form:"include_drafts,omitempty" json:"include_drafts,omitempty"` - - // IncludeFips Whether to include fips versions - IncludeFips *IncludeFips `form:"include_fips,omitempty" json:"include_fips,omitempty"` - - // IncludePrereleases Whether to include prerelease versions - IncludePrereleases *IncludePrereleases `form:"include_prereleases,omitempty" json:"include_prereleases,omitempty"` - VersionFilter *VersionFilter `form:"version_filter,omitempty" json:"version_filter,omitempty"` -} - -// ListPluginVersionsParamsSortBy defines parameters for ListPluginVersions. -type ListPluginVersionsParamsSortBy string - -// CreatePluginVersionJSONBody defines parameters for CreatePluginVersion. -type CreatePluginVersionJSONBody struct { - // Checksums List of SHA-256 checksums for this plugin version, one for each supported target. - Checksums []string `json:"checksums"` - - // Message A message describing what's new or changed in this version. - // This message will be displayed to users in the plugin's changelog. - // Supports limited markdown syntax. - Message string `json:"message"` - - // PackageType The package type of the plugin assets - PackageType PluginPackageType `json:"package_type"` - - // Protocols The CloudQuery protocols supported by this plugin version (only protocol 3 is supported by new plugins). - Protocols PluginProtocols `json:"protocols"` - - // SpecJsonSchema The specification of the plugin. This is a JSON schema that describes the configuration of the plugin. - SpecJsonSchema *PluginSpecJSONSchema `json:"spec_json_schema,omitempty"` - - // SupportedTargets The targets supported by this plugin version, formatted as _ - SupportedTargets []string `json:"supported_targets"` - UIID *openapi_types.UUID `json:"ui_id,omitempty"` -} - -// DownloadPluginAssetParams defines parameters for DownloadPluginAsset. -type DownloadPluginAssetParams struct { - Accept *string `json:"Accept,omitempty"` -} - -// DeletePluginVersionDocsJSONBody defines parameters for DeletePluginVersionDocs. -type DeletePluginVersionDocsJSONBody struct { - Names []PluginDocsPageName `json:"names"` -} - -// ListPluginVersionDocsParams defines parameters for ListPluginVersionDocs. -type ListPluginVersionDocsParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - -// ReplacePluginVersionDocsJSONBody defines parameters for ReplacePluginVersionDocs. -type ReplacePluginVersionDocsJSONBody struct { - Pages []PluginDocsPageCreate `json:"pages"` -} - -// CreatePluginVersionDocsJSONBody defines parameters for CreatePluginVersionDocs. -type CreatePluginVersionDocsJSONBody struct { - Pages []PluginDocsPageCreate `json:"pages"` -} - -// DeletePluginVersionTablesJSONBody defines parameters for DeletePluginVersionTables. -type DeletePluginVersionTablesJSONBody struct { - Names []PluginTableName `json:"names"` -} - -// ListPluginVersionTablesParams defines parameters for ListPluginVersionTables. -type ListPluginVersionTablesParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - -// CreatePluginVersionTablesJSONBody defines parameters for CreatePluginVersionTables. -type CreatePluginVersionTablesJSONBody struct { - Tables []PluginTableCreate `json:"tables"` -} - -// UploadPluginUIAssetsJSONBody defines parameters for UploadPluginUIAssets. -type UploadPluginUIAssetsJSONBody struct { - Assets []PluginUIAssetUploadRequest `json:"assets"` - UIID *openapi_types.UUID `json:"ui_id,omitempty"` -} - -// FinalizePluginUIAssetUploadJSONBody defines parameters for FinalizePluginUIAssetUpload. -type FinalizePluginUIAssetUploadJSONBody struct { - // UIID ID representing the finished upload - UIID string `json:"ui_id"` -} - -// AuthRegistryRequestParams defines parameters for AuthRegistryRequest. -type AuthRegistryRequestParams struct { - // Account Username used for `docker login` - Account *string `form:"account,omitempty" json:"account,omitempty"` - - // Service Service requesting the JWT token - Service *string `form:"service,omitempty" json:"service,omitempty"` - - // Scope Multi-value string containing the repository being access and the operation type (push/pull) - Scope *string `form:"scope,omitempty" json:"scope,omitempty"` - - // XMetaPluginVersion Plugin version name - XMetaPluginVersion *string `json:"X-Meta-Plugin-Version,omitempty"` - - // XMetaUserTeamName User's team name - XMetaUserTeamName *string `json:"X-Meta-User-Team-Name,omitempty"` -} - -// ListTeamsParams defines parameters for ListTeams. -type ListTeamsParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` -} - -// CreateTeamJSONBody defines parameters for CreateTeam. -type CreateTeamJSONBody struct { - // DisplayName The team's display name - DisplayName string `json:"display_name"` - - // Name The unique name for the team. - Name TeamName `json:"name"` -} - -// UpdateTeamJSONBody defines parameters for UpdateTeam. -type UpdateTeamJSONBody struct { - // DisplayName The team's display name - DisplayName *string `json:"display_name,omitempty"` -} - // ListAllAlertsParams defines parameters for ListAllAlerts. type ListAllAlertsParams struct { // PerPage The number of results per page (max 1000). @@ -4720,6 +3932,9 @@ type ListAllAlertsParams struct { // Enabled Enabled Enabled *Enabled `form:"enabled,omitempty" json:"enabled,omitempty"` + + // QueryTags Query tags + QueryTags QueryTags `form:"tag,omitempty" json:"tag,omitempty"` } // TestUnsavedAlertParams defines parameters for TestUnsavedAlert. @@ -4728,8 +3943,8 @@ type TestUnsavedAlertParams struct { QueryID *QueryID `form:"query_id,omitempty" json:"query_id,omitempty"` } -// ListTeamAPIKeysParams defines parameters for ListTeamAPIKeys. -type ListTeamAPIKeysParams struct { +// ListAPIKeysParams defines parameters for ListAPIKeys. +type ListAPIKeysParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -4737,28 +3952,43 @@ type ListTeamAPIKeysParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// CreateTeamAPIKeyJSONBody defines parameters for CreateTeamAPIKey. -type CreateTeamAPIKeyJSONBody struct { +// CreateAPIKeyJSONBody defines parameters for CreateAPIKey. +type CreateAPIKeyJSONBody struct { ExpiresAt time.Time `json:"expires_at"` // Name Name of the API key - Name APIKeyName `json:"name"` - Roles *[]APIKeyTeamRole `json:"roles,omitempty"` + Name APIKeyName `json:"name"` + Roles *[]RoleID `json:"roles,omitempty"` } -// ListConnectorsParams defines parameters for ListConnectors. -type ListConnectorsParams struct { +// ListAuditLogsParams defines parameters for ListAuditLogs. +type ListAuditLogsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` - // FilterType Filter connectors by a given type. - FilterType *string `form:"filter_type,omitempty" json:"filter_type,omitempty"` + // UserId Filter by user ID + UserId *openapi_types.UUID `form:"user_id,omitempty" json:"user_id,omitempty"` - // FilterPlugin Filter connectors by a given plugin reference. Mutually exclusive with `type`. - FilterPlugin *string `form:"filter_plugin,omitempty" json:"filter_plugin,omitempty"` + // EventType Filter by event type + EventType *string `form:"event_type,omitempty" json:"event_type,omitempty"` + + // EntityDisplayName Filter by entity display name + EntityDisplayName *string `form:"entity_display_name,omitempty" json:"entity_display_name,omitempty"` + + // UserIpAddress Filter by user IP address + UserIpAddress *string `form:"user_ip_address,omitempty" json:"user_ip_address,omitempty"` + + // StartTime Filter by start time (inclusive) + StartTime *time.Time `form:"start_time,omitempty" json:"start_time,omitempty"` + + // EndTime Filter by end time (inclusive) + EndTime *time.Time `form:"end_time,omitempty" json:"end_time,omitempty"` + + // Search Search across user name, event type, entity display name, and user IP address + Search *string `form:"search,omitempty" json:"search,omitempty"` } // ListAllCustomColumnsParams defines parameters for ListAllCustomColumns. @@ -4775,15 +4005,12 @@ type ListAllCustomColumnsParams struct { // CustomColumnSortDirections Custom column sort direction options CustomColumnSortDirections CustomColumnSortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` - // Table Filter columns by table name. - Table *string `form:"table,omitempty" json:"table,omitempty"` - // SearchTerm Filter columns by name, label, or description. SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` } -// ListFiltersTeamParams defines parameters for ListFiltersTeam. -type ListFiltersTeamParams struct { +// ListFiltersParams defines parameters for ListFilters. +type ListFiltersParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -4796,8 +4023,8 @@ type ListFiltersTeamParams struct { ExpressionFilter *FilterExpressionFilter `form:"expression_filter,omitempty" json:"expression_filter,omitempty"` } -// ListFilterTagsTeamParams defines parameters for ListFilterTagsTeam. -type ListFilterTagsTeamParams struct { +// ListFilterTagsParams defines parameters for ListFilterTags. +type ListFilterTagsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -4805,42 +4032,19 @@ type ListFilterTagsTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// CreateTeamImagesJSONBody defines parameters for CreateTeamImages. -type CreateTeamImagesJSONBody struct { - Images []TeamImageCreate `json:"images"` -} - -// DeleteTeamInvitationJSONBody defines parameters for DeleteTeamInvitation. -type DeleteTeamInvitationJSONBody struct { - Email openapi_types.Email `json:"email"` -} - -// ListTeamInvitationsParams defines parameters for ListTeamInvitations. -type ListTeamInvitationsParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - +// ListNotificationsParams defines parameters for ListNotifications. +type ListNotificationsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - -// AcceptTeamInvitationJSONBody defines parameters for AcceptTeamInvitation. -type AcceptTeamInvitationJSONBody struct { - Token openapi_types.UUID `json:"token"` -} -// RemoveTeamMembershipJSONBody defines parameters for RemoveTeamMembership. -type RemoveTeamMembershipJSONBody struct { - Email string `json:"email"` -} - -// GetTeamMembershipsParams defines parameters for GetTeamMemberships. -type GetTeamMembershipsParams struct { // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + // Severities Filter by policy severities (policy matches any) + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // PolicyGroupIds Filter by policy groups (policy matches any) + PolicyGroupIds *[]PolicyGroupID `form:"policy_group_ids,omitempty" json:"policy_group_ids,omitempty"` } // GetNotificationDestinationAlertsParams defines parameters for GetNotificationDestinationAlerts. @@ -4867,135 +4071,206 @@ type CreateAWSOnboardingJSONBody struct { SingleAccount bool `json:"single_account"` } -// ListPluginsByTeamParams defines parameters for ListPluginsByTeam. -type ListPluginsByTeamParams struct { +// ListPlatformVersionsParams defines parameters for ListPlatformVersions. +type ListPlatformVersionsParams struct { // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // IncludePrivate Whether to include private plugins - IncludePrivate *IncludePrivate `form:"include_private,omitempty" json:"include_private,omitempty"` } -// DownloadPluginAssetByTeamParams defines parameters for DownloadPluginAssetByTeam. -type DownloadPluginAssetByTeamParams struct { - Accept *string `json:"Accept,omitempty"` -} +// ListPluginsParams defines parameters for ListPlugins. +type ListPluginsParams struct { + // SortBy The field to sort by + SortBy *ListPluginsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` -// ListPoliciesParams defines parameters for ListPolicies. -type ListPoliciesParams struct { - // SearchTerm Filter policies by name. - SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + // IncludeReleaseStages Include these release stages in the response + IncludeReleaseStages *PluginIncludeReleaseStages `form:"include_release_stages,omitempty" json:"include_release_stages,omitempty"` + + // ExcludeReleaseStages Exclude these release stages from the response + ExcludeReleaseStages *PluginExcludeReleaseStages `form:"exclude_release_stages,omitempty" json:"exclude_release_stages,omitempty"` +} + +// ListPluginsParamsSortBy defines parameters for ListPlugins. +type ListPluginsParamsSortBy string + +// ListPluginVersionsParams defines parameters for ListPluginVersions. +type ListPluginVersionsParams struct { + // SortBy The field to sort by + SortBy *ListPluginVersionsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` + // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` - // PlatformPolicySortBys Sort by options - PlatformPolicySortBys PlatformPolicySortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - // PlatformPolicySortDirections Platform policies sort direction options - PlatformPolicySortDirections PlatformPolicySortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` + // IncludeDrafts Whether to include draft versions + IncludeDrafts *IncludeDrafts `form:"include_drafts,omitempty" json:"include_drafts,omitempty"` - // Sort DEPRECATED! Sorting order. - Sort *string `form:"sort,omitempty" json:"sort,omitempty"` + // IncludeFips Whether to include fips versions + IncludeFips *IncludeFips `form:"include_fips,omitempty" json:"include_fips,omitempty"` + + // IncludePrereleases Whether to include prerelease versions + IncludePrereleases *IncludePrereleases `form:"include_prereleases,omitempty" json:"include_prereleases,omitempty"` + VersionFilter *VersionFilter `form:"version_filter,omitempty" json:"version_filter,omitempty"` } -// ListAllFrameworksParams defines parameters for ListAllFrameworks. -type ListAllFrameworksParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` +// ListPluginVersionsParamsSortBy defines parameters for ListPluginVersions. +type ListPluginVersionsParamsSortBy string +// DownloadPluginAssetParams defines parameters for DownloadPluginAsset. +type DownloadPluginAssetParams struct { + Accept *string `json:"Accept,omitempty"` +} + +// ListPluginVersionTablesParams defines parameters for ListPluginVersionTables. +type ListPluginVersionTablesParams struct { // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` } -// ListPolicyFrameworksParams defines parameters for ListPolicyFrameworks. -type ListPolicyFrameworksParams struct { +// ListPoliciesParams defines parameters for ListPolicies. +type ListPoliciesParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` + Page *Page `form:"page,omitempty" json:"page,omitempty"` + PolicyStatus *PolicyStatus `form:"status,omitempty" json:"status,omitempty"` - // PlatformPolicyFrameworkSortBys Sort by options - PlatformPolicyFrameworkSortBys PlatformPolicyFrameworkSortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` + // Severities Filter by severities (policy matches any) + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` - // PlatformPolicySortDirections Platform policies sort direction options - PlatformPolicySortDirections PlatformPolicySortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` + // Domain Filter by domain + Domain *PolicyDomain `form:"domain,omitempty" json:"domain,omitempty"` - // SearchTerm Filter rules by name. - SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` + // PolicyGroupIds Filter by policy groups (policy matches any) + PolicyGroupIds *[]PolicyGroupID `form:"policy_group_ids,omitempty" json:"policy_group_ids,omitempty"` - // Sort DEPRECATED! Sorting order. - Sort *string `form:"sort,omitempty" json:"sort,omitempty"` + // Search Search in policy name and description + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // SortBy Field to sort by + SortBy *ListPoliciesParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` + + // SortDir Sort direction + SortDir *ListPoliciesParamsSortDir `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` } -// ListPolicyRulesParams defines parameters for ListPolicyRules. -type ListPolicyRulesParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` +// ListPoliciesParamsSortBy defines parameters for ListPolicies. +type ListPoliciesParamsSortBy string - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` +// ListPoliciesParamsSortDir defines parameters for ListPolicies. +type ListPoliciesParamsSortDir string - // PlatformPolicyRuleSortBys Sort by options - PlatformPolicyRuleSortBys PlatformPolicyRuleSortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` +// GetPolicyMetricsParams defines parameters for GetPolicyMetrics. +type GetPolicyMetricsParams struct { + // Severities Filter by severities (policy matches any) + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` - // PlatformPolicySortDirections Platform policies sort direction options - PlatformPolicySortDirections PlatformPolicySortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` + // Domain Filter by domain + Domain *PolicyDomain `form:"domain,omitempty" json:"domain,omitempty"` - // SearchTerm Filter rules by name. - SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` + // PolicyGroupIds Filter by policy groups (policy matches any) + PolicyGroupIds *[]PolicyGroupID `form:"policy_group_ids,omitempty" json:"policy_group_ids,omitempty"` +} - // Sort Sorting order. - Sort *string `form:"sort,omitempty" json:"sort,omitempty"` +// GetViolationsByDomainParams defines parameters for GetViolationsByDomain. +type GetViolationsByDomainParams struct { + // Severities Filter by severities (policy matches any) + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // Domain Filter by domain + Domain *PolicyDomain `form:"domain,omitempty" json:"domain,omitempty"` + + // PolicyGroupIds Filter by policy groups (policy matches any) + PolicyGroupIds *[]PolicyGroupID `form:"policy_group_ids,omitempty" json:"policy_group_ids,omitempty"` } -// ListPolicyRuleDetailsParams defines parameters for ListPolicyRuleDetails. -type ListPolicyRuleDetailsParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` +// GetViolationsHistoryParams defines parameters for GetViolationsHistory. +type GetViolationsHistoryParams struct { + // StartDate Start date for the query range (YYYY-MM-DD) + StartDate *openapi_types.Date `form:"start_date,omitempty" json:"start_date,omitempty"` + // EndDate End date for the query range (YYYY-MM-DD) + EndDate *openapi_types.Date `form:"end_date,omitempty" json:"end_date,omitempty"` + + // Severities Filter by severities (policy matches any) + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // Domain Filter by domain + Domain *PolicyDomain `form:"domain,omitempty" json:"domain,omitempty"` + + // PolicyGroupIds Filter by policy groups (policy matches any) + PolicyGroupIds *[]PolicyGroupID `form:"policy_group_ids,omitempty" json:"policy_group_ids,omitempty"` +} + +// GetPolicyViolationsParams defines parameters for GetPolicyViolations. +type GetPolicyViolationsParams struct { // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` - // PlatformPolicyRuleDetailSortBys Sort by options - PlatformPolicyRuleDetailSortBys PlatformPolicyRuleDetailSortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - // PlatformPolicySortDirections Platform policies sort direction options - PlatformPolicySortDirections PlatformPolicySortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` + // Search Text search term to filter violations by resource_type_label, name, account_name, cloud, or region + Search *string `form:"search,omitempty" json:"search,omitempty"` +} - // SearchTerm Filter rules by name. - SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` +// GetPolicyViolationsHistoryParams defines parameters for GetPolicyViolationsHistory. +type GetPolicyViolationsHistoryParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - // Sort DEPRECATED! Sorting order. - Sort *string `form:"sort,omitempty" json:"sort,omitempty"` + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + StartTime *time.Time `form:"start_time,omitempty" json:"start_time,omitempty"` + EndTime *time.Time `form:"end_time,omitempty" json:"end_time,omitempty"` } -// TogglePolicyParams defines parameters for TogglePolicy. -type TogglePolicyParams struct { - Status TogglePolicyParamsStatus `form:"status" json:"status"` +// ListPolicyGroupsParams defines parameters for ListPolicyGroups. +type ListPolicyGroupsParams struct { + // Search Search in policy group name and description + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // Severities Filter to policy groups that contain at least one policy with any of these severities + Severities *[]PolicySeverity `form:"severities,omitempty" json:"severities,omitempty"` } -// TogglePolicyParamsStatus defines parameters for TogglePolicy. -type TogglePolicyParamsStatus string +// ListPoliciesInGroupParams defines parameters for ListPoliciesInGroup. +type ListPoliciesInGroupParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -// GetPolicyViolationsHistoryParams defines parameters for GetPolicyViolationsHistory. -type GetPolicyViolationsHistoryParams struct { - // Start A valid ISO 8601 date string representing the inclusive start of the period within which to return history entities. Defaults to start of current month if not specified. - Start *time.Time `form:"start,omitempty" json:"start,omitempty"` + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` - // End A valid ISO 8601 date string representing the exclusive end of the period within which to return history entities. Defaults to end of current month if not specified. - End *time.Time `form:"end,omitempty" json:"end,omitempty"` + // SortBy Field to sort by + SortBy *ListPoliciesInGroupParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` + + // SortDir Sort direction + SortDir *ListPoliciesInGroupParamsSortDir `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` } -// ListAllQueriesTeamParams defines parameters for ListAllQueriesTeam. -type ListAllQueriesTeamParams struct { +// ListPoliciesInGroupParamsSortBy defines parameters for ListPoliciesInGroup. +type ListPoliciesInGroupParamsSortBy string + +// ListPoliciesInGroupParamsSortDir defines parameters for ListPoliciesInGroup. +type ListPoliciesInGroupParamsSortDir string + +// ListAllQueriesParams defines parameters for ListAllQueries. +type ListAllQueriesParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5015,13 +4290,13 @@ type ListAllQueriesTeamParams struct { AlertEnabled *AlertEnabled `form:"alert_enabled,omitempty" json:"alert_enabled,omitempty"` } -// ExecuteAdHocQueryTeamJSONBody defines parameters for ExecuteAdHocQueryTeam. -type ExecuteAdHocQueryTeamJSONBody struct { +// ExecuteAdHocQueryJSONBody defines parameters for ExecuteAdHocQuery. +type ExecuteAdHocQueryJSONBody struct { Query string `json:"query"` } -// ExecuteAdHocQueryTeamParams defines parameters for ExecuteAdHocQueryTeam. -type ExecuteAdHocQueryTeamParams struct { +// ExecuteAdHocQueryParams defines parameters for ExecuteAdHocQuery. +type ExecuteAdHocQueryParams struct { // Selects Table selects. This filters the columns that are returned in the result set. Selects Selects `form:"select,omitempty" json:"select,omitempty"` @@ -5035,7 +4310,7 @@ type ExecuteAdHocQueryTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *ExecuteAdHocQueryTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + FilterMode *ExecuteAdHocQueryParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` // Filters Table filters. This filters the rows that are returned in the result set. Filters Filters `form:"filter,omitempty" json:"filter,omitempty"` @@ -5060,11 +4335,11 @@ type ExecuteAdHocQueryTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// ExecuteAdHocQueryTeamParamsFilterMode defines parameters for ExecuteAdHocQueryTeam. -type ExecuteAdHocQueryTeamParamsFilterMode string +// ExecuteAdHocQueryParamsFilterMode defines parameters for ExecuteAdHocQuery. +type ExecuteAdHocQueryParamsFilterMode string -// ListQueryTagsTeamParams defines parameters for ListQueryTagsTeam. -type ListQueryTagsTeamParams struct { +// ListQueryTagsParams defines parameters for ListQueryTags. +type ListQueryTagsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5072,8 +4347,8 @@ type ListQueryTagsTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// ExecuteSavedQueryTeamParams defines parameters for ExecuteSavedQueryTeam. -type ExecuteSavedQueryTeamParams struct { +// ExecuteSavedQueryParams defines parameters for ExecuteSavedQuery. +type ExecuteSavedQueryParams struct { // Selects Table selects. This filters the columns that are returned in the result set. Selects Selects `form:"select,omitempty" json:"select,omitempty"` @@ -5087,7 +4362,7 @@ type ExecuteSavedQueryTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *ExecuteSavedQueryTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + FilterMode *ExecuteSavedQueryParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` // Filters Table filters. This filters the rows that are returned in the result set. Filters Filters `form:"filter,omitempty" json:"filter,omitempty"` @@ -5112,11 +4387,11 @@ type ExecuteSavedQueryTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// ExecuteSavedQueryTeamParamsFilterMode defines parameters for ExecuteSavedQueryTeam. -type ExecuteSavedQueryTeamParamsFilterMode string +// ExecuteSavedQueryParamsFilterMode defines parameters for ExecuteSavedQuery. +type ExecuteSavedQueryParamsFilterMode string -// QueryListFiltersTeamParams defines parameters for QueryListFiltersTeam. -type QueryListFiltersTeamParams struct { +// QueryListFiltersParams defines parameters for QueryListFilters. +type QueryListFiltersParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5127,8 +4402,8 @@ type QueryListFiltersTeamParams struct { FilterTags *FilterTags `form:"tag,omitempty" json:"tag,omitempty"` } -// QueryListFilterTagsTeamParams defines parameters for QueryListFilterTagsTeam. -type QueryListFilterTagsTeamParams struct { +// QueryListFilterTagsParams defines parameters for QueryListFilterTags. +type QueryListFilterTagsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5170,6 +4445,9 @@ type ListAllRBACRolesParams struct { // SearchTerm Filter roles by name or description. SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` + + // Type Filter roles by type. + Type *string `form:"type,omitempty" json:"type,omitempty"` } // ListReportsParams defines parameters for ListReports. @@ -5212,6 +4490,12 @@ type ListReportTemplatesParams struct { ReportTemplateSortDirections ReportTemplateSortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` } +// ListSlackChannelsParams defines parameters for ListSlackChannels. +type ListSlackChannelsParams struct { + // Name Filter channels by name (case-insensitive partial match) + Name *string `form:"name,omitempty" json:"name,omitempty"` +} + // UpdateSyncTestConnectionForSyncDestinationJSONBody defines parameters for UpdateSyncTestConnectionForSyncDestination. type UpdateSyncTestConnectionForSyncDestinationJSONBody struct { // FailureCode Code for failure @@ -5224,11 +4508,6 @@ type UpdateSyncTestConnectionForSyncDestinationJSONBody struct { Status SyncTestConnectionStatus `json:"status"` } -// GetSyncDestinationTestConnectionLogsParams defines parameters for GetSyncDestinationTestConnectionLogs. -type GetSyncDestinationTestConnectionLogsParams struct { - Accept *string `json:"Accept,omitempty"` -} - // GetSyncDestinationTestConnectionLogsLiveParams defines parameters for GetSyncDestinationTestConnectionLogsLive. type GetSyncDestinationTestConnectionLogsLiveParams struct { Accept *string `json:"Accept,omitempty"` @@ -5295,11 +4574,6 @@ type UpdateSyncTestConnectionForSyncSourceJSONBody struct { Status SyncTestConnectionStatus `json:"status"` } -// GetSyncSourceTestConnectionLogsParams defines parameters for GetSyncSourceTestConnectionLogs. -type GetSyncSourceTestConnectionLogsParams struct { - Accept *string `json:"Accept,omitempty"` -} - // GetSyncSourceTestConnectionLogsLiveParams defines parameters for GetSyncSourceTestConnectionLogsLive. type GetSyncSourceTestConnectionLogsLiveParams struct { Accept *string `json:"Accept,omitempty"` @@ -5446,12 +4720,6 @@ type UpdateSyncRunJSONBody struct { StatusReason *SyncRunStatusReason `json:"status_reason,omitempty"` } -// GetSyncRunLogsParams defines parameters for GetSyncRunLogs. -type GetSyncRunLogsParams struct { - Table *string `form:"table,omitempty" json:"table,omitempty"` - Accept *string `json:"Accept,omitempty"` -} - // GetSyncRunLogsLiveParams defines parameters for GetSyncRunLogsLive. type GetSyncRunLogsLiveParams struct { Table *string `form:"table,omitempty" json:"table,omitempty"` @@ -5506,15 +4774,15 @@ type GetSyncRunTablesParams struct { // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` - // SortBys Table sort by options. This sorts the rows that are returned in the result set. - SortBys SortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` + // SyncRunTableSortBys Sync run table sort by options. This sorts the rows that are returned in the result set. + SyncRunTableSortBys SyncRunTableSortBys `form:"sort_by,omitempty" json:"sort_by,omitempty"` // SortDirections Table sort direction options. This sorts the rows that are returned in the result set. SortDirections SortDirections `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` } -// ListTablesTeamParams defines parameters for ListTablesTeam. -type ListTablesTeamParams struct { +// ListTablesParams defines parameters for ListTables. +type ListTablesParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5522,14 +4790,23 @@ type ListTablesTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// BatchTableSchemasTeamParams defines parameters for BatchTableSchemasTeam. -type BatchTableSchemasTeamParams struct { +// GetTablesDataParams defines parameters for GetTablesData. +type GetTablesDataParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` +} + +// BatchTableSchemasParams defines parameters for BatchTableSchemas. +type BatchTableSchemasParams struct { // Tables A list of table names to retrieve schemas for Tables []string `form:"tables" json:"tables"` } -// TableListColumnsTeamParams defines parameters for TableListColumnsTeam. -type TableListColumnsTeamParams struct { +// TableListColumnsParams defines parameters for TableListColumns. +type TableListColumnsParams struct { // FilterMode Table filter mode. // // Smart mode switches between column and search mode based on the filtered table and @@ -5540,8 +4817,8 @@ type TableListColumnsTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *TableListColumnsTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` - Filter *TableColumnNameFilter `form:"filter,omitempty" json:"filter,omitempty"` + FilterMode *TableListColumnsParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + Filter *TableColumnNameFilter `form:"filter,omitempty" json:"filter,omitempty"` // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` @@ -5550,11 +4827,11 @@ type TableListColumnsTeamParams struct { PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` } -// TableListColumnsTeamParamsFilterMode defines parameters for TableListColumnsTeam. -type TableListColumnsTeamParamsFilterMode string +// TableListColumnsParamsFilterMode defines parameters for TableListColumns. +type TableListColumnsParamsFilterMode string -// TableColumnListValuesTeamParams defines parameters for TableColumnListValuesTeam. -type TableColumnListValuesTeamParams struct { +// TableColumnListValuesParams defines parameters for TableColumnListValues. +type TableColumnListValuesParams struct { // FilterMode Table filter mode. // // Smart mode switches between column and search mode based on the filtered table and @@ -5565,8 +4842,8 @@ type TableColumnListValuesTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *TableColumnListValuesTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` - Filter *TableColumnValueFilter `form:"filter,omitempty" json:"filter,omitempty"` + FilterMode *TableColumnListValuesParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + Filter *TableColumnValueFilter `form:"filter,omitempty" json:"filter,omitempty"` // Page Page number of the results to fetch Page *Page `form:"page,omitempty" json:"page,omitempty"` @@ -5575,11 +4852,11 @@ type TableColumnListValuesTeamParams struct { PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` } -// TableColumnListValuesTeamParamsFilterMode defines parameters for TableColumnListValuesTeam. -type TableColumnListValuesTeamParamsFilterMode string +// TableColumnListValuesParamsFilterMode defines parameters for TableColumnListValues. +type TableColumnListValuesParamsFilterMode string -// TableListRowsTeamParams defines parameters for TableListRowsTeam. -type TableListRowsTeamParams struct { +// TableListRowsParams defines parameters for TableListRows. +type TableListRowsParams struct { // Selects Table selects. This filters the columns that are returned in the result set. Selects Selects `form:"select,omitempty" json:"select,omitempty"` @@ -5593,7 +4870,7 @@ type TableListRowsTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *TableListRowsTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + FilterMode *TableListRowsParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` // Filters Table filters. This filters the rows that are returned in the result set. Filters Filters `form:"filter,omitempty" json:"filter,omitempty"` @@ -5618,11 +4895,11 @@ type TableListRowsTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// TableListRowsTeamParamsFilterMode defines parameters for TableListRowsTeam. -type TableListRowsTeamParamsFilterMode string +// TableListRowsParamsFilterMode defines parameters for TableListRows. +type TableListRowsParamsFilterMode string -// TableRowByIdTeamParams defines parameters for TableRowByIdTeam. -type TableRowByIdTeamParams struct { +// TableRowByIdParams defines parameters for TableRowById. +type TableRowByIdParams struct { // FilterMode Table filter mode. // // Smart mode switches between column and search mode based on the filtered table and @@ -5633,7 +4910,7 @@ type TableRowByIdTeamParams struct { // // Column mode searches purely using the columns in the table. // It will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables. - FilterMode *TableRowByIdTeamParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` + FilterMode *TableRowByIdParamsFilterMode `form:"filter_mode,omitempty" json:"filter_mode,omitempty"` // Filters Table filters. This filters the rows that are returned in the result set. Filters Filters `form:"filter,omitempty" json:"filter,omitempty"` @@ -5643,11 +4920,11 @@ type TableRowByIdTeamParams struct { FilterIDs FilterIDs `form:"filter_id,omitempty" json:"filter_id,omitempty"` } -// TableRowByIdTeamParamsFilterMode defines parameters for TableRowByIdTeam. -type TableRowByIdTeamParamsFilterMode string +// TableRowByIdParamsFilterMode defines parameters for TableRowById. +type TableRowByIdParamsFilterMode string -// TableListFiltersTeamParams defines parameters for TableListFiltersTeam. -type TableListFiltersTeamParams struct { +// TableListFiltersParams defines parameters for TableListFilters. +type TableListFiltersParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5658,8 +4935,8 @@ type TableListFiltersTeamParams struct { FilterTags *FilterTags `form:"tag,omitempty" json:"tag,omitempty"` } -// TableListFilterTagsTeamParams defines parameters for TableListFilterTagsTeam. -type TableListFilterTagsTeamParams struct { +// TableListFilterTagsParams defines parameters for TableListFilterTags. +type TableListFilterTagsParams struct { // PerPage The number of results per page (max 1000). PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` @@ -5667,10 +4944,66 @@ type TableListFilterTagsTeamParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } -// TableListRelationsTeamParams defines parameters for TableListRelationsTeam. -type TableListRelationsTeamParams struct { - // RelationName Filter by related table name - RelationName *string `form:"relation_name,omitempty" json:"relation_name,omitempty"` +// ListTeamsParams defines parameters for ListTeams. +type ListTeamsParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` +} + +// DownloadPluginAssetByTeamParams defines parameters for DownloadPluginAssetByTeam. +type DownloadPluginAssetByTeamParams struct { + Accept *string `json:"Accept,omitempty"` +} + +// UpdateSyncTestConnectionForSyncDestinationTeamJSONBody defines parameters for UpdateSyncTestConnectionForSyncDestinationTeam. +type UpdateSyncTestConnectionForSyncDestinationTeamJSONBody struct { + // FailureCode Code for failure + FailureCode *string `json:"failure_code,omitempty"` + + // FailureReason Reason for failure + FailureReason *string `json:"failure_reason,omitempty"` + + // Status The status of the sync run + Status SyncTestConnectionStatus `json:"status"` +} + +// UpdateSyncTestConnectionForSyncSourceTeamJSONBody defines parameters for UpdateSyncTestConnectionForSyncSourceTeam. +type UpdateSyncTestConnectionForSyncSourceTeamJSONBody struct { + // FailureCode Code for failure + FailureCode *string `json:"failure_code,omitempty"` + + // FailureReason Reason for failure + FailureReason *string `json:"failure_reason,omitempty"` + + // Status The status of the sync run + Status SyncTestConnectionStatus `json:"status"` +} + +// CreateSyncRunProgressTeamJSONBody defines parameters for CreateSyncRunProgressTeam. +type CreateSyncRunProgressTeamJSONBody struct { + // Errors Number of errors encountered so far + Errors int64 `json:"errors"` + + // Rows Number of rows synced so far + Rows int64 `json:"rows"` + + // ShardNum The shard number that this progress update is for + ShardNum *int32 `json:"shard_num,omitempty"` + + // ShardTotal The total number of shards for this sync run + ShardTotal *int32 `json:"shard_total,omitempty"` + + // Status The status of the sync run + Status *SyncRunStatus `json:"status,omitempty"` + + // TableProgress Table-specific progress information for a sync run + TableProgress *SyncRunTableProgress `json:"table_progress,omitempty"` + + // Warnings Number of warnings encountered so far + Warnings int64 `json:"warnings"` } // GetTeamUsageSummaryParams defines parameters for GetTeamUsageSummary. @@ -5708,21 +5041,6 @@ type GetGroupedTeamUsageSummaryParamsAggregationPeriod string // GetGroupedTeamUsageSummaryParamsGroupBy defines parameters for GetGroupedTeamUsageSummary. type GetGroupedTeamUsageSummaryParamsGroupBy string -// ListUsersByTeamParams defines parameters for ListUsersByTeam. -type ListUsersByTeamParams struct { - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` - - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` -} - -// UploadImageJSONBody defines parameters for UploadImage. -type UploadImageJSONBody struct { - // ContentType The HTTP Content-Type of the image or asset - ContentType ContentType `json:"content_type"` -} - // UpdateCurrentUserJSONBody defines parameters for UpdateCurrentUser. type UpdateCurrentUserJSONBody struct { // Name The unique name for the user. @@ -5744,14 +5062,14 @@ type SendAnonymousEventJSONBody struct { Properties *map[string]interface{} `json:"properties,omitempty"` } -// AuthenticateLocalUserJSONBody defines parameters for AuthenticateLocalUser. -type AuthenticateLocalUserJSONBody struct { +// AuthenticateUserJSONBody defines parameters for AuthenticateUser. +type AuthenticateUserJSONBody struct { Email string `json:"email"` Password string `json:"password"` } -// ChangeLocalUserPasswordJSONBody defines parameters for ChangeLocalUserPassword. -type ChangeLocalUserPasswordJSONBody struct { +// ChangeUserPasswordJSONBody defines parameters for ChangeUserPassword. +type ChangeUserPasswordJSONBody struct { Email string `json:"email"` NewPassword string `json:"new_password"` OldPassword string `json:"old_password"` @@ -5776,36 +5094,11 @@ type SendUserEventJSONBody struct { Properties *map[string]interface{} `json:"properties,omitempty"` } -// ListCurrentUserInvitationsParams defines parameters for ListCurrentUserInvitations. -type ListCurrentUserInvitationsParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - // LoginUserJSONBody defines parameters for LoginUser. type LoginUserJSONBody struct { IDToken string `json:"id_token"` } -// GetCurrentUserMembershipsParams defines parameters for GetCurrentUserMemberships. -type GetCurrentUserMembershipsParams struct { - // Page Page number of the results to fetch - Page *Page `form:"page,omitempty" json:"page,omitempty"` - - // PerPage The number of results per page (max 1000). - PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` -} - -// ResetLocalUserPasswordJSONBody defines parameters for ResetLocalUserPassword. -type ResetLocalUserPasswordJSONBody struct { - Email string `json:"email"` - NewPassword string `json:"new_password"` - ResetToken string `json:"reset_token"` -} - // UserTOTPVerifyJSONBody defines parameters for UserTOTPVerify. type UserTOTPVerifyJSONBody struct { OTP string `json:"otp"` @@ -5816,6 +5109,42 @@ type UserTOTPVerifyParams struct { CqpSess *string `form:"__cqp_sess,omitempty" json:"__cqp_sess,omitempty"` } +// ListUsersParams defines parameters for ListUsers. +type ListUsersParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // UserSearch Search by user name or email + UserSearch *string `form:"user_search,omitempty" json:"user_search,omitempty"` + + // RoleId Search by user role ID + RoleId *RoleID `form:"role_id,omitempty" json:"role_id,omitempty"` +} + +// AddUserJSONBody defines parameters for AddUser. +type AddUserJSONBody struct { + Email string `json:"email"` + Name string `json:"name"` + Password *string `json:"password,omitempty"` + + // Roles Roles for the user + Roles []RoleID `json:"roles"` +} + +// UpdateUserJSONBody defines parameters for UpdateUser. +type UpdateUserJSONBody struct { + Email *string `json:"email,omitempty"` + Enabled *bool `json:"enabled,omitempty"` + Name *string `json:"name,omitempty"` + Password *string `json:"password,omitempty"` + + // Roles Roles for the user + Roles *[]RoleID `json:"roles,omitempty"` +} + // GetV2SyncDestinationsParams defines parameters for GetV2SyncDestinations. type GetV2SyncDestinationsParams struct { // PerPage The number of results per page (max 1000). @@ -5848,95 +5177,20 @@ type ListV2SyncIntegrationsParams struct { Filter *SyncNameFilter `form:"filter,omitempty" json:"filter,omitempty"` } -// ManageUpdateSAMLJSONRequestBody defines body for ManageUpdateSAML for application/json ContentType. -type ManageUpdateSAMLJSONRequestBody = SAMLConfigUpdate - -// ManageRegisterPlatformJSONRequestBody defines body for ManageRegisterPlatform for application/json ContentType. -type ManageRegisterPlatformJSONRequestBody ManageRegisterPlatformJSONBody - -// ManageRegisterPlatformWithOfflineLicenseJSONRequestBody defines body for ManageRegisterPlatformWithOfflineLicense for application/json ContentType. -type ManageRegisterPlatformWithOfflineLicenseJSONRequestBody ManageRegisterPlatformWithOfflineLicenseJSONBody - -// UpdateSettingsJSONRequestBody defines body for UpdateSettings for application/json ContentType. -type UpdateSettingsJSONRequestBody = PlatformSettingsUpdate - -// ManageRemoveTeamMemberJSONRequestBody defines body for ManageRemoveTeamMember for application/json ContentType. -type ManageRemoveTeamMemberJSONRequestBody ManageRemoveTeamMemberJSONBody - -// ManageAddTeamMemberJSONRequestBody defines body for ManageAddTeamMember for application/json ContentType. -type ManageAddTeamMemberJSONRequestBody ManageAddTeamMemberJSONBody - -// AddLocalUserJSONRequestBody defines body for AddLocalUser for application/json ContentType. -type AddLocalUserJSONRequestBody AddLocalUserJSONBody - -// UpdateLocalUserJSONRequestBody defines body for UpdateLocalUser for application/json ContentType. -type UpdateLocalUserJSONRequestBody UpdateLocalUserJSONBody - -// CreatePluginJSONRequestBody defines body for CreatePlugin for application/json ContentType. -type CreatePluginJSONRequestBody = PluginCreate - -// UpdatePluginJSONRequestBody defines body for UpdatePlugin for application/json ContentType. -type UpdatePluginJSONRequestBody = PluginUpdate - -// UpdatePluginVersionJSONRequestBody defines body for UpdatePluginVersion for application/json ContentType. -type UpdatePluginVersionJSONRequestBody = PluginVersionUpdate - -// CreatePluginVersionJSONRequestBody defines body for CreatePluginVersion for application/json ContentType. -type CreatePluginVersionJSONRequestBody CreatePluginVersionJSONBody - -// DeletePluginVersionDocsJSONRequestBody defines body for DeletePluginVersionDocs for application/json ContentType. -type DeletePluginVersionDocsJSONRequestBody DeletePluginVersionDocsJSONBody - -// ReplacePluginVersionDocsJSONRequestBody defines body for ReplacePluginVersionDocs for application/json ContentType. -type ReplacePluginVersionDocsJSONRequestBody ReplacePluginVersionDocsJSONBody - -// CreatePluginVersionDocsJSONRequestBody defines body for CreatePluginVersionDocs for application/json ContentType. -type CreatePluginVersionDocsJSONRequestBody CreatePluginVersionDocsJSONBody - -// DeletePluginVersionTablesJSONRequestBody defines body for DeletePluginVersionTables for application/json ContentType. -type DeletePluginVersionTablesJSONRequestBody DeletePluginVersionTablesJSONBody - -// CreatePluginVersionTablesJSONRequestBody defines body for CreatePluginVersionTables for application/json ContentType. -type CreatePluginVersionTablesJSONRequestBody CreatePluginVersionTablesJSONBody - -// UploadPluginUIAssetsJSONRequestBody defines body for UploadPluginUIAssets for application/json ContentType. -type UploadPluginUIAssetsJSONRequestBody UploadPluginUIAssetsJSONBody - -// FinalizePluginUIAssetUploadJSONRequestBody defines body for FinalizePluginUIAssetUpload for application/json ContentType. -type FinalizePluginUIAssetUploadJSONRequestBody FinalizePluginUIAssetUploadJSONBody - -// CreateTeamJSONRequestBody defines body for CreateTeam for application/json ContentType. -type CreateTeamJSONRequestBody CreateTeamJSONBody - -// UpdateTeamJSONRequestBody defines body for UpdateTeam for application/json ContentType. -type UpdateTeamJSONRequestBody UpdateTeamJSONBody +// DeleteV2SyncIntegrationParams defines parameters for DeleteV2SyncIntegration. +type DeleteV2SyncIntegrationParams struct { + // DeleteData If true, also delete data associated with this integration from the relevant destinations. + DeleteData *bool `form:"delete_data,omitempty" json:"delete_data,omitempty"` +} // TestUnsavedAlertJSONRequestBody defines body for TestUnsavedAlert for application/json ContentType. type TestUnsavedAlertJSONRequestBody = AlertCreate -// CreateTeamAPIKeyJSONRequestBody defines body for CreateTeamAPIKey for application/json ContentType. -type CreateTeamAPIKeyJSONRequestBody CreateTeamAPIKeyJSONBody - -// CreateConnectorJSONRequestBody defines body for CreateConnector for application/json ContentType. -type CreateConnectorJSONRequestBody = ConnectorCreate - -// UpdateConnectorJSONRequestBody defines body for UpdateConnector for application/json ContentType. -type UpdateConnectorJSONRequestBody = ConnectorUpdate - -// AuthenticateConnectorFinishAWSJSONRequestBody defines body for AuthenticateConnectorFinishAWS for application/json ContentType. -type AuthenticateConnectorFinishAWSJSONRequestBody = ConnectorAuthFinishRequestAWS - -// AuthenticateConnectorAWSJSONRequestBody defines body for AuthenticateConnectorAWS for application/json ContentType. -type AuthenticateConnectorAWSJSONRequestBody = ConnectorAuthRequestAWS +// CreateAPIKeyJSONRequestBody defines body for CreateAPIKey for application/json ContentType. +type CreateAPIKeyJSONRequestBody CreateAPIKeyJSONBody -// AuthenticateConnectorGCPJSONRequestBody defines body for AuthenticateConnectorGCP for application/json ContentType. -type AuthenticateConnectorGCPJSONRequestBody = ConnectorAuthRequestGCP - -// AuthenticateConnectorFinishOAuthJSONRequestBody defines body for AuthenticateConnectorFinishOAuth for application/json ContentType. -type AuthenticateConnectorFinishOAuthJSONRequestBody = ConnectorAuthFinishRequestOAuth - -// AuthenticateConnectorOAuthJSONRequestBody defines body for AuthenticateConnectorOAuth for application/json ContentType. -type AuthenticateConnectorOAuthJSONRequestBody = ConnectorAuthRequestOAuth +// UpdateSAMLJSONRequestBody defines body for UpdateSAML for application/json ContentType. +type UpdateSAMLJSONRequestBody = SAMLConfigUpdate // CreateConversationJSONRequestBody defines body for CreateConversation for application/json ContentType. type CreateConversationJSONRequestBody = ConversationCreate @@ -5950,26 +5204,8 @@ type SaveCustomColumnJSONRequestBody = CustomColumnCreateOrUpdate // UpdateCustomColumnJSONRequestBody defines body for UpdateCustomColumn for application/json ContentType. type UpdateCustomColumnJSONRequestBody = CustomColumnCreateOrUpdate -// PutCustomColumnDataJSONRequestBody defines body for PutCustomColumnData for application/json ContentType. -type PutCustomColumnDataJSONRequestBody = CustomColumnDataImport - -// PutCustomColumnValuesJSONRequestBody defines body for PutCustomColumnValues for application/json ContentType. -type PutCustomColumnValuesJSONRequestBody = CustomColumnDataValues - -// UpdateFilterTeamJSONRequestBody defines body for UpdateFilterTeam for application/json ContentType. -type UpdateFilterTeamJSONRequestBody = FilterUpdate - -// CreateTeamImagesJSONRequestBody defines body for CreateTeamImages for application/json ContentType. -type CreateTeamImagesJSONRequestBody CreateTeamImagesJSONBody - -// DeleteTeamInvitationJSONRequestBody defines body for DeleteTeamInvitation for application/json ContentType. -type DeleteTeamInvitationJSONRequestBody DeleteTeamInvitationJSONBody - -// AcceptTeamInvitationJSONRequestBody defines body for AcceptTeamInvitation for application/json ContentType. -type AcceptTeamInvitationJSONRequestBody AcceptTeamInvitationJSONBody - -// RemoveTeamMembershipJSONRequestBody defines body for RemoveTeamMembership for application/json ContentType. -type RemoveTeamMembershipJSONRequestBody RemoveTeamMembershipJSONBody +// UpdateFilterJSONRequestBody defines body for UpdateFilter for application/json ContentType. +type UpdateFilterJSONRequestBody = FilterUpdate // UpdateNotificationDestinationJSONRequestBody defines body for UpdateNotificationDestination for application/json ContentType. type UpdateNotificationDestinationJSONRequestBody = NotificationDestinationUpdate @@ -5990,22 +5226,28 @@ type ProvisionOnboardingConfigurationJSONRequestBody = OnboardingAWSProvision type NotifyOnboardingJSONRequestBody = OnboardingAWSNotification // CreatePolicyJSONRequestBody defines body for CreatePolicy for application/json ContentType. -type CreatePolicyJSONRequestBody = PlatformCreateOrUpdatePolicy +type CreatePolicyJSONRequestBody = PolicyCreate // UpdatePolicyJSONRequestBody defines body for UpdatePolicy for application/json ContentType. -type UpdatePolicyJSONRequestBody = PlatformCreateOrUpdatePolicy +type UpdatePolicyJSONRequestBody = PolicyUpdate -// ExecuteAdHocQueryTeamJSONRequestBody defines body for ExecuteAdHocQueryTeam for application/json ContentType. -type ExecuteAdHocQueryTeamJSONRequestBody ExecuteAdHocQueryTeamJSONBody +// CreatePolicyGroupJSONRequestBody defines body for CreatePolicyGroup for application/json ContentType. +type CreatePolicyGroupJSONRequestBody = PolicyGroupCreate -// SaveQueryTeamJSONRequestBody defines body for SaveQueryTeam for application/json ContentType. -type SaveQueryTeamJSONRequestBody = QueryCreate +// UpdatePolicyGroupJSONRequestBody defines body for UpdatePolicyGroup for application/json ContentType. +type UpdatePolicyGroupJSONRequestBody = PolicyGroupUpdate -// UpdateQueryTeamJSONRequestBody defines body for UpdateQueryTeam for application/json ContentType. -type UpdateQueryTeamJSONRequestBody = QueryUpdate +// ExecuteAdHocQueryJSONRequestBody defines body for ExecuteAdHocQuery for application/json ContentType. +type ExecuteAdHocQueryJSONRequestBody ExecuteAdHocQueryJSONBody -// QuerySaveFilterTeamJSONRequestBody defines body for QuerySaveFilterTeam for application/json ContentType. -type QuerySaveFilterTeamJSONRequestBody = FilterCreate +// SaveQueryJSONRequestBody defines body for SaveQuery for application/json ContentType. +type SaveQueryJSONRequestBody = QueryCreate + +// UpdateQueryJSONRequestBody defines body for UpdateQuery for application/json ContentType. +type UpdateQueryJSONRequestBody = QueryUpdate + +// QuerySaveFilterJSONRequestBody defines body for QuerySaveFilter for application/json ContentType. +type QuerySaveFilterJSONRequestBody = FilterCreate // CreateRBACPermissionJSONRequestBody defines body for CreateRBACPermission for application/json ContentType. type CreateRBACPermissionJSONRequestBody = RBACPermissionCreate @@ -6031,6 +5273,15 @@ type UpdateReportTemplateJSONRequestBody = ReportTemplateCreateOrUpdate // UpdateReportJSONRequestBody defines body for UpdateReport for application/json ContentType. type UpdateReportJSONRequestBody = ReportUpdate +// UpdateSettingsJSONRequestBody defines body for UpdateSettings for application/json ContentType. +type UpdateSettingsJSONRequestBody = PlatformSettingsUpdate + +// UpdateDataSettingsJSONRequestBody defines body for UpdateDataSettings for application/json ContentType. +type UpdateDataSettingsJSONRequestBody = PlatformDataSettingsUpdate + +// CreateSlackConnectionJSONRequestBody defines body for CreateSlackConnection for application/json ContentType. +type CreateSlackConnectionJSONRequestBody = SlackConnectionCreate + // CreateSyncDestinationTestConnectionJSONRequestBody defines body for CreateSyncDestinationTestConnection for application/json ContentType. type CreateSyncDestinationTestConnectionJSONRequestBody = SyncDestinationTestConnectionCreate @@ -6070,11 +5321,20 @@ type UpdateSyncRunJSONRequestBody UpdateSyncRunJSONBody // CreateSyncRunProgressJSONRequestBody defines body for CreateSyncRunProgress for application/json ContentType. type CreateSyncRunProgressJSONRequestBody CreateSyncRunProgressJSONBody -// TableSaveFilterTeamJSONRequestBody defines body for TableSaveFilterTeam for application/json ContentType. -type TableSaveFilterTeamJSONRequestBody = FilterCreate +// TablesDataActionJSONRequestBody defines body for TablesDataAction for application/json ContentType. +type TablesDataActionJSONRequestBody = TableDataAction + +// TableSaveFilterJSONRequestBody defines body for TableSaveFilter for application/json ContentType. +type TableSaveFilterJSONRequestBody = FilterCreate + +// UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody defines body for UpdateSyncTestConnectionForSyncDestinationTeam for application/json ContentType. +type UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody UpdateSyncTestConnectionForSyncDestinationTeamJSONBody -// UploadImageJSONRequestBody defines body for UploadImage for application/json ContentType. -type UploadImageJSONRequestBody UploadImageJSONBody +// UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody defines body for UpdateSyncTestConnectionForSyncSourceTeam for application/json ContentType. +type UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody UpdateSyncTestConnectionForSyncSourceTeamJSONBody + +// CreateSyncRunProgressTeamJSONRequestBody defines body for CreateSyncRunProgressTeam for application/json ContentType. +type CreateSyncRunProgressTeamJSONRequestBody CreateSyncRunProgressTeamJSONBody // UpdateCurrentUserJSONRequestBody defines body for UpdateCurrentUser for application/json ContentType. type UpdateCurrentUserJSONRequestBody UpdateCurrentUserJSONBody @@ -6082,11 +5342,11 @@ type UpdateCurrentUserJSONRequestBody UpdateCurrentUserJSONBody // SendAnonymousEventJSONRequestBody defines body for SendAnonymousEvent for application/json ContentType. type SendAnonymousEventJSONRequestBody SendAnonymousEventJSONBody -// AuthenticateLocalUserJSONRequestBody defines body for AuthenticateLocalUser for application/json ContentType. -type AuthenticateLocalUserJSONRequestBody AuthenticateLocalUserJSONBody +// AuthenticateUserJSONRequestBody defines body for AuthenticateUser for application/json ContentType. +type AuthenticateUserJSONRequestBody AuthenticateUserJSONBody -// ChangeLocalUserPasswordJSONRequestBody defines body for ChangeLocalUserPassword for application/json ContentType. -type ChangeLocalUserPasswordJSONRequestBody ChangeLocalUserPasswordJSONBody +// ChangeUserPasswordJSONRequestBody defines body for ChangeUserPassword for application/json ContentType. +type ChangeUserPasswordJSONRequestBody ChangeUserPasswordJSONBody // UpdateCustomerJSONRequestBody defines body for UpdateCustomer for application/json ContentType. type UpdateCustomerJSONRequestBody UpdateCustomerJSONBody @@ -6097,12 +5357,15 @@ type SendUserEventJSONRequestBody SendUserEventJSONBody // LoginUserJSONRequestBody defines body for LoginUser for application/json ContentType. type LoginUserJSONRequestBody LoginUserJSONBody -// ResetLocalUserPasswordJSONRequestBody defines body for ResetLocalUserPassword for application/json ContentType. -type ResetLocalUserPasswordJSONRequestBody ResetLocalUserPasswordJSONBody - // UserTOTPVerifyJSONRequestBody defines body for UserTOTPVerify for application/json ContentType. type UserTOTPVerifyJSONRequestBody UserTOTPVerifyJSONBody +// AddUserJSONRequestBody defines body for AddUser for application/json ContentType. +type AddUserJSONRequestBody AddUserJSONBody + +// UpdateUserJSONRequestBody defines body for UpdateUser for application/json ContentType. +type UpdateUserJSONRequestBody UpdateUserJSONBody + // CreateV2SyncDestinationTestConnectionJSONRequestBody defines body for CreateV2SyncDestinationTestConnection for application/json ContentType. type CreateV2SyncDestinationTestConnectionJSONRequestBody = CreateSyncDestinationTestConnectionV2 @@ -6409,838 +5672,608 @@ type ClientInterface interface { // Index request Index(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListAuditLogs request - ListAuditLogs(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetAuditLog request - GetAuditLog(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // HealthCheck request - HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // HealthCheckHead request - HealthCheckHead(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AssetViewGetStatus request - AssetViewGetStatus(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AssetViewTrigger request - AssetViewTrigger(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AssetViewListLogs request - AssetViewListLogs(ctx context.Context, params *AssetViewListLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageGetSAML request - ManageGetSAML(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageUpdateSAMLWithBody request with any body - ManageUpdateSAMLWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ManageUpdateSAML(ctx context.Context, body ManageUpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageGetPlatformRegistry request - ManageGetPlatformRegistry(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageRegisterPlatformWithBody request with any body - ManageRegisterPlatformWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ManageRegisterPlatform(ctx context.Context, body ManageRegisterPlatformJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageRegisterPlatformWithOfflineLicenseWithBody request with any body - ManageRegisterPlatformWithOfflineLicenseWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ManageRegisterPlatformWithOfflineLicense(ctx context.Context, body ManageRegisterPlatformWithOfflineLicenseJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetSettings request - GetSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UpdateSettingsWithBody request with any body - UpdateSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateSettings(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageListAllTeams request - ManageListAllTeams(ctx context.Context, params *ManageListAllTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageDeleteTeam request - ManageDeleteTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageGetTeam request - ManageGetTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageRemoveTeamMemberWithBody request with any body - ManageRemoveTeamMemberWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ManageRemoveTeamMember(ctx context.Context, teamName TeamName, body ManageRemoveTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageListTeamMembers request - ManageListTeamMembers(ctx context.Context, teamName TeamName, params *ManageListTeamMembersParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageAddTeamMemberWithBody request with any body - ManageAddTeamMemberWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ManageAddTeamMember(ctx context.Context, teamName TeamName, body ManageAddTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListLocalUsers request - ListLocalUsers(ctx context.Context, params *ListLocalUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AddLocalUserWithBody request with any body - AddLocalUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - AddLocalUser(ctx context.Context, body AddLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeleteLocalUser request - DeleteLocalUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetLocalUser request - GetLocalUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UpdateLocalUserWithBody request with any body - UpdateLocalUserWithBody(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateLocalUser(ctx context.Context, userID UserID, body UpdateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreateLocalUserResetToken request - CreateLocalUserResetToken(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ManageUserTOTPDelete request - ManageUserTOTPDelete(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetOpenAPIJSON request - GetOpenAPIJSON(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetPlatformInfo request - GetPlatformInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListPlatformVersions request - ListPlatformVersions(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListPlugins request - ListPlugins(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreatePluginWithBody request with any body - CreatePluginWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreatePlugin(ctx context.Context, body CreatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeletePluginByTeamAndPluginName request - DeletePluginByTeamAndPluginName(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetPlugin request - GetPlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UpdatePluginWithBody request with any body - UpdatePluginWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdatePlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, body UpdatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListPluginVersions request - ListPluginVersions(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetPluginVersion request - GetPluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UpdatePluginVersionWithBody request with any body - UpdatePluginVersionWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdatePluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UpdatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreatePluginVersionWithBody request with any body - CreatePluginVersionWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreatePluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DownloadPluginAsset request - DownloadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UploadPluginAsset request - UploadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeletePluginVersionDocsWithBody request with any body - DeletePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - DeletePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListPluginVersionDocs request - ListPluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionDocsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ReplacePluginVersionDocsWithBody request with any body - ReplacePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ReplacePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body ReplacePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreatePluginVersionDocsWithBody request with any body - CreatePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreatePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeletePluginVersionTablesWithBody request with any body - DeletePluginVersionTablesWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - DeletePluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListPluginVersionTables request - ListPluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreatePluginVersionTablesWithBody request with any body - CreatePluginVersionTablesWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreatePluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetPluginVersionTable request - GetPluginVersionTable(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*http.Response, error) - - // RemovePluginUIAssets request - RemovePluginUIAssets(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UploadPluginUIAssetsWithBody request with any body - UploadPluginUIAssetsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UploadPluginUIAssets(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UploadPluginUIAssetsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // FinalizePluginUIAssetUploadWithBody request with any body - FinalizePluginUIAssetUploadWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - FinalizePluginUIAssetUpload(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body FinalizePluginUIAssetUploadJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AuthRegistryRequest request - AuthRegistryRequest(ctx context.Context, params *AuthRegistryRequestParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListTeams request - ListTeams(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreateTeamWithBody request with any body - CreateTeamWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreateTeam(ctx context.Context, body CreateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeleteTeam request - DeleteTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetTeamByName request - GetTeamByName(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) - - // UpdateTeamWithBody request with any body - UpdateTeamWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateTeam(ctx context.Context, teamName TeamName, body UpdateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListAllAlerts request - ListAllAlerts(ctx context.Context, teamName TeamName, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAllAlerts(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // TestUnsavedAlertWithBody request with any body - TestUnsavedAlertWithBody(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - TestUnsavedAlert(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListTeamAPIKeys request - ListTeamAPIKeys(ctx context.Context, teamName TeamName, params *ListTeamAPIKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreateTeamAPIKeyWithBody request with any body - CreateTeamAPIKeyWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreateTeamAPIKey(ctx context.Context, teamName TeamName, body CreateTeamAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + TestUnsavedAlertWithBody(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // DeleteTeamAPIKey request - DeleteTeamAPIKey(ctx context.Context, teamName TeamName, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*http.Response, error) + TestUnsavedAlert(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListConnectors request - ListConnectors(ctx context.Context, teamName TeamName, params *ListConnectorsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListAPIKeys request + ListAPIKeys(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // CreateConnectorWithBody request with any body - CreateConnectorWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreateAPIKeyWithBody request with any body + CreateAPIKeyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateConnector(ctx context.Context, teamName TeamName, body CreateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateAPIKey(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetConnector request - GetConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) + // DeleteAPIKey request + DeleteAPIKey(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*http.Response, error) - // UpdateConnectorWithBody request with any body - UpdateConnectorWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, body UpdateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // RevokeConnector request - RevokeConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetConnectorAuthStatusAWS request - GetConnectorAuthStatusAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AuthenticateConnectorFinishAWSWithBody request with any body - AuthenticateConnectorFinishAWSWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - AuthenticateConnectorFinishAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AuthenticateConnectorAWSWithBody request with any body - AuthenticateConnectorAWSWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - AuthenticateConnectorAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetConnectorAuthStatusGCP request - GetConnectorAuthStatusGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AuthenticateConnectorGCPWithBody request with any body - AuthenticateConnectorGCPWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - AuthenticateConnectorGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorGCPJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AuthenticateConnectorFinishGCP request - AuthenticateConnectorFinishGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListAuditLogs request + ListAuditLogs(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // AuthenticateConnectorFinishOAuthWithBody request with any body - AuthenticateConnectorFinishOAuthWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetAuditLog request + GetAuditLog(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) - AuthenticateConnectorFinishOAuth(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetSAML request + GetSAML(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // AuthenticateConnectorOAuthWithBody request with any body - AuthenticateConnectorOAuthWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // UpdateSAMLWithBody request with any body + UpdateSAMLWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - AuthenticateConnectorOAuth(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSAML(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateConversationWithBody request with any body - CreateConversationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateConversationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateConversation(ctx context.Context, teamName TeamName, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateConversation(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetConversation request - GetConversation(ctx context.Context, teamName TeamName, conversationID ConversationID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetConversation(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*http.Response, error) // SendMessageWithBody request with any body - SendMessageWithBody(ctx context.Context, teamName TeamName, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + SendMessageWithBody(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - SendMessage(ctx context.Context, teamName TeamName, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + SendMessage(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListAllCustomColumns request - ListAllCustomColumns(ctx context.Context, teamName TeamName, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAllCustomColumns(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // SaveCustomColumnWithBody request with any body - SaveCustomColumnWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + SaveCustomColumnWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - SaveCustomColumn(ctx context.Context, teamName TeamName, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + SaveCustomColumn(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteCustomColumn request - DeleteCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteCustomColumn(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetCustomColumn request - GetCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetCustomColumn(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateCustomColumnWithBody request with any body - UpdateCustomColumnWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // PutCustomColumnDataWithBody request with any body - PutCustomColumnDataWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateCustomColumnWithBody(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - PutCustomColumnData(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnDataJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateCustomColumn(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // PutCustomColumnValuesWithBody request with any body - PutCustomColumnValuesWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListFilters request + ListFilters(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) - PutCustomColumnValues(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnValuesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListFilterTags request + ListFilterTags(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListFiltersTeam request - ListFiltersTeam(ctx context.Context, teamName TeamName, params *ListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // DeleteFilter request + DeleteFilter(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListFilterTagsTeam request - ListFilterTagsTeam(ctx context.Context, teamName TeamName, params *ListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetFilterByID request + GetFilterByID(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) - // DeleteFilterTeam request - DeleteFilterTeam(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) + // UpdateFilterWithBody request with any body + UpdateFilterWithBody(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetFilterByIDTeam request - GetFilterByIDTeam(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateFilter(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // UpdateFilterTeamWithBody request with any body - UpdateFilterTeamWithBody(ctx context.Context, teamName TeamName, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateFilterTeam(ctx context.Context, teamName TeamName, filterID FilterID, body UpdateFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreateTeamImagesWithBody request with any body - CreateTeamImagesWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreateTeamImages(ctx context.Context, teamName TeamName, body CreateTeamImagesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // DeleteTeamInvitationWithBody request with any body - DeleteTeamInvitationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - DeleteTeamInvitation(ctx context.Context, teamName TeamName, body DeleteTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ListTeamInvitations request - ListTeamInvitations(ctx context.Context, teamName TeamName, params *ListTeamInvitationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // AcceptTeamInvitationWithBody request with any body - AcceptTeamInvitationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - AcceptTeamInvitation(ctx context.Context, teamName TeamName, body AcceptTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // RemoveTeamMembershipWithBody request with any body - RemoveTeamMembershipWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - RemoveTeamMembership(ctx context.Context, teamName TeamName, body RemoveTeamMembershipJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // HealthCheck request + HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetTeamMemberships request - GetTeamMemberships(ctx context.Context, teamName TeamName, params *GetTeamMembershipsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // HealthCheckHead request + HealthCheckHead(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // DeleteTeamMembership request - DeleteTeamMembership(ctx context.Context, teamName TeamName, email EmailBasic, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListNotifications request + ListNotifications(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteNotificationDestination request - DeleteNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) // GetNotificationDestination request - GetNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateNotificationDestinationWithBody request with any body - UpdateNotificationDestinationWithBody(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateNotificationDestinationWithBody(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetNotificationDestinationAlerts request - GetNotificationDestinationAlerts(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetNotificationDestinationAlerts(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // TestNotificationDestination request - TestNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) + TestNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) // ListAllNotificationDestinations request - ListAllNotificationDestinations(ctx context.Context, teamName TeamName, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAllNotificationDestinations(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateNotificationDestinationWithBody request with any body - CreateNotificationDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateNotificationDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateNotificationDestination(ctx context.Context, teamName TeamName, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateNotificationDestination(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // TestUnsavedNotificationDestinationWithBody request with any body - TestUnsavedNotificationDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + TestUnsavedNotificationDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - TestUnsavedNotificationDestination(ctx context.Context, teamName TeamName, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + TestUnsavedNotificationDestination(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateAWSOnboardingWithBody request with any body - CreateAWSOnboardingWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateAWSOnboardingWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateAWSOnboarding(ctx context.Context, teamName TeamName, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateAWSOnboarding(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetAWSOnboarding request - GetAWSOnboarding(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetAWSOnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetAWSAccountsInRoot request - GetAWSAccountsInRoot(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetAWSAccountsInRoot(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) // ProvisionOnboardingConfigurationWithBody request with any body - ProvisionOnboardingConfigurationWithBody(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + ProvisionOnboardingConfigurationWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - ProvisionOnboardingConfiguration(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + ProvisionOnboardingConfiguration(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetAWSAccountsInParent request - GetAWSAccountsInParent(ctx context.Context, teamName TeamName, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetAWSAccountsInParent(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*http.Response, error) // NotifyOnboardingWithBody request with any body - NotifyOnboardingWithBody(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + NotifyOnboardingWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - NotifyOnboarding(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + NotifyOnboarding(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // DeletePluginsByTeam request - DeletePluginsByTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetOpenAPIJSON request + GetOpenAPIJSON(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListPluginsByTeam request - ListPluginsByTeam(ctx context.Context, teamName TeamName, params *ListPluginsByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetPlatformInfo request + GetPlatformInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // DownloadPluginAssetByTeam request - DownloadPluginAssetByTeam(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListPlatformVersions request + ListPlatformVersions(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListPlugins request + ListPlugins(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPlugin request + GetPlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListPluginVersions request + ListPluginVersions(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPluginVersion request + GetPluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DownloadPluginAsset request + DownloadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListPluginVersionTables request + ListPluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPluginVersionTable request + GetPluginVersionTable(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*http.Response, error) // ListPolicies request - ListPolicies(ctx context.Context, teamName TeamName, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListPolicies(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreatePolicyWithBody request with any body - CreatePolicyWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreatePolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + CreatePolicy(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - CreatePolicy(ctx context.Context, teamName TeamName, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetPolicyMetrics request + GetPolicyMetrics(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListAllFrameworks request - ListAllFrameworks(ctx context.Context, teamName TeamName, params *ListAllFrameworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetViolationsByDomain request + GetViolationsByDomain(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetViolationsHistory request + GetViolationsHistory(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) // DeletePolicy request - DeletePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeletePolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetPolicy request - GetPolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetPolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdatePolicyWithBody request with any body - UpdatePolicyWithBody(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdatePolicyWithBody(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdatePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdatePolicy(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListPolicyFrameworks request - ListPolicyFrameworks(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyFrameworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TogglePolicy request + TogglePolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListPolicyRules request - ListPolicyRules(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetPolicyViolations request + GetPolicyViolations(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListPolicyRuleDetails request - ListPolicyRuleDetails(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, ruleId openapi_types.UUID, params *ListPolicyRuleDetailsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetPolicyViolationsHistory request + GetPolicyViolationsHistory(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TogglePolicy request - TogglePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *TogglePolicyParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListPolicyGroups request + ListPolicyGroups(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetPolicyViolationsHistory request - GetPolicyViolationsHistory(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreatePolicyGroupWithBody request with any body + CreatePolicyGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + CreatePolicyGroup(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeletePolicyGroup request + DeletePolicyGroup(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListPoliciesInGroup request + ListPoliciesInGroup(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdatePolicyGroupWithBody request with any body + UpdatePolicyGroupWithBody(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListAllQueriesTeam request - ListAllQueriesTeam(ctx context.Context, teamName TeamName, params *ListAllQueriesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdatePolicyGroup(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ExecuteAdHocQueryTeamWithBody request with any body - ExecuteAdHocQueryTeamWithBody(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListAllQueries request + ListAllQueries(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*http.Response, error) - ExecuteAdHocQueryTeam(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, body ExecuteAdHocQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // ExecuteAdHocQueryWithBody request with any body + ExecuteAdHocQueryWithBody(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // SaveQueryTeamWithBody request with any body - SaveQueryTeamWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + ExecuteAdHocQuery(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - SaveQueryTeam(ctx context.Context, teamName TeamName, body SaveQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // SaveQueryWithBody request with any body + SaveQueryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListQueryTagsTeam request - ListQueryTagsTeam(ctx context.Context, teamName TeamName, params *ListQueryTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + SaveQuery(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // DeleteSavedQueryTeam request - DeleteSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListQueryTags request + ListQueryTags(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetSavedQueryTeam request - GetSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) + // DeleteSavedQuery request + DeleteSavedQuery(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) - // UpdateQueryTeamWithBody request with any body - UpdateQueryTeamWithBody(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetSavedQuery request + GetSavedQuery(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, body UpdateQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // UpdateQueryWithBody request with any body + UpdateQueryWithBody(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateQuery(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteAlert request - DeleteAlert(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteAlert(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) - // ExecuteSavedQueryTeam request - ExecuteSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *ExecuteSavedQueryTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ExecuteSavedQuery request + ExecuteSavedQuery(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // QueryListFiltersTeam request - QueryListFiltersTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // QueryListFilters request + QueryListFilters(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // QuerySaveFilterTeamWithBody request with any body - QuerySaveFilterTeamWithBody(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // QuerySaveFilterWithBody request with any body + QuerySaveFilterWithBody(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - QuerySaveFilterTeam(ctx context.Context, teamName TeamName, queryID QueryID, body QuerySaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + QuerySaveFilter(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // QueryListFilterTagsTeam request - QueryListFilterTagsTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // QueryListFilterTags request + QueryListFilterTags(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // ListAllRBACPermissions request - ListAllRBACPermissions(ctx context.Context, teamName TeamName, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAllRBACPermissions(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateRBACPermissionWithBody request with any body - CreateRBACPermissionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateRBACPermissionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateRBACPermission(ctx context.Context, teamName TeamName, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateRBACPermission(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteRBACPermission request - DeleteRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetRBACPermission request - GetRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateRBACPermissionWithBody request with any body - UpdateRBACPermissionWithBody(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateRBACPermissionWithBody(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListAllRBACRoles request - ListAllRBACRoles(ctx context.Context, teamName TeamName, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListAllRBACRoles(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateRBACRoleWithBody request with any body - CreateRBACRoleWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateRBACRoleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateRBACRole(ctx context.Context, teamName TeamName, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateRBACRole(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteRBACRole request - DeleteRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteRBACRole(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetRBACRole request - GetRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetRBACRole(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateRBACRoleWithBody request with any body - UpdateRBACRoleWithBody(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateRBACRoleWithBody(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateRBACRole(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListReports request - ListReports(ctx context.Context, teamName TeamName, params *ListReportsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListReports(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateReportWithBody request with any body - CreateReportWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateReportWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateReport(ctx context.Context, teamName TeamName, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateReport(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListReportTemplates request - ListReportTemplates(ctx context.Context, teamName TeamName, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListReportTemplates(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateReportTemplateWithBody request with any body - CreateReportTemplateWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateReportTemplateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateReportTemplate(ctx context.Context, teamName TeamName, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateReportTemplate(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteReportTemplate request - DeleteReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteReportTemplate(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetReportTemplate request - GetReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetReportTemplate(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateReportTemplateWithBody request with any body - UpdateReportTemplateWithBody(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateReportTemplateWithBody(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateReportTemplate(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteReport request - DeleteReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteReport(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) // GetReport request - GetReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetReport(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateReportWithBody request with any body - UpdateReportWithBody(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateReportWithBody(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateReport(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetSettings request + GetSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdateSettingsWithBody request with any body + UpdateSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateSettings(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDataSettings request + GetDataSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdateDataSettingsWithBody request with any body + UpdateDataSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateDataSettings(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // CreateSlackConnectionWithBody request with any body + CreateSlackConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + CreateSlackConnection(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // ListSlackChannels request + ListSlackChannels(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateSyncDestinationTestConnectionWithBody request with any body - CreateSyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncDestinationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateSyncDestinationTestConnection(ctx context.Context, teamName TeamName, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncDestinationTestConnection(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncDestinationTestConnection request - GetSyncDestinationTestConnection(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncDestinationTestConnection(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncTestConnectionForSyncDestinationWithBody request with any body - UpdateSyncTestConnectionForSyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateSyncTestConnectionForSyncDestination(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTestConnectionForSyncDestinationWithBody(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetSyncDestinationTestConnectionLogs request - GetSyncDestinationTestConnectionLogs(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTestConnectionForSyncDestination(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncDestinationTestConnectionLogsLive request - GetSyncDestinationTestConnectionLogsLive(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncDestinationTestConnectionLogsLive(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncDestinationTestConnectionLogsQuery request - GetSyncDestinationTestConnectionLogsQuery(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncDestinationTestConnectionLogsQuery(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) // PromoteSyncDestinationTestConnectionWithBody request with any body - PromoteSyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + PromoteSyncDestinationTestConnectionWithBody(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - PromoteSyncDestinationTestConnection(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + PromoteSyncDestinationTestConnection(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncDestinations request - ListSyncDestinations(ctx context.Context, teamName TeamName, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncDestinations(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteSyncDestination request - DeleteSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncDestination request - GetSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncDestinationWithBody request with any body - UpdateSyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncDestinationWithBody(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // MigrateSyncDestination request - MigrateSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncDestinationSyncs request - ListSyncDestinationSyncs(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncDestinationSyncs(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetTestConnectionForSyncDestination request - GetTestConnectionForSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) + GetTestConnectionForSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateSyncSourceTestConnectionWithBody request with any body - CreateSyncSourceTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncSourceTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateSyncSourceTestConnection(ctx context.Context, teamName TeamName, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncSourceTestConnection(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncSourceTestConnection request - GetSyncSourceTestConnection(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncSourceTestConnection(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncTestConnectionForSyncSourceWithBody request with any body - UpdateSyncTestConnectionForSyncSourceWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateSyncTestConnectionForSyncSource(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTestConnectionForSyncSourceWithBody(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetSyncSourceTestConnectionLogs request - GetSyncSourceTestConnectionLogs(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTestConnectionForSyncSource(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncSourceTestConnectionLogsLive request - GetSyncSourceTestConnectionLogsLive(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncSourceTestConnectionLogsLive(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncSourceTestConnectionLogsQuery request - GetSyncSourceTestConnectionLogsQuery(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncSourceTestConnectionLogsQuery(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) // PromoteSyncSourceTestConnectionWithBody request with any body - PromoteSyncSourceTestConnectionWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + PromoteSyncSourceTestConnectionWithBody(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - PromoteSyncSourceTestConnection(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + PromoteSyncSourceTestConnection(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncSources request - ListSyncSources(ctx context.Context, teamName TeamName, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncSources(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteSyncSource request - DeleteSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteSyncSource(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncSource request - GetSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncSource(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncSourceWithBody request with any body - UpdateSyncSourceWithBody(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncSourceWithBody(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // MigrateSyncSource request - MigrateSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncSource(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncSourceSyncs request - ListSyncSourceSyncs(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncSourceSyncs(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetTestConnectionForSyncSource request - GetTestConnectionForSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) + GetTestConnectionForSyncSource(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncTransformers request - ListSyncTransformers(ctx context.Context, teamName TeamName, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncTransformers(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteSyncTransformer request - DeleteSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncTransformer request - GetSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncTransformerWithBody request with any body - UpdateSyncTransformerWithBody(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTransformerWithBody(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncTransformerSyncDestinations request - ListSyncTransformerSyncDestinations(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncTransformerSyncDestinations(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncTransformerSyncs request - ListSyncTransformerSyncs(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncTransformerSyncs(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncUpgrades request - ListSyncUpgrades(ctx context.Context, teamName TeamName, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncUpgrades(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncs request - ListSyncs(ctx context.Context, teamName TeamName, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncs(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateSyncWithBody request with any body - CreateSyncWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - CreateSync(ctx context.Context, teamName TeamName, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetTestConnectionConnectorCredentials request - GetTestConnectionConnectorCredentials(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetTestConnectionConnectorIdentity request - GetTestConnectionConnectorIdentity(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSync(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteSync request - DeleteSync(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteSync(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSync request - GetSync(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSync(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncWithBody request with any body - UpdateSyncWithBody(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncWithBody(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateSync(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSync(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListSyncRuns request - ListSyncRuns(ctx context.Context, teamName TeamName, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListSyncRuns(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateSyncRun request - CreateSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncRun(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncRun request - GetSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncRun(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateSyncRunWithBody request with any body - UpdateSyncRunWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - UpdateSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetSyncRunConnectorCredentials request - GetSyncRunConnectorCredentials(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetSyncRunConnectorIdentity request - GetSyncRunConnectorIdentity(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncRunWithBody(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetSyncRunLogs request - GetSyncRunLogs(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateSyncRun(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncRunLogsLive request - GetSyncRunLogsLive(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncRunLogsLive(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncRunLogsQuery request - GetSyncRunLogsQuery(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncRunLogsQuery(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateSyncRunProgressWithBody request with any body - CreateSyncRunProgressWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncRunProgressWithBody(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateSyncRunProgress(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateSyncRunProgress(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncRunStats request - GetSyncRunStats(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncRunStats(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) // GetSyncRunTables request - GetSyncRunTables(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetSyncRunTables(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListTablesTeam request - ListTablesTeam(ctx context.Context, teamName TeamName, params *ListTablesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListTables request + ListTables(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // BatchTableSchemasTeam request - BatchTableSchemasTeam(ctx context.Context, teamName TeamName, params *BatchTableSchemasTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetTablesData request + GetTablesData(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableListColumnsTeam request - TableListColumnsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListColumnsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TablesDataActionWithBody request with any body + TablesDataActionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableColumnListValuesTeam request - TableColumnListValuesTeam(ctx context.Context, teamName TeamName, tableName TableName, columnName ColumnName, params *TableColumnListValuesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + TablesDataAction(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableListRowsTeam request - TableListRowsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRowsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // BatchTableSchemas request + BatchTableSchemas(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableRowByIdTeam request - TableRowByIdTeam(ctx context.Context, teamName TeamName, tableName TableName, tableRowId TableRowId, params *TableRowByIdTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableListColumns request + TableListColumns(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableListFiltersTeam request - TableListFiltersTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableColumnListValues request + TableColumnListValues(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableSaveFilterTeamWithBody request with any body - TableSaveFilterTeamWithBody(ctx context.Context, teamName TeamName, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableListRows request + TableListRows(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - TableSaveFilterTeam(ctx context.Context, teamName TeamName, tableName TableName, body TableSaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableRowById request + TableRowById(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableListFilterTagsTeam request - TableListFilterTagsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableListFilters request + TableListFilters(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableListRelationsTeam request - TableListRelationsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRelationsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableSaveFilterWithBody request with any body + TableSaveFilterWithBody(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - // TableSchemaTeam request - TableSchemaTeam(ctx context.Context, teamName TeamName, tableName TableName, reqEditors ...RequestEditorFn) (*http.Response, error) + TableSaveFilter(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetTeamUsageSummary request - GetTeamUsageSummary(ctx context.Context, teamName TeamName, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableListFilterTags request + TableListFilterTags(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetGroupedTeamUsageSummary request - GetGroupedTeamUsageSummary(ctx context.Context, teamName TeamName, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // TableSchema request + TableSchema(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListUsersByTeam request - ListUsersByTeam(ctx context.Context, teamName TeamName, params *ListUsersByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListTeams request + ListTeams(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - // UploadImageWithBody request with any body - UploadImageWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // DownloadPluginAssetByTeam request + DownloadPluginAssetByTeam(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdateSyncTestConnectionForSyncDestinationTeamWithBody request with any body + UpdateSyncTestConnectionForSyncDestinationTeamWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateSyncTestConnectionForSyncDestinationTeam(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdateSyncTestConnectionForSyncSourceTeamWithBody request with any body + UpdateSyncTestConnectionForSyncSourceTeamWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateSyncTestConnectionForSyncSourceTeam(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // CreateSyncRunProgressTeamWithBody request with any body + CreateSyncRunProgressTeamWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + CreateSyncRunProgressTeam(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - UploadImage(ctx context.Context, body UploadImageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetTeamUsageSummary request + GetTeamUsageSummary(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetGroupedTeamUsageSummary request + GetGroupedTeamUsageSummary(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetCurrentUser request GetCurrentUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7255,15 +6288,15 @@ type ClientInterface interface { SendAnonymousEvent(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // AuthenticateLocalUserWithBody request with any body - AuthenticateLocalUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // AuthenticateUserWithBody request with any body + AuthenticateUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - AuthenticateLocalUser(ctx context.Context, body AuthenticateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + AuthenticateUser(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ChangeLocalUserPasswordWithBody request with any body - ChangeLocalUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + // ChangeUserPasswordWithBody request with any body + ChangeUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - ChangeLocalUserPassword(ctx context.Context, body ChangeLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + ChangeUserPassword(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateCustomerWithBody request with any body UpdateCustomerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7275,12 +6308,6 @@ type ClientInterface interface { SendUserEvent(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // ListCurrentUserInvitations request - ListCurrentUserInvitations(ctx context.Context, params *ListCurrentUserInvitationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // GetCurrentLocalUser request - GetCurrentLocalUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // LogoutUser request LogoutUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7289,17 +6316,6 @@ type ClientInterface interface { LoginUser(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - // GetCurrentUserMemberships request - GetCurrentUserMemberships(ctx context.Context, params *GetCurrentUserMembershipsParams, reqEditors ...RequestEditorFn) (*http.Response, error) - - // ResetLocalUserPasswordWithBody request with any body - ResetLocalUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - - ResetLocalUserPassword(ctx context.Context, body ResetLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) - - // CreateUserToken request - CreateUserToken(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) - // UserTOTPDelete request UserTOTPDelete(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -7311,56 +6327,75 @@ type ClientInterface interface { UserTOTPVerify(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListUsers request + ListUsers(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // AddUserWithBody request with any body + AddUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + AddUser(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // DeleteUser request DeleteUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetUser request + GetUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // UpdateUserWithBody request with any body + UpdateUserWithBody(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + UpdateUser(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteUserTOTP request + DeleteUserTOTP(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreateV2SyncDestinationTestConnectionWithBody request with any body - CreateV2SyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncDestinationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateV2SyncDestinationTestConnection(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncDestinationTestConnection(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // GetV2SyncDestinations request - GetV2SyncDestinations(ctx context.Context, teamName TeamName, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + GetV2SyncDestinations(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateV2SyncDestinationWithBody request with any body - CreateV2SyncDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateV2SyncDestination(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncDestination(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteV2SyncDestination request - DeleteV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) // GetV2SyncDestination request - GetV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) // PatchV2SyncDestinationWithBody request with any body - PatchV2SyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + PatchV2SyncDestinationWithBody(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - PatchV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + PatchV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateV2SyncIntegrationTestConnectionWithBody request with any body - CreateV2SyncIntegrationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncIntegrationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateV2SyncIntegrationTestConnection(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncIntegrationTestConnection(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // ListV2SyncIntegrations request - ListV2SyncIntegrations(ctx context.Context, teamName TeamName, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + ListV2SyncIntegrations(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) // CreateV2SyncIntegrationWithBody request with any body - CreateV2SyncIntegrationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncIntegrationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - CreateV2SyncIntegration(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + CreateV2SyncIntegration(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) // DeleteV2SyncIntegration request - DeleteV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) + DeleteV2SyncIntegration(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*http.Response, error) // GetV2SyncIntegration request - GetV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) + GetV2SyncIntegration(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) // UpdateV2SyncIntegrationWithBody request with any body - UpdateV2SyncIntegrationWithBody(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateV2SyncIntegrationWithBody(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) - UpdateV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + UpdateV2SyncIntegration(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) } func (c *Client) Index(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { @@ -7375,8 +6410,8 @@ func (c *Client) Index(ctx context.Context, reqEditors ...RequestEditorFn) (*htt return c.Client.Do(req) } -func (c *Client) ListAuditLogs(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAuditLogsRequest(c.Server, params) +func (c *Client) ListAllAlerts(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllAlertsRequest(c.Server, params) if err != nil { return nil, err } @@ -7387,8 +6422,8 @@ func (c *Client) ListAuditLogs(ctx context.Context, params *ListAuditLogsParams, return c.Client.Do(req) } -func (c *Client) GetAuditLog(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetAuditLogRequest(c.Server, id) +func (c *Client) TestUnsavedAlertWithBody(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTestUnsavedAlertRequestWithBody(c.Server, params, contentType, body) if err != nil { return nil, err } @@ -7399,8 +6434,8 @@ func (c *Client) GetAuditLog(ctx context.Context, id openapi_types.UUID, reqEdit return c.Client.Do(req) } -func (c *Client) HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewHealthCheckRequest(c.Server) +func (c *Client) TestUnsavedAlert(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTestUnsavedAlertRequest(c.Server, params, body) if err != nil { return nil, err } @@ -7411,8 +6446,8 @@ func (c *Client) HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) return c.Client.Do(req) } -func (c *Client) HealthCheckHead(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewHealthCheckHeadRequest(c.Server) +func (c *Client) ListAPIKeys(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAPIKeysRequest(c.Server, params) if err != nil { return nil, err } @@ -7423,8 +6458,8 @@ func (c *Client) HealthCheckHead(ctx context.Context, reqEditors ...RequestEdito return c.Client.Do(req) } -func (c *Client) AssetViewGetStatus(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAssetViewGetStatusRequest(c.Server) +func (c *Client) CreateAPIKeyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateAPIKeyRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7435,8 +6470,8 @@ func (c *Client) AssetViewGetStatus(ctx context.Context, reqEditors ...RequestEd return c.Client.Do(req) } -func (c *Client) AssetViewTrigger(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAssetViewTriggerRequest(c.Server) +func (c *Client) CreateAPIKey(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateAPIKeyRequest(c.Server, body) if err != nil { return nil, err } @@ -7447,8 +6482,8 @@ func (c *Client) AssetViewTrigger(ctx context.Context, reqEditors ...RequestEdit return c.Client.Do(req) } -func (c *Client) AssetViewListLogs(ctx context.Context, params *AssetViewListLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAssetViewListLogsRequest(c.Server, params) +func (c *Client) DeleteAPIKey(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteAPIKeyRequest(c.Server, apiKeyID) if err != nil { return nil, err } @@ -7459,8 +6494,8 @@ func (c *Client) AssetViewListLogs(ctx context.Context, params *AssetViewListLog return c.Client.Do(req) } -func (c *Client) ManageGetSAML(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageGetSAMLRequest(c.Server) +func (c *Client) ListAuditLogs(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAuditLogsRequest(c.Server, params) if err != nil { return nil, err } @@ -7471,8 +6506,8 @@ func (c *Client) ManageGetSAML(ctx context.Context, reqEditors ...RequestEditorF return c.Client.Do(req) } -func (c *Client) ManageUpdateSAMLWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageUpdateSAMLRequestWithBody(c.Server, contentType, body) +func (c *Client) GetAuditLog(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAuditLogRequest(c.Server, id) if err != nil { return nil, err } @@ -7483,8 +6518,8 @@ func (c *Client) ManageUpdateSAMLWithBody(ctx context.Context, contentType strin return c.Client.Do(req) } -func (c *Client) ManageUpdateSAML(ctx context.Context, body ManageUpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageUpdateSAMLRequest(c.Server, body) +func (c *Client) GetSAML(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSAMLRequest(c.Server) if err != nil { return nil, err } @@ -7495,8 +6530,8 @@ func (c *Client) ManageUpdateSAML(ctx context.Context, body ManageUpdateSAMLJSON return c.Client.Do(req) } -func (c *Client) ManageGetPlatformRegistry(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageGetPlatformRegistryRequest(c.Server) +func (c *Client) UpdateSAMLWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSAMLRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7507,8 +6542,8 @@ func (c *Client) ManageGetPlatformRegistry(ctx context.Context, reqEditors ...Re return c.Client.Do(req) } -func (c *Client) ManageRegisterPlatformWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRegisterPlatformRequestWithBody(c.Server, contentType, body) +func (c *Client) UpdateSAML(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSAMLRequest(c.Server, body) if err != nil { return nil, err } @@ -7519,8 +6554,8 @@ func (c *Client) ManageRegisterPlatformWithBody(ctx context.Context, contentType return c.Client.Do(req) } -func (c *Client) ManageRegisterPlatform(ctx context.Context, body ManageRegisterPlatformJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRegisterPlatformRequest(c.Server, body) +func (c *Client) CreateConversationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateConversationRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7531,8 +6566,8 @@ func (c *Client) ManageRegisterPlatform(ctx context.Context, body ManageRegister return c.Client.Do(req) } -func (c *Client) ManageRegisterPlatformWithOfflineLicenseWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRegisterPlatformWithOfflineLicenseRequestWithBody(c.Server, contentType, body) +func (c *Client) CreateConversation(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateConversationRequest(c.Server, body) if err != nil { return nil, err } @@ -7543,8 +6578,8 @@ func (c *Client) ManageRegisterPlatformWithOfflineLicenseWithBody(ctx context.Co return c.Client.Do(req) } -func (c *Client) ManageRegisterPlatformWithOfflineLicense(ctx context.Context, body ManageRegisterPlatformWithOfflineLicenseJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRegisterPlatformWithOfflineLicenseRequest(c.Server, body) +func (c *Client) GetConversation(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetConversationRequest(c.Server, conversationID) if err != nil { return nil, err } @@ -7555,8 +6590,8 @@ func (c *Client) ManageRegisterPlatformWithOfflineLicense(ctx context.Context, b return c.Client.Do(req) } -func (c *Client) GetSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSettingsRequest(c.Server) +func (c *Client) SendMessageWithBody(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendMessageRequestWithBody(c.Server, conversationID, contentType, body) if err != nil { return nil, err } @@ -7567,8 +6602,8 @@ func (c *Client) GetSettings(ctx context.Context, reqEditors ...RequestEditorFn) return c.Client.Do(req) } -func (c *Client) UpdateSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSettingsRequestWithBody(c.Server, contentType, body) +func (c *Client) SendMessage(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendMessageRequest(c.Server, conversationID, body) if err != nil { return nil, err } @@ -7579,8 +6614,8 @@ func (c *Client) UpdateSettingsWithBody(ctx context.Context, contentType string, return c.Client.Do(req) } -func (c *Client) UpdateSettings(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSettingsRequest(c.Server, body) +func (c *Client) ListAllCustomColumns(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllCustomColumnsRequest(c.Server, params) if err != nil { return nil, err } @@ -7591,8 +6626,8 @@ func (c *Client) UpdateSettings(ctx context.Context, body UpdateSettingsJSONRequ return c.Client.Do(req) } -func (c *Client) ManageListAllTeams(ctx context.Context, params *ManageListAllTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageListAllTeamsRequest(c.Server, params) +func (c *Client) SaveCustomColumnWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSaveCustomColumnRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7603,8 +6638,8 @@ func (c *Client) ManageListAllTeams(ctx context.Context, params *ManageListAllTe return c.Client.Do(req) } -func (c *Client) ManageDeleteTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageDeleteTeamRequest(c.Server, teamName) +func (c *Client) SaveCustomColumn(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSaveCustomColumnRequest(c.Server, body) if err != nil { return nil, err } @@ -7615,8 +6650,8 @@ func (c *Client) ManageDeleteTeam(ctx context.Context, teamName TeamName, reqEdi return c.Client.Do(req) } -func (c *Client) ManageGetTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageGetTeamRequest(c.Server, teamName) +func (c *Client) DeleteCustomColumn(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteCustomColumnRequest(c.Server, customColumnID) if err != nil { return nil, err } @@ -7627,8 +6662,8 @@ func (c *Client) ManageGetTeam(ctx context.Context, teamName TeamName, reqEditor return c.Client.Do(req) } -func (c *Client) ManageRemoveTeamMemberWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRemoveTeamMemberRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) GetCustomColumn(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCustomColumnRequest(c.Server, customColumnID) if err != nil { return nil, err } @@ -7639,8 +6674,8 @@ func (c *Client) ManageRemoveTeamMemberWithBody(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) ManageRemoveTeamMember(ctx context.Context, teamName TeamName, body ManageRemoveTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageRemoveTeamMemberRequest(c.Server, teamName, body) +func (c *Client) UpdateCustomColumnWithBody(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCustomColumnRequestWithBody(c.Server, customColumnID, contentType, body) if err != nil { return nil, err } @@ -7651,8 +6686,8 @@ func (c *Client) ManageRemoveTeamMember(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) ManageListTeamMembers(ctx context.Context, teamName TeamName, params *ManageListTeamMembersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageListTeamMembersRequest(c.Server, teamName, params) +func (c *Client) UpdateCustomColumn(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCustomColumnRequest(c.Server, customColumnID, body) if err != nil { return nil, err } @@ -7663,8 +6698,8 @@ func (c *Client) ManageListTeamMembers(ctx context.Context, teamName TeamName, p return c.Client.Do(req) } -func (c *Client) ManageAddTeamMemberWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageAddTeamMemberRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) ListFilters(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListFiltersRequest(c.Server, params) if err != nil { return nil, err } @@ -7675,8 +6710,8 @@ func (c *Client) ManageAddTeamMemberWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) ManageAddTeamMember(ctx context.Context, teamName TeamName, body ManageAddTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageAddTeamMemberRequest(c.Server, teamName, body) +func (c *Client) ListFilterTags(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListFilterTagsRequest(c.Server, params) if err != nil { return nil, err } @@ -7687,8 +6722,8 @@ func (c *Client) ManageAddTeamMember(ctx context.Context, teamName TeamName, bod return c.Client.Do(req) } -func (c *Client) ListLocalUsers(ctx context.Context, params *ListLocalUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListLocalUsersRequest(c.Server, params) +func (c *Client) DeleteFilter(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteFilterRequest(c.Server, filterID) if err != nil { return nil, err } @@ -7699,8 +6734,8 @@ func (c *Client) ListLocalUsers(ctx context.Context, params *ListLocalUsersParam return c.Client.Do(req) } -func (c *Client) AddLocalUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAddLocalUserRequestWithBody(c.Server, contentType, body) +func (c *Client) GetFilterByID(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetFilterByIDRequest(c.Server, filterID) if err != nil { return nil, err } @@ -7711,8 +6746,8 @@ func (c *Client) AddLocalUserWithBody(ctx context.Context, contentType string, b return c.Client.Do(req) } -func (c *Client) AddLocalUser(ctx context.Context, body AddLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAddLocalUserRequest(c.Server, body) +func (c *Client) UpdateFilterWithBody(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateFilterRequestWithBody(c.Server, filterID, contentType, body) if err != nil { return nil, err } @@ -7723,8 +6758,8 @@ func (c *Client) AddLocalUser(ctx context.Context, body AddLocalUserJSONRequestB return c.Client.Do(req) } -func (c *Client) DeleteLocalUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteLocalUserRequest(c.Server, userID) +func (c *Client) UpdateFilter(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateFilterRequest(c.Server, filterID, body) if err != nil { return nil, err } @@ -7735,20 +6770,8 @@ func (c *Client) DeleteLocalUser(ctx context.Context, userID UserID, reqEditors return c.Client.Do(req) } -func (c *Client) GetLocalUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetLocalUserRequest(c.Server, userID) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UpdateLocalUserWithBody(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateLocalUserRequestWithBody(c.Server, userID, contentType, body) +func (c *Client) HealthCheck(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewHealthCheckRequest(c.Server) if err != nil { return nil, err } @@ -7759,8 +6782,8 @@ func (c *Client) UpdateLocalUserWithBody(ctx context.Context, userID UserID, con return c.Client.Do(req) } -func (c *Client) UpdateLocalUser(ctx context.Context, userID UserID, body UpdateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateLocalUserRequest(c.Server, userID, body) +func (c *Client) HealthCheckHead(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewHealthCheckHeadRequest(c.Server) if err != nil { return nil, err } @@ -7771,8 +6794,8 @@ func (c *Client) UpdateLocalUser(ctx context.Context, userID UserID, body Update return c.Client.Do(req) } -func (c *Client) CreateLocalUserResetToken(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateLocalUserResetTokenRequest(c.Server, userID) +func (c *Client) ListNotifications(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListNotificationsRequest(c.Server, params) if err != nil { return nil, err } @@ -7783,8 +6806,8 @@ func (c *Client) CreateLocalUserResetToken(ctx context.Context, userID UserID, r return c.Client.Do(req) } -func (c *Client) ManageUserTOTPDelete(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewManageUserTOTPDeleteRequest(c.Server, userID) +func (c *Client) DeleteNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteNotificationDestinationRequest(c.Server, notificationDestinationId) if err != nil { return nil, err } @@ -7795,8 +6818,8 @@ func (c *Client) ManageUserTOTPDelete(ctx context.Context, userID UserID, reqEdi return c.Client.Do(req) } -func (c *Client) GetOpenAPIJSON(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetOpenAPIJSONRequest(c.Server) +func (c *Client) GetNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetNotificationDestinationRequest(c.Server, notificationDestinationId) if err != nil { return nil, err } @@ -7807,8 +6830,8 @@ func (c *Client) GetOpenAPIJSON(ctx context.Context, reqEditors ...RequestEditor return c.Client.Do(req) } -func (c *Client) GetPlatformInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetPlatformInfoRequest(c.Server) +func (c *Client) UpdateNotificationDestinationWithBody(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateNotificationDestinationRequestWithBody(c.Server, notificationDestinationId, contentType, body) if err != nil { return nil, err } @@ -7819,8 +6842,8 @@ func (c *Client) GetPlatformInfo(ctx context.Context, reqEditors ...RequestEdito return c.Client.Do(req) } -func (c *Client) ListPlatformVersions(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPlatformVersionsRequest(c.Server, params) +func (c *Client) UpdateNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateNotificationDestinationRequest(c.Server, notificationDestinationId, body) if err != nil { return nil, err } @@ -7831,8 +6854,8 @@ func (c *Client) ListPlatformVersions(ctx context.Context, params *ListPlatformV return c.Client.Do(req) } -func (c *Client) ListPlugins(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPluginsRequest(c.Server, params) +func (c *Client) GetNotificationDestinationAlerts(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetNotificationDestinationAlertsRequest(c.Server, notificationDestinationId, params) if err != nil { return nil, err } @@ -7843,8 +6866,8 @@ func (c *Client) ListPlugins(ctx context.Context, params *ListPluginsParams, req return c.Client.Do(req) } -func (c *Client) CreatePluginWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginRequestWithBody(c.Server, contentType, body) +func (c *Client) TestNotificationDestination(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTestNotificationDestinationRequest(c.Server, notificationDestinationId) if err != nil { return nil, err } @@ -7855,8 +6878,8 @@ func (c *Client) CreatePluginWithBody(ctx context.Context, contentType string, b return c.Client.Do(req) } -func (c *Client) CreatePlugin(ctx context.Context, body CreatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginRequest(c.Server, body) +func (c *Client) ListAllNotificationDestinations(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllNotificationDestinationsRequest(c.Server, params) if err != nil { return nil, err } @@ -7867,8 +6890,8 @@ func (c *Client) CreatePlugin(ctx context.Context, body CreatePluginJSONRequestB return c.Client.Do(req) } -func (c *Client) DeletePluginByTeamAndPluginName(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginByTeamAndPluginNameRequest(c.Server, teamName, pluginKind, pluginName) +func (c *Client) CreateNotificationDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateNotificationDestinationRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7879,8 +6902,8 @@ func (c *Client) DeletePluginByTeamAndPluginName(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) GetPlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetPluginRequest(c.Server, teamName, pluginKind, pluginName) +func (c *Client) CreateNotificationDestination(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateNotificationDestinationRequest(c.Server, body) if err != nil { return nil, err } @@ -7891,8 +6914,8 @@ func (c *Client) GetPlugin(ctx context.Context, teamName TeamName, pluginKind Pl return c.Client.Do(req) } -func (c *Client) UpdatePluginWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePluginRequestWithBody(c.Server, teamName, pluginKind, pluginName, contentType, body) +func (c *Client) TestUnsavedNotificationDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTestUnsavedNotificationDestinationRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7903,8 +6926,8 @@ func (c *Client) UpdatePluginWithBody(ctx context.Context, teamName TeamName, pl return c.Client.Do(req) } -func (c *Client) UpdatePlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, body UpdatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePluginRequest(c.Server, teamName, pluginKind, pluginName, body) +func (c *Client) TestUnsavedNotificationDestination(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTestUnsavedNotificationDestinationRequest(c.Server, body) if err != nil { return nil, err } @@ -7915,8 +6938,8 @@ func (c *Client) UpdatePlugin(ctx context.Context, teamName TeamName, pluginKind return c.Client.Do(req) } -func (c *Client) ListPluginVersions(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPluginVersionsRequest(c.Server, teamName, pluginKind, pluginName, params) +func (c *Client) CreateAWSOnboardingWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateAWSOnboardingRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -7927,8 +6950,8 @@ func (c *Client) ListPluginVersions(ctx context.Context, teamName TeamName, plug return c.Client.Do(req) } -func (c *Client) GetPluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetPluginVersionRequest(c.Server, teamName, pluginKind, pluginName, versionName) +func (c *Client) CreateAWSOnboarding(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateAWSOnboardingRequest(c.Server, body) if err != nil { return nil, err } @@ -7939,8 +6962,8 @@ func (c *Client) GetPluginVersion(ctx context.Context, teamName TeamName, plugin return c.Client.Do(req) } -func (c *Client) UpdatePluginVersionWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePluginVersionRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) GetAWSOnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAWSOnboardingRequest(c.Server, onboardingID) if err != nil { return nil, err } @@ -7951,8 +6974,8 @@ func (c *Client) UpdatePluginVersionWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) UpdatePluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UpdatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePluginVersionRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) GetAWSAccountsInRoot(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAWSAccountsInRootRequest(c.Server, onboardingID) if err != nil { return nil, err } @@ -7963,8 +6986,8 @@ func (c *Client) UpdatePluginVersion(ctx context.Context, teamName TeamName, plu return c.Client.Do(req) } -func (c *Client) CreatePluginVersionWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) ProvisionOnboardingConfigurationWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewProvisionOnboardingConfigurationRequestWithBody(c.Server, onboardingID, contentType, body) if err != nil { return nil, err } @@ -7975,8 +6998,8 @@ func (c *Client) CreatePluginVersionWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) CreatePluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) ProvisionOnboardingConfiguration(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewProvisionOnboardingConfigurationRequest(c.Server, onboardingID, body) if err != nil { return nil, err } @@ -7987,8 +7010,8 @@ func (c *Client) CreatePluginVersion(ctx context.Context, teamName TeamName, plu return c.Client.Do(req) } -func (c *Client) DownloadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDownloadPluginAssetRequest(c.Server, teamName, pluginKind, pluginName, versionName, targetName, params) +func (c *Client) GetAWSAccountsInParent(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAWSAccountsInParentRequest(c.Server, onboardingID, organizationalUnitID) if err != nil { return nil, err } @@ -7999,8 +7022,8 @@ func (c *Client) DownloadPluginAsset(ctx context.Context, teamName TeamName, plu return c.Client.Do(req) } -func (c *Client) UploadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUploadPluginAssetRequest(c.Server, teamName, pluginKind, pluginName, versionName, targetName) +func (c *Client) NotifyOnboardingWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewNotifyOnboardingRequestWithBody(c.Server, onboardingID, contentType, body) if err != nil { return nil, err } @@ -8011,8 +7034,8 @@ func (c *Client) UploadPluginAsset(ctx context.Context, teamName TeamName, plugi return c.Client.Do(req) } -func (c *Client) DeletePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginVersionDocsRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) NotifyOnboarding(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewNotifyOnboardingRequest(c.Server, onboardingID, body) if err != nil { return nil, err } @@ -8023,8 +7046,8 @@ func (c *Client) DeletePluginVersionDocsWithBody(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) DeletePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginVersionDocsRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) GetOpenAPIJSON(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOpenAPIJSONRequest(c.Server) if err != nil { return nil, err } @@ -8035,8 +7058,8 @@ func (c *Client) DeletePluginVersionDocs(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) ListPluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionDocsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPluginVersionDocsRequest(c.Server, teamName, pluginKind, pluginName, versionName, params) +func (c *Client) GetPlatformInfo(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPlatformInfoRequest(c.Server) if err != nil { return nil, err } @@ -8047,8 +7070,8 @@ func (c *Client) ListPluginVersionDocs(ctx context.Context, teamName TeamName, p return c.Client.Do(req) } -func (c *Client) ReplacePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewReplacePluginVersionDocsRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) ListPlatformVersions(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPlatformVersionsRequest(c.Server, params) if err != nil { return nil, err } @@ -8059,8 +7082,8 @@ func (c *Client) ReplacePluginVersionDocsWithBody(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) ReplacePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body ReplacePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewReplacePluginVersionDocsRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) ListPlugins(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPluginsRequest(c.Server, params) if err != nil { return nil, err } @@ -8071,8 +7094,8 @@ func (c *Client) ReplacePluginVersionDocs(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) CreatePluginVersionDocsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionDocsRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) GetPlugin(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPluginRequest(c.Server, teamName, pluginKind, pluginName) if err != nil { return nil, err } @@ -8083,8 +7106,8 @@ func (c *Client) CreatePluginVersionDocsWithBody(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) CreatePluginVersionDocs(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionDocsRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) ListPluginVersions(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPluginVersionsRequest(c.Server, teamName, pluginKind, pluginName, params) if err != nil { return nil, err } @@ -8095,8 +7118,8 @@ func (c *Client) CreatePluginVersionDocs(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) DeletePluginVersionTablesWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginVersionTablesRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) +func (c *Client) GetPluginVersion(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPluginVersionRequest(c.Server, teamName, pluginKind, pluginName, versionName) if err != nil { return nil, err } @@ -8107,8 +7130,8 @@ func (c *Client) DeletePluginVersionTablesWithBody(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) DeletePluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginVersionTablesRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) +func (c *Client) DownloadPluginAsset(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDownloadPluginAssetRequest(c.Server, teamName, pluginKind, pluginName, versionName, targetName, params) if err != nil { return nil, err } @@ -8131,30 +7154,6 @@ func (c *Client) ListPluginVersionTables(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) CreatePluginVersionTablesWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionTablesRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreatePluginVersionTables(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePluginVersionTablesRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - func (c *Client) GetPluginVersionTable(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewGetPluginVersionTableRequest(c.Server, teamName, pluginKind, pluginName, versionName, tableName) if err != nil { @@ -8167,152 +7166,8 @@ func (c *Client) GetPluginVersionTable(ctx context.Context, teamName TeamName, p return c.Client.Do(req) } -func (c *Client) RemovePluginUIAssets(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewRemovePluginUIAssetsRequest(c.Server, teamName, pluginKind, pluginName, versionName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UploadPluginUIAssetsWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUploadPluginUIAssetsRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UploadPluginUIAssets(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UploadPluginUIAssetsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUploadPluginUIAssetsRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) FinalizePluginUIAssetUploadWithBody(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewFinalizePluginUIAssetUploadRequestWithBody(c.Server, teamName, pluginKind, pluginName, versionName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) FinalizePluginUIAssetUpload(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body FinalizePluginUIAssetUploadJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewFinalizePluginUIAssetUploadRequest(c.Server, teamName, pluginKind, pluginName, versionName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) AuthRegistryRequest(ctx context.Context, params *AuthRegistryRequestParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthRegistryRequestRequest(c.Server, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) ListTeams(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListTeamsRequest(c.Server, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateTeamWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamRequestWithBody(c.Server, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateTeam(ctx context.Context, body CreateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamRequest(c.Server, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) DeleteTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteTeamRequest(c.Server, teamName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetTeamByName(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTeamByNameRequest(c.Server, teamName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UpdateTeamWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateTeamRequestWithBody(c.Server, teamName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UpdateTeam(ctx context.Context, teamName TeamName, body UpdateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateTeamRequest(c.Server, teamName, body) +func (c *Client) ListPolicies(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPoliciesRequest(c.Server, params) if err != nil { return nil, err } @@ -8323,8 +7178,8 @@ func (c *Client) UpdateTeam(ctx context.Context, teamName TeamName, body UpdateT return c.Client.Do(req) } -func (c *Client) ListAllAlerts(ctx context.Context, teamName TeamName, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllAlertsRequest(c.Server, teamName, params) +func (c *Client) CreatePolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreatePolicyRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8335,8 +7190,8 @@ func (c *Client) ListAllAlerts(ctx context.Context, teamName TeamName, params *L return c.Client.Do(req) } -func (c *Client) TestUnsavedAlertWithBody(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTestUnsavedAlertRequestWithBody(c.Server, teamName, params, contentType, body) +func (c *Client) CreatePolicy(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreatePolicyRequest(c.Server, body) if err != nil { return nil, err } @@ -8347,8 +7202,8 @@ func (c *Client) TestUnsavedAlertWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) TestUnsavedAlert(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTestUnsavedAlertRequest(c.Server, teamName, params, body) +func (c *Client) GetPolicyMetrics(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPolicyMetricsRequest(c.Server, params) if err != nil { return nil, err } @@ -8359,8 +7214,8 @@ func (c *Client) TestUnsavedAlert(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) ListTeamAPIKeys(ctx context.Context, teamName TeamName, params *ListTeamAPIKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListTeamAPIKeysRequest(c.Server, teamName, params) +func (c *Client) GetViolationsByDomain(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetViolationsByDomainRequest(c.Server, params) if err != nil { return nil, err } @@ -8371,8 +7226,8 @@ func (c *Client) ListTeamAPIKeys(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) CreateTeamAPIKeyWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamAPIKeyRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) GetViolationsHistory(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetViolationsHistoryRequest(c.Server, params) if err != nil { return nil, err } @@ -8383,8 +7238,8 @@ func (c *Client) CreateTeamAPIKeyWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) CreateTeamAPIKey(ctx context.Context, teamName TeamName, body CreateTeamAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamAPIKeyRequest(c.Server, teamName, body) +func (c *Client) DeletePolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeletePolicyRequest(c.Server, policyID) if err != nil { return nil, err } @@ -8395,8 +7250,8 @@ func (c *Client) CreateTeamAPIKey(ctx context.Context, teamName TeamName, body C return c.Client.Do(req) } -func (c *Client) DeleteTeamAPIKey(ctx context.Context, teamName TeamName, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteTeamAPIKeyRequest(c.Server, teamName, apiKeyID) +func (c *Client) GetPolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPolicyRequest(c.Server, policyID) if err != nil { return nil, err } @@ -8407,8 +7262,8 @@ func (c *Client) DeleteTeamAPIKey(ctx context.Context, teamName TeamName, apiKey return c.Client.Do(req) } -func (c *Client) ListConnectors(ctx context.Context, teamName TeamName, params *ListConnectorsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListConnectorsRequest(c.Server, teamName, params) +func (c *Client) UpdatePolicyWithBody(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdatePolicyRequestWithBody(c.Server, policyID, contentType, body) if err != nil { return nil, err } @@ -8419,8 +7274,8 @@ func (c *Client) ListConnectors(ctx context.Context, teamName TeamName, params * return c.Client.Do(req) } -func (c *Client) CreateConnectorWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateConnectorRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdatePolicy(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdatePolicyRequest(c.Server, policyID, body) if err != nil { return nil, err } @@ -8431,8 +7286,8 @@ func (c *Client) CreateConnectorWithBody(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) CreateConnector(ctx context.Context, teamName TeamName, body CreateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateConnectorRequest(c.Server, teamName, body) +func (c *Client) TogglePolicy(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTogglePolicyRequest(c.Server, policyID) if err != nil { return nil, err } @@ -8443,8 +7298,8 @@ func (c *Client) CreateConnector(ctx context.Context, teamName TeamName, body Cr return c.Client.Do(req) } -func (c *Client) GetConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetConnectorRequest(c.Server, teamName, connectorID) +func (c *Client) GetPolicyViolations(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPolicyViolationsRequest(c.Server, policyID, params) if err != nil { return nil, err } @@ -8455,8 +7310,8 @@ func (c *Client) GetConnector(ctx context.Context, teamName TeamName, connectorI return c.Client.Do(req) } -func (c *Client) UpdateConnectorWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateConnectorRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) GetPolicyViolationsHistory(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPolicyViolationsHistoryRequest(c.Server, policyID, params) if err != nil { return nil, err } @@ -8467,8 +7322,8 @@ func (c *Client) UpdateConnectorWithBody(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) UpdateConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, body UpdateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateConnectorRequest(c.Server, teamName, connectorID, body) +func (c *Client) ListPolicyGroups(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPolicyGroupsRequest(c.Server, params) if err != nil { return nil, err } @@ -8479,8 +7334,8 @@ func (c *Client) UpdateConnector(ctx context.Context, teamName TeamName, connect return c.Client.Do(req) } -func (c *Client) RevokeConnector(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewRevokeConnectorRequest(c.Server, teamName, connectorID) +func (c *Client) CreatePolicyGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreatePolicyGroupRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8491,8 +7346,8 @@ func (c *Client) RevokeConnector(ctx context.Context, teamName TeamName, connect return c.Client.Do(req) } -func (c *Client) GetConnectorAuthStatusAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetConnectorAuthStatusAWSRequest(c.Server, teamName, connectorID) +func (c *Client) CreatePolicyGroup(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreatePolicyGroupRequest(c.Server, body) if err != nil { return nil, err } @@ -8503,8 +7358,8 @@ func (c *Client) GetConnectorAuthStatusAWS(ctx context.Context, teamName TeamNam return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorFinishAWSWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorFinishAWSRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) DeletePolicyGroup(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeletePolicyGroupRequest(c.Server, policyGroupID) if err != nil { return nil, err } @@ -8515,8 +7370,8 @@ func (c *Client) AuthenticateConnectorFinishAWSWithBody(ctx context.Context, tea return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorFinishAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorFinishAWSRequest(c.Server, teamName, connectorID, body) +func (c *Client) ListPoliciesInGroup(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPoliciesInGroupRequest(c.Server, policyGroupID, params) if err != nil { return nil, err } @@ -8527,8 +7382,8 @@ func (c *Client) AuthenticateConnectorFinishAWS(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorAWSWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorAWSRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) UpdatePolicyGroupWithBody(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdatePolicyGroupRequestWithBody(c.Server, policyGroupID, contentType, body) if err != nil { return nil, err } @@ -8539,8 +7394,8 @@ func (c *Client) AuthenticateConnectorAWSWithBody(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorAWS(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorAWSRequest(c.Server, teamName, connectorID, body) +func (c *Client) UpdatePolicyGroup(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdatePolicyGroupRequest(c.Server, policyGroupID, body) if err != nil { return nil, err } @@ -8551,8 +7406,8 @@ func (c *Client) AuthenticateConnectorAWS(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) GetConnectorAuthStatusGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetConnectorAuthStatusGCPRequest(c.Server, teamName, connectorID) +func (c *Client) ListAllQueries(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllQueriesRequest(c.Server, params) if err != nil { return nil, err } @@ -8563,8 +7418,8 @@ func (c *Client) GetConnectorAuthStatusGCP(ctx context.Context, teamName TeamNam return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorGCPWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorGCPRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) ExecuteAdHocQueryWithBody(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewExecuteAdHocQueryRequestWithBody(c.Server, params, contentType, body) if err != nil { return nil, err } @@ -8575,8 +7430,8 @@ func (c *Client) AuthenticateConnectorGCPWithBody(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorGCPJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorGCPRequest(c.Server, teamName, connectorID, body) +func (c *Client) ExecuteAdHocQuery(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewExecuteAdHocQueryRequest(c.Server, params, body) if err != nil { return nil, err } @@ -8587,8 +7442,8 @@ func (c *Client) AuthenticateConnectorGCP(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorFinishGCP(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorFinishGCPRequest(c.Server, teamName, connectorID) +func (c *Client) SaveQueryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSaveQueryRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8599,8 +7454,8 @@ func (c *Client) AuthenticateConnectorFinishGCP(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorFinishOAuthWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorFinishOAuthRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) SaveQuery(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSaveQueryRequest(c.Server, body) if err != nil { return nil, err } @@ -8611,8 +7466,8 @@ func (c *Client) AuthenticateConnectorFinishOAuthWithBody(ctx context.Context, t return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorFinishOAuth(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorFinishOAuthRequest(c.Server, teamName, connectorID, body) +func (c *Client) ListQueryTags(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListQueryTagsRequest(c.Server, params) if err != nil { return nil, err } @@ -8623,8 +7478,8 @@ func (c *Client) AuthenticateConnectorFinishOAuth(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorOAuthWithBody(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorOAuthRequestWithBody(c.Server, teamName, connectorID, contentType, body) +func (c *Client) DeleteSavedQuery(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSavedQueryRequest(c.Server, queryID) if err != nil { return nil, err } @@ -8635,8 +7490,8 @@ func (c *Client) AuthenticateConnectorOAuthWithBody(ctx context.Context, teamNam return c.Client.Do(req) } -func (c *Client) AuthenticateConnectorOAuth(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateConnectorOAuthRequest(c.Server, teamName, connectorID, body) +func (c *Client) GetSavedQuery(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSavedQueryRequest(c.Server, queryID) if err != nil { return nil, err } @@ -8647,8 +7502,8 @@ func (c *Client) AuthenticateConnectorOAuth(ctx context.Context, teamName TeamNa return c.Client.Do(req) } -func (c *Client) CreateConversationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateConversationRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdateQueryWithBody(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateQueryRequestWithBody(c.Server, queryID, contentType, body) if err != nil { return nil, err } @@ -8659,8 +7514,8 @@ func (c *Client) CreateConversationWithBody(ctx context.Context, teamName TeamNa return c.Client.Do(req) } -func (c *Client) CreateConversation(ctx context.Context, teamName TeamName, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateConversationRequest(c.Server, teamName, body) +func (c *Client) UpdateQuery(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateQueryRequest(c.Server, queryID, body) if err != nil { return nil, err } @@ -8671,8 +7526,8 @@ func (c *Client) CreateConversation(ctx context.Context, teamName TeamName, body return c.Client.Do(req) } -func (c *Client) GetConversation(ctx context.Context, teamName TeamName, conversationID ConversationID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetConversationRequest(c.Server, teamName, conversationID) +func (c *Client) DeleteAlert(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteAlertRequest(c.Server, queryID) if err != nil { return nil, err } @@ -8683,8 +7538,8 @@ func (c *Client) GetConversation(ctx context.Context, teamName TeamName, convers return c.Client.Do(req) } -func (c *Client) SendMessageWithBody(ctx context.Context, teamName TeamName, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendMessageRequestWithBody(c.Server, teamName, conversationID, contentType, body) +func (c *Client) ExecuteSavedQuery(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewExecuteSavedQueryRequest(c.Server, queryID, params) if err != nil { return nil, err } @@ -8695,8 +7550,8 @@ func (c *Client) SendMessageWithBody(ctx context.Context, teamName TeamName, con return c.Client.Do(req) } -func (c *Client) SendMessage(ctx context.Context, teamName TeamName, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendMessageRequest(c.Server, teamName, conversationID, body) +func (c *Client) QueryListFilters(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewQueryListFiltersRequest(c.Server, queryID, params) if err != nil { return nil, err } @@ -8707,8 +7562,8 @@ func (c *Client) SendMessage(ctx context.Context, teamName TeamName, conversatio return c.Client.Do(req) } -func (c *Client) ListAllCustomColumns(ctx context.Context, teamName TeamName, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllCustomColumnsRequest(c.Server, teamName, params) +func (c *Client) QuerySaveFilterWithBody(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewQuerySaveFilterRequestWithBody(c.Server, queryID, contentType, body) if err != nil { return nil, err } @@ -8719,8 +7574,8 @@ func (c *Client) ListAllCustomColumns(ctx context.Context, teamName TeamName, pa return c.Client.Do(req) } -func (c *Client) SaveCustomColumnWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSaveCustomColumnRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) QuerySaveFilter(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewQuerySaveFilterRequest(c.Server, queryID, body) if err != nil { return nil, err } @@ -8731,8 +7586,8 @@ func (c *Client) SaveCustomColumnWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) SaveCustomColumn(ctx context.Context, teamName TeamName, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSaveCustomColumnRequest(c.Server, teamName, body) +func (c *Client) QueryListFilterTags(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewQueryListFilterTagsRequest(c.Server, queryID, params) if err != nil { return nil, err } @@ -8743,8 +7598,8 @@ func (c *Client) SaveCustomColumn(ctx context.Context, teamName TeamName, body S return c.Client.Do(req) } -func (c *Client) DeleteCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteCustomColumnRequest(c.Server, teamName, customColumnID) +func (c *Client) ListAllRBACPermissions(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllRBACPermissionsRequest(c.Server, params) if err != nil { return nil, err } @@ -8755,8 +7610,8 @@ func (c *Client) DeleteCustomColumn(ctx context.Context, teamName TeamName, cust return c.Client.Do(req) } -func (c *Client) GetCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetCustomColumnRequest(c.Server, teamName, customColumnID) +func (c *Client) CreateRBACPermissionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateRBACPermissionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8767,8 +7622,8 @@ func (c *Client) GetCustomColumn(ctx context.Context, teamName TeamName, customC return c.Client.Do(req) } -func (c *Client) UpdateCustomColumnWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCustomColumnRequestWithBody(c.Server, teamName, customColumnID, contentType, body) +func (c *Client) CreateRBACPermission(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateRBACPermissionRequest(c.Server, body) if err != nil { return nil, err } @@ -8779,8 +7634,8 @@ func (c *Client) UpdateCustomColumnWithBody(ctx context.Context, teamName TeamNa return c.Client.Do(req) } -func (c *Client) UpdateCustomColumn(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCustomColumnRequest(c.Server, teamName, customColumnID, body) +func (c *Client) DeleteRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteRBACPermissionRequest(c.Server, rbacPermissionID) if err != nil { return nil, err } @@ -8791,8 +7646,8 @@ func (c *Client) UpdateCustomColumn(ctx context.Context, teamName TeamName, cust return c.Client.Do(req) } -func (c *Client) PutCustomColumnDataWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPutCustomColumnDataRequestWithBody(c.Server, teamName, customColumnID, contentType, body) +func (c *Client) GetRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetRBACPermissionRequest(c.Server, rbacPermissionID) if err != nil { return nil, err } @@ -8803,8 +7658,8 @@ func (c *Client) PutCustomColumnDataWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) PutCustomColumnData(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnDataJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPutCustomColumnDataRequest(c.Server, teamName, customColumnID, body) +func (c *Client) UpdateRBACPermissionWithBody(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateRBACPermissionRequestWithBody(c.Server, rbacPermissionID, contentType, body) if err != nil { return nil, err } @@ -8815,8 +7670,8 @@ func (c *Client) PutCustomColumnData(ctx context.Context, teamName TeamName, cus return c.Client.Do(req) } -func (c *Client) PutCustomColumnValuesWithBody(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPutCustomColumnValuesRequestWithBody(c.Server, teamName, customColumnID, contentType, body) +func (c *Client) UpdateRBACPermission(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateRBACPermissionRequest(c.Server, rbacPermissionID, body) if err != nil { return nil, err } @@ -8827,8 +7682,8 @@ func (c *Client) PutCustomColumnValuesWithBody(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) PutCustomColumnValues(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnValuesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPutCustomColumnValuesRequest(c.Server, teamName, customColumnID, body) +func (c *Client) ListAllRBACRoles(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListAllRBACRolesRequest(c.Server, params) if err != nil { return nil, err } @@ -8839,8 +7694,8 @@ func (c *Client) PutCustomColumnValues(ctx context.Context, teamName TeamName, c return c.Client.Do(req) } -func (c *Client) ListFiltersTeam(ctx context.Context, teamName TeamName, params *ListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListFiltersTeamRequest(c.Server, teamName, params) +func (c *Client) CreateRBACRoleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateRBACRoleRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8851,8 +7706,8 @@ func (c *Client) ListFiltersTeam(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) ListFilterTagsTeam(ctx context.Context, teamName TeamName, params *ListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListFilterTagsTeamRequest(c.Server, teamName, params) +func (c *Client) CreateRBACRole(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateRBACRoleRequest(c.Server, body) if err != nil { return nil, err } @@ -8863,8 +7718,8 @@ func (c *Client) ListFilterTagsTeam(ctx context.Context, teamName TeamName, para return c.Client.Do(req) } -func (c *Client) DeleteFilterTeam(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteFilterTeamRequest(c.Server, teamName, filterID) +func (c *Client) DeleteRBACRole(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteRBACRoleRequest(c.Server, roleID) if err != nil { return nil, err } @@ -8875,8 +7730,8 @@ func (c *Client) DeleteFilterTeam(ctx context.Context, teamName TeamName, filter return c.Client.Do(req) } -func (c *Client) GetFilterByIDTeam(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetFilterByIDTeamRequest(c.Server, teamName, filterID) +func (c *Client) GetRBACRole(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetRBACRoleRequest(c.Server, roleID) if err != nil { return nil, err } @@ -8887,8 +7742,8 @@ func (c *Client) GetFilterByIDTeam(ctx context.Context, teamName TeamName, filte return c.Client.Do(req) } -func (c *Client) UpdateFilterTeamWithBody(ctx context.Context, teamName TeamName, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateFilterTeamRequestWithBody(c.Server, teamName, filterID, contentType, body) +func (c *Client) UpdateRBACRoleWithBody(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateRBACRoleRequestWithBody(c.Server, roleID, contentType, body) if err != nil { return nil, err } @@ -8899,8 +7754,8 @@ func (c *Client) UpdateFilterTeamWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) UpdateFilterTeam(ctx context.Context, teamName TeamName, filterID FilterID, body UpdateFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateFilterTeamRequest(c.Server, teamName, filterID, body) +func (c *Client) UpdateRBACRole(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateRBACRoleRequest(c.Server, roleID, body) if err != nil { return nil, err } @@ -8911,8 +7766,8 @@ func (c *Client) UpdateFilterTeam(ctx context.Context, teamName TeamName, filter return c.Client.Do(req) } -func (c *Client) CreateTeamImagesWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamImagesRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) ListReports(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListReportsRequest(c.Server, params) if err != nil { return nil, err } @@ -8923,8 +7778,8 @@ func (c *Client) CreateTeamImagesWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) CreateTeamImages(ctx context.Context, teamName TeamName, body CreateTeamImagesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateTeamImagesRequest(c.Server, teamName, body) +func (c *Client) CreateReportWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateReportRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8935,8 +7790,8 @@ func (c *Client) CreateTeamImages(ctx context.Context, teamName TeamName, body C return c.Client.Do(req) } -func (c *Client) DeleteTeamInvitationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteTeamInvitationRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) CreateReport(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateReportRequest(c.Server, body) if err != nil { return nil, err } @@ -8947,8 +7802,8 @@ func (c *Client) DeleteTeamInvitationWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) DeleteTeamInvitation(ctx context.Context, teamName TeamName, body DeleteTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteTeamInvitationRequest(c.Server, teamName, body) +func (c *Client) ListReportTemplates(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListReportTemplatesRequest(c.Server, params) if err != nil { return nil, err } @@ -8959,8 +7814,8 @@ func (c *Client) DeleteTeamInvitation(ctx context.Context, teamName TeamName, bo return c.Client.Do(req) } -func (c *Client) ListTeamInvitations(ctx context.Context, teamName TeamName, params *ListTeamInvitationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListTeamInvitationsRequest(c.Server, teamName, params) +func (c *Client) CreateReportTemplateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateReportTemplateRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -8971,8 +7826,8 @@ func (c *Client) ListTeamInvitations(ctx context.Context, teamName TeamName, par return c.Client.Do(req) } -func (c *Client) AcceptTeamInvitationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAcceptTeamInvitationRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) CreateReportTemplate(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateReportTemplateRequest(c.Server, body) if err != nil { return nil, err } @@ -8983,8 +7838,8 @@ func (c *Client) AcceptTeamInvitationWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) AcceptTeamInvitation(ctx context.Context, teamName TeamName, body AcceptTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAcceptTeamInvitationRequest(c.Server, teamName, body) +func (c *Client) DeleteReportTemplate(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteReportTemplateRequest(c.Server, templateId) if err != nil { return nil, err } @@ -8995,8 +7850,8 @@ func (c *Client) AcceptTeamInvitation(ctx context.Context, teamName TeamName, bo return c.Client.Do(req) } -func (c *Client) RemoveTeamMembershipWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewRemoveTeamMembershipRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) GetReportTemplate(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetReportTemplateRequest(c.Server, templateId) if err != nil { return nil, err } @@ -9007,8 +7862,8 @@ func (c *Client) RemoveTeamMembershipWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) RemoveTeamMembership(ctx context.Context, teamName TeamName, body RemoveTeamMembershipJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewRemoveTeamMembershipRequest(c.Server, teamName, body) +func (c *Client) UpdateReportTemplateWithBody(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateReportTemplateRequestWithBody(c.Server, templateId, contentType, body) if err != nil { return nil, err } @@ -9019,8 +7874,8 @@ func (c *Client) RemoveTeamMembership(ctx context.Context, teamName TeamName, bo return c.Client.Do(req) } -func (c *Client) GetTeamMemberships(ctx context.Context, teamName TeamName, params *GetTeamMembershipsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTeamMembershipsRequest(c.Server, teamName, params) +func (c *Client) UpdateReportTemplate(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateReportTemplateRequest(c.Server, templateId, body) if err != nil { return nil, err } @@ -9031,8 +7886,8 @@ func (c *Client) GetTeamMemberships(ctx context.Context, teamName TeamName, para return c.Client.Do(req) } -func (c *Client) DeleteTeamMembership(ctx context.Context, teamName TeamName, email EmailBasic, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteTeamMembershipRequest(c.Server, teamName, email) +func (c *Client) DeleteReport(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteReportRequest(c.Server, reportId) if err != nil { return nil, err } @@ -9043,8 +7898,8 @@ func (c *Client) DeleteTeamMembership(ctx context.Context, teamName TeamName, em return c.Client.Do(req) } -func (c *Client) DeleteNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteNotificationDestinationRequest(c.Server, teamName, notificationDestinationID) +func (c *Client) GetReport(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetReportRequest(c.Server, reportId) if err != nil { return nil, err } @@ -9055,8 +7910,8 @@ func (c *Client) DeleteNotificationDestination(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) GetNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetNotificationDestinationRequest(c.Server, teamName, notificationDestinationID) +func (c *Client) UpdateReportWithBody(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateReportRequestWithBody(c.Server, reportId, contentType, body) if err != nil { return nil, err } @@ -9067,8 +7922,8 @@ func (c *Client) GetNotificationDestination(ctx context.Context, teamName TeamNa return c.Client.Do(req) } -func (c *Client) UpdateNotificationDestinationWithBody(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateNotificationDestinationRequestWithBody(c.Server, teamName, notificationDestinationID, contentType, body) +func (c *Client) UpdateReport(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateReportRequest(c.Server, reportId, body) if err != nil { return nil, err } @@ -9079,32 +7934,8 @@ func (c *Client) UpdateNotificationDestinationWithBody(ctx context.Context, team return c.Client.Do(req) } -func (c *Client) UpdateNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateNotificationDestinationRequest(c.Server, teamName, notificationDestinationID, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetNotificationDestinationAlerts(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetNotificationDestinationAlertsRequest(c.Server, teamName, notificationDestinationID, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) TestNotificationDestination(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTestNotificationDestinationRequest(c.Server, teamName, notificationDestinationID) +func (c *Client) GetSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSettingsRequest(c.Server) if err != nil { return nil, err } @@ -9115,8 +7946,8 @@ func (c *Client) TestNotificationDestination(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) ListAllNotificationDestinations(ctx context.Context, teamName TeamName, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllNotificationDestinationsRequest(c.Server, teamName, params) +func (c *Client) UpdateSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSettingsRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9127,8 +7958,8 @@ func (c *Client) ListAllNotificationDestinations(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) CreateNotificationDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateNotificationDestinationRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdateSettings(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSettingsRequest(c.Server, body) if err != nil { return nil, err } @@ -9139,8 +7970,8 @@ func (c *Client) CreateNotificationDestinationWithBody(ctx context.Context, team return c.Client.Do(req) } -func (c *Client) CreateNotificationDestination(ctx context.Context, teamName TeamName, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateNotificationDestinationRequest(c.Server, teamName, body) +func (c *Client) GetDataSettings(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDataSettingsRequest(c.Server) if err != nil { return nil, err } @@ -9151,8 +7982,8 @@ func (c *Client) CreateNotificationDestination(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) TestUnsavedNotificationDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTestUnsavedNotificationDestinationRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdateDataSettingsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateDataSettingsRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9163,8 +7994,8 @@ func (c *Client) TestUnsavedNotificationDestinationWithBody(ctx context.Context, return c.Client.Do(req) } -func (c *Client) TestUnsavedNotificationDestination(ctx context.Context, teamName TeamName, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTestUnsavedNotificationDestinationRequest(c.Server, teamName, body) +func (c *Client) UpdateDataSettings(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateDataSettingsRequest(c.Server, body) if err != nil { return nil, err } @@ -9175,8 +8006,8 @@ func (c *Client) TestUnsavedNotificationDestination(ctx context.Context, teamNam return c.Client.Do(req) } -func (c *Client) CreateAWSOnboardingWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateAWSOnboardingRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) CreateSlackConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSlackConnectionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9187,8 +8018,8 @@ func (c *Client) CreateAWSOnboardingWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) CreateAWSOnboarding(ctx context.Context, teamName TeamName, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateAWSOnboardingRequest(c.Server, teamName, body) +func (c *Client) CreateSlackConnection(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSlackConnectionRequest(c.Server, body) if err != nil { return nil, err } @@ -9199,8 +8030,8 @@ func (c *Client) CreateAWSOnboarding(ctx context.Context, teamName TeamName, bod return c.Client.Do(req) } -func (c *Client) GetAWSOnboarding(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetAWSOnboardingRequest(c.Server, teamName, onboardingID) +func (c *Client) ListSlackChannels(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSlackChannelsRequest(c.Server, id, params) if err != nil { return nil, err } @@ -9211,8 +8042,8 @@ func (c *Client) GetAWSOnboarding(ctx context.Context, teamName TeamName, onboar return c.Client.Do(req) } -func (c *Client) GetAWSAccountsInRoot(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetAWSAccountsInRootRequest(c.Server, teamName, onboardingID) +func (c *Client) CreateSyncDestinationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncDestinationTestConnectionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9223,8 +8054,8 @@ func (c *Client) GetAWSAccountsInRoot(ctx context.Context, teamName TeamName, on return c.Client.Do(req) } -func (c *Client) ProvisionOnboardingConfigurationWithBody(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewProvisionOnboardingConfigurationRequestWithBody(c.Server, teamName, onboardingID, contentType, body) +func (c *Client) CreateSyncDestinationTestConnection(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncDestinationTestConnectionRequest(c.Server, body) if err != nil { return nil, err } @@ -9235,8 +8066,8 @@ func (c *Client) ProvisionOnboardingConfigurationWithBody(ctx context.Context, t return c.Client.Do(req) } -func (c *Client) ProvisionOnboardingConfiguration(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewProvisionOnboardingConfigurationRequest(c.Server, teamName, onboardingID, body) +func (c *Client) GetSyncDestinationTestConnection(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncDestinationTestConnectionRequest(c.Server, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -9247,8 +8078,8 @@ func (c *Client) ProvisionOnboardingConfiguration(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) GetAWSAccountsInParent(ctx context.Context, teamName TeamName, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetAWSAccountsInParentRequest(c.Server, teamName, onboardingID, organizationalUnitID) +func (c *Client) UpdateSyncTestConnectionForSyncDestinationWithBody(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(c.Server, syncDestinationTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -9259,8 +8090,8 @@ func (c *Client) GetAWSAccountsInParent(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) NotifyOnboardingWithBody(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewNotifyOnboardingRequestWithBody(c.Server, teamName, onboardingID, contentType, body) +func (c *Client) UpdateSyncTestConnectionForSyncDestination(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncDestinationRequest(c.Server, syncDestinationTestConnectionID, body) if err != nil { return nil, err } @@ -9271,8 +8102,8 @@ func (c *Client) NotifyOnboardingWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) NotifyOnboarding(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewNotifyOnboardingRequest(c.Server, teamName, onboardingID, body) +func (c *Client) GetSyncDestinationTestConnectionLogsLive(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncDestinationTestConnectionLogsLiveRequest(c.Server, syncDestinationTestConnectionID, params) if err != nil { return nil, err } @@ -9283,8 +8114,8 @@ func (c *Client) NotifyOnboarding(ctx context.Context, teamName TeamName, onboar return c.Client.Do(req) } -func (c *Client) DeletePluginsByTeam(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePluginsByTeamRequest(c.Server, teamName) +func (c *Client) GetSyncDestinationTestConnectionLogsQuery(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncDestinationTestConnectionLogsQueryRequest(c.Server, syncDestinationTestConnectionID, params) if err != nil { return nil, err } @@ -9295,8 +8126,8 @@ func (c *Client) DeletePluginsByTeam(ctx context.Context, teamName TeamName, req return c.Client.Do(req) } -func (c *Client) ListPluginsByTeam(ctx context.Context, teamName TeamName, params *ListPluginsByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPluginsByTeamRequest(c.Server, teamName, params) +func (c *Client) PromoteSyncDestinationTestConnectionWithBody(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSyncDestinationTestConnectionRequestWithBody(c.Server, syncDestinationTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -9307,8 +8138,8 @@ func (c *Client) ListPluginsByTeam(ctx context.Context, teamName TeamName, param return c.Client.Do(req) } -func (c *Client) DownloadPluginAssetByTeam(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDownloadPluginAssetByTeamRequest(c.Server, teamName, pluginTeam, pluginKind, pluginName, versionName, targetName, params) +func (c *Client) PromoteSyncDestinationTestConnection(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSyncDestinationTestConnectionRequest(c.Server, syncDestinationTestConnectionID, body) if err != nil { return nil, err } @@ -9319,8 +8150,8 @@ func (c *Client) DownloadPluginAssetByTeam(ctx context.Context, teamName TeamNam return c.Client.Do(req) } -func (c *Client) ListPolicies(ctx context.Context, teamName TeamName, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPoliciesRequest(c.Server, teamName, params) +func (c *Client) ListSyncDestinations(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncDestinationsRequest(c.Server, params) if err != nil { return nil, err } @@ -9331,8 +8162,8 @@ func (c *Client) ListPolicies(ctx context.Context, teamName TeamName, params *Li return c.Client.Do(req) } -func (c *Client) CreatePolicyWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePolicyRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) DeleteSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSyncDestinationRequest(c.Server, syncDestinationName) if err != nil { return nil, err } @@ -9343,8 +8174,8 @@ func (c *Client) CreatePolicyWithBody(ctx context.Context, teamName TeamName, co return c.Client.Do(req) } -func (c *Client) CreatePolicy(ctx context.Context, teamName TeamName, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreatePolicyRequest(c.Server, teamName, body) +func (c *Client) GetSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncDestinationRequest(c.Server, syncDestinationName) if err != nil { return nil, err } @@ -9355,8 +8186,8 @@ func (c *Client) CreatePolicy(ctx context.Context, teamName TeamName, body Creat return c.Client.Do(req) } -func (c *Client) ListAllFrameworks(ctx context.Context, teamName TeamName, params *ListAllFrameworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllFrameworksRequest(c.Server, teamName, params) +func (c *Client) UpdateSyncDestinationWithBody(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncDestinationRequestWithBody(c.Server, syncDestinationName, contentType, body) if err != nil { return nil, err } @@ -9367,8 +8198,8 @@ func (c *Client) ListAllFrameworks(ctx context.Context, teamName TeamName, param return c.Client.Do(req) } -func (c *Client) DeletePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeletePolicyRequest(c.Server, teamName, policyId) +func (c *Client) UpdateSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncDestinationRequest(c.Server, syncDestinationName, body) if err != nil { return nil, err } @@ -9379,8 +8210,8 @@ func (c *Client) DeletePolicy(ctx context.Context, teamName TeamName, policyId o return c.Client.Do(req) } -func (c *Client) GetPolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetPolicyRequest(c.Server, teamName, policyId) +func (c *Client) ListSyncDestinationSyncs(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncDestinationSyncsRequest(c.Server, syncDestinationName, params) if err != nil { return nil, err } @@ -9391,8 +8222,8 @@ func (c *Client) GetPolicy(ctx context.Context, teamName TeamName, policyId open return c.Client.Do(req) } -func (c *Client) UpdatePolicyWithBody(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePolicyRequestWithBody(c.Server, teamName, policyId, contentType, body) +func (c *Client) GetTestConnectionForSyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTestConnectionForSyncDestinationRequest(c.Server, syncDestinationName, syncTestConnectionId) if err != nil { return nil, err } @@ -9403,8 +8234,8 @@ func (c *Client) UpdatePolicyWithBody(ctx context.Context, teamName TeamName, po return c.Client.Do(req) } -func (c *Client) UpdatePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdatePolicyRequest(c.Server, teamName, policyId, body) +func (c *Client) CreateSyncSourceTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncSourceTestConnectionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9415,8 +8246,8 @@ func (c *Client) UpdatePolicy(ctx context.Context, teamName TeamName, policyId o return c.Client.Do(req) } -func (c *Client) ListPolicyFrameworks(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyFrameworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPolicyFrameworksRequest(c.Server, teamName, policyId, params) +func (c *Client) CreateSyncSourceTestConnection(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncSourceTestConnectionRequest(c.Server, body) if err != nil { return nil, err } @@ -9427,8 +8258,8 @@ func (c *Client) ListPolicyFrameworks(ctx context.Context, teamName TeamName, po return c.Client.Do(req) } -func (c *Client) ListPolicyRules(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPolicyRulesRequest(c.Server, teamName, policyId, params) +func (c *Client) GetSyncSourceTestConnection(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncSourceTestConnectionRequest(c.Server, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -9439,8 +8270,8 @@ func (c *Client) ListPolicyRules(ctx context.Context, teamName TeamName, policyI return c.Client.Do(req) } -func (c *Client) ListPolicyRuleDetails(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, ruleId openapi_types.UUID, params *ListPolicyRuleDetailsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListPolicyRuleDetailsRequest(c.Server, teamName, policyId, ruleId, params) +func (c *Client) UpdateSyncTestConnectionForSyncSourceWithBody(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(c.Server, syncSourceTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -9451,8 +8282,8 @@ func (c *Client) ListPolicyRuleDetails(ctx context.Context, teamName TeamName, p return c.Client.Do(req) } -func (c *Client) TogglePolicy(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *TogglePolicyParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTogglePolicyRequest(c.Server, teamName, policyId, params) +func (c *Client) UpdateSyncTestConnectionForSyncSource(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncSourceRequest(c.Server, syncSourceTestConnectionID, body) if err != nil { return nil, err } @@ -9463,8 +8294,8 @@ func (c *Client) TogglePolicy(ctx context.Context, teamName TeamName, policyId o return c.Client.Do(req) } -func (c *Client) GetPolicyViolationsHistory(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetPolicyViolationsHistoryRequest(c.Server, teamName, policyId, params) +func (c *Client) GetSyncSourceTestConnectionLogsLive(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncSourceTestConnectionLogsLiveRequest(c.Server, syncSourceTestConnectionID, params) if err != nil { return nil, err } @@ -9475,8 +8306,8 @@ func (c *Client) GetPolicyViolationsHistory(ctx context.Context, teamName TeamNa return c.Client.Do(req) } -func (c *Client) ListAllQueriesTeam(ctx context.Context, teamName TeamName, params *ListAllQueriesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllQueriesTeamRequest(c.Server, teamName, params) +func (c *Client) GetSyncSourceTestConnectionLogsQuery(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncSourceTestConnectionLogsQueryRequest(c.Server, syncSourceTestConnectionID, params) if err != nil { return nil, err } @@ -9487,8 +8318,8 @@ func (c *Client) ListAllQueriesTeam(ctx context.Context, teamName TeamName, para return c.Client.Do(req) } -func (c *Client) ExecuteAdHocQueryTeamWithBody(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewExecuteAdHocQueryTeamRequestWithBody(c.Server, teamName, params, contentType, body) +func (c *Client) PromoteSyncSourceTestConnectionWithBody(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSyncSourceTestConnectionRequestWithBody(c.Server, syncSourceTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -9499,8 +8330,8 @@ func (c *Client) ExecuteAdHocQueryTeamWithBody(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) ExecuteAdHocQueryTeam(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, body ExecuteAdHocQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewExecuteAdHocQueryTeamRequest(c.Server, teamName, params, body) +func (c *Client) PromoteSyncSourceTestConnection(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSyncSourceTestConnectionRequest(c.Server, syncSourceTestConnectionID, body) if err != nil { return nil, err } @@ -9511,8 +8342,8 @@ func (c *Client) ExecuteAdHocQueryTeam(ctx context.Context, teamName TeamName, p return c.Client.Do(req) } -func (c *Client) SaveQueryTeamWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSaveQueryTeamRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) ListSyncSources(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncSourcesRequest(c.Server, params) if err != nil { return nil, err } @@ -9523,8 +8354,8 @@ func (c *Client) SaveQueryTeamWithBody(ctx context.Context, teamName TeamName, c return c.Client.Do(req) } -func (c *Client) SaveQueryTeam(ctx context.Context, teamName TeamName, body SaveQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSaveQueryTeamRequest(c.Server, teamName, body) +func (c *Client) DeleteSyncSource(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSyncSourceRequest(c.Server, syncSourceName) if err != nil { return nil, err } @@ -9535,8 +8366,8 @@ func (c *Client) SaveQueryTeam(ctx context.Context, teamName TeamName, body Save return c.Client.Do(req) } -func (c *Client) ListQueryTagsTeam(ctx context.Context, teamName TeamName, params *ListQueryTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListQueryTagsTeamRequest(c.Server, teamName, params) +func (c *Client) GetSyncSource(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncSourceRequest(c.Server, syncSourceName) if err != nil { return nil, err } @@ -9547,8 +8378,8 @@ func (c *Client) ListQueryTagsTeam(ctx context.Context, teamName TeamName, param return c.Client.Do(req) } -func (c *Client) DeleteSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteSavedQueryTeamRequest(c.Server, teamName, queryID) +func (c *Client) UpdateSyncSourceWithBody(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncSourceRequestWithBody(c.Server, syncSourceName, contentType, body) if err != nil { return nil, err } @@ -9559,8 +8390,8 @@ func (c *Client) DeleteSavedQueryTeam(ctx context.Context, teamName TeamName, qu return c.Client.Do(req) } -func (c *Client) GetSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSavedQueryTeamRequest(c.Server, teamName, queryID) +func (c *Client) UpdateSyncSource(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncSourceRequest(c.Server, syncSourceName, body) if err != nil { return nil, err } @@ -9571,8 +8402,8 @@ func (c *Client) GetSavedQueryTeam(ctx context.Context, teamName TeamName, query return c.Client.Do(req) } -func (c *Client) UpdateQueryTeamWithBody(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateQueryTeamRequestWithBody(c.Server, teamName, queryID, contentType, body) +func (c *Client) ListSyncSourceSyncs(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncSourceSyncsRequest(c.Server, syncSourceName, params) if err != nil { return nil, err } @@ -9583,8 +8414,8 @@ func (c *Client) UpdateQueryTeamWithBody(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) UpdateQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, body UpdateQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateQueryTeamRequest(c.Server, teamName, queryID, body) +func (c *Client) GetTestConnectionForSyncSource(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTestConnectionForSyncSourceRequest(c.Server, syncSourceName, syncTestConnectionId) if err != nil { return nil, err } @@ -9595,8 +8426,8 @@ func (c *Client) UpdateQueryTeam(ctx context.Context, teamName TeamName, queryID return c.Client.Do(req) } -func (c *Client) DeleteAlert(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteAlertRequest(c.Server, teamName, queryID) +func (c *Client) ListSyncTransformers(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncTransformersRequest(c.Server, params) if err != nil { return nil, err } @@ -9607,8 +8438,8 @@ func (c *Client) DeleteAlert(ctx context.Context, teamName TeamName, queryID Que return c.Client.Do(req) } -func (c *Client) ExecuteSavedQueryTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *ExecuteSavedQueryTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewExecuteSavedQueryTeamRequest(c.Server, teamName, queryID, params) +func (c *Client) DeleteSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSyncTransformerRequest(c.Server, syncTransformerName) if err != nil { return nil, err } @@ -9619,8 +8450,8 @@ func (c *Client) ExecuteSavedQueryTeam(ctx context.Context, teamName TeamName, q return c.Client.Do(req) } -func (c *Client) QueryListFiltersTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewQueryListFiltersTeamRequest(c.Server, teamName, queryID, params) +func (c *Client) GetSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncTransformerRequest(c.Server, syncTransformerName) if err != nil { return nil, err } @@ -9631,8 +8462,8 @@ func (c *Client) QueryListFiltersTeam(ctx context.Context, teamName TeamName, qu return c.Client.Do(req) } -func (c *Client) QuerySaveFilterTeamWithBody(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewQuerySaveFilterTeamRequestWithBody(c.Server, teamName, queryID, contentType, body) +func (c *Client) UpdateSyncTransformerWithBody(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTransformerRequestWithBody(c.Server, syncTransformerName, contentType, body) if err != nil { return nil, err } @@ -9643,8 +8474,8 @@ func (c *Client) QuerySaveFilterTeamWithBody(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) QuerySaveFilterTeam(ctx context.Context, teamName TeamName, queryID QueryID, body QuerySaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewQuerySaveFilterTeamRequest(c.Server, teamName, queryID, body) +func (c *Client) UpdateSyncTransformer(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTransformerRequest(c.Server, syncTransformerName, body) if err != nil { return nil, err } @@ -9655,8 +8486,8 @@ func (c *Client) QuerySaveFilterTeam(ctx context.Context, teamName TeamName, que return c.Client.Do(req) } -func (c *Client) QueryListFilterTagsTeam(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewQueryListFilterTagsTeamRequest(c.Server, teamName, queryID, params) +func (c *Client) ListSyncTransformerSyncDestinations(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncTransformerSyncDestinationsRequest(c.Server, syncTransformerName, params) if err != nil { return nil, err } @@ -9667,8 +8498,8 @@ func (c *Client) QueryListFilterTagsTeam(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) ListAllRBACPermissions(ctx context.Context, teamName TeamName, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllRBACPermissionsRequest(c.Server, teamName, params) +func (c *Client) ListSyncTransformerSyncs(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncTransformerSyncsRequest(c.Server, syncTransformerName, params) if err != nil { return nil, err } @@ -9679,8 +8510,8 @@ func (c *Client) ListAllRBACPermissions(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) CreateRBACPermissionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateRBACPermissionRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) ListSyncUpgrades(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncUpgradesRequest(c.Server, params) if err != nil { return nil, err } @@ -9691,8 +8522,8 @@ func (c *Client) CreateRBACPermissionWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) CreateRBACPermission(ctx context.Context, teamName TeamName, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateRBACPermissionRequest(c.Server, teamName, body) +func (c *Client) ListSyncs(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncsRequest(c.Server, params) if err != nil { return nil, err } @@ -9703,8 +8534,8 @@ func (c *Client) CreateRBACPermission(ctx context.Context, teamName TeamName, bo return c.Client.Do(req) } -func (c *Client) DeleteRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteRBACPermissionRequest(c.Server, teamName, rbacPermissionID) +func (c *Client) CreateSyncWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9715,8 +8546,8 @@ func (c *Client) DeleteRBACPermission(ctx context.Context, teamName TeamName, rb return c.Client.Do(req) } -func (c *Client) GetRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetRBACPermissionRequest(c.Server, teamName, rbacPermissionID) +func (c *Client) CreateSync(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRequest(c.Server, body) if err != nil { return nil, err } @@ -9727,8 +8558,8 @@ func (c *Client) GetRBACPermission(ctx context.Context, teamName TeamName, rbacP return c.Client.Do(req) } -func (c *Client) UpdateRBACPermissionWithBody(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateRBACPermissionRequestWithBody(c.Server, teamName, rbacPermissionID, contentType, body) +func (c *Client) DeleteSync(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSyncRequest(c.Server, syncName) if err != nil { return nil, err } @@ -9739,8 +8570,8 @@ func (c *Client) UpdateRBACPermissionWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) UpdateRBACPermission(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateRBACPermissionRequest(c.Server, teamName, rbacPermissionID, body) +func (c *Client) GetSync(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRequest(c.Server, syncName) if err != nil { return nil, err } @@ -9751,8 +8582,8 @@ func (c *Client) UpdateRBACPermission(ctx context.Context, teamName TeamName, rb return c.Client.Do(req) } -func (c *Client) ListAllRBACRoles(ctx context.Context, teamName TeamName, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListAllRBACRolesRequest(c.Server, teamName, params) +func (c *Client) UpdateSyncWithBody(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncRequestWithBody(c.Server, syncName, contentType, body) if err != nil { return nil, err } @@ -9763,8 +8594,8 @@ func (c *Client) ListAllRBACRoles(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) CreateRBACRoleWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateRBACRoleRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdateSync(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncRequest(c.Server, syncName, body) if err != nil { return nil, err } @@ -9775,8 +8606,8 @@ func (c *Client) CreateRBACRoleWithBody(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) CreateRBACRole(ctx context.Context, teamName TeamName, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateRBACRoleRequest(c.Server, teamName, body) +func (c *Client) ListSyncRuns(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListSyncRunsRequest(c.Server, syncName, params) if err != nil { return nil, err } @@ -9787,8 +8618,8 @@ func (c *Client) CreateRBACRole(ctx context.Context, teamName TeamName, body Cre return c.Client.Do(req) } -func (c *Client) DeleteRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteRBACRoleRequest(c.Server, teamName, rbacCustomRoleID) +func (c *Client) CreateSyncRun(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRunRequest(c.Server, syncName) if err != nil { return nil, err } @@ -9799,8 +8630,8 @@ func (c *Client) DeleteRBACRole(ctx context.Context, teamName TeamName, rbacCust return c.Client.Do(req) } -func (c *Client) GetRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetRBACRoleRequest(c.Server, teamName, rbacCustomRoleID) +func (c *Client) GetSyncRun(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRunRequest(c.Server, syncName, syncRunId) if err != nil { return nil, err } @@ -9811,8 +8642,8 @@ func (c *Client) GetRBACRole(ctx context.Context, teamName TeamName, rbacCustomR return c.Client.Do(req) } -func (c *Client) UpdateRBACRoleWithBody(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateRBACRoleRequestWithBody(c.Server, teamName, rbacCustomRoleID, contentType, body) +func (c *Client) UpdateSyncRunWithBody(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncRunRequestWithBody(c.Server, syncName, syncRunId, contentType, body) if err != nil { return nil, err } @@ -9823,8 +8654,8 @@ func (c *Client) UpdateRBACRoleWithBody(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) UpdateRBACRole(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateRBACRoleRequest(c.Server, teamName, rbacCustomRoleID, body) +func (c *Client) UpdateSyncRun(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncRunRequest(c.Server, syncName, syncRunId, body) if err != nil { return nil, err } @@ -9835,8 +8666,8 @@ func (c *Client) UpdateRBACRole(ctx context.Context, teamName TeamName, rbacCust return c.Client.Do(req) } -func (c *Client) ListReports(ctx context.Context, teamName TeamName, params *ListReportsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListReportsRequest(c.Server, teamName, params) +func (c *Client) GetSyncRunLogsLive(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRunLogsLiveRequest(c.Server, syncName, syncRunId, params) if err != nil { return nil, err } @@ -9847,8 +8678,8 @@ func (c *Client) ListReports(ctx context.Context, teamName TeamName, params *Lis return c.Client.Do(req) } -func (c *Client) CreateReportWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateReportRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) GetSyncRunLogsQuery(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRunLogsQueryRequest(c.Server, syncName, syncRunId, params) if err != nil { return nil, err } @@ -9859,8 +8690,8 @@ func (c *Client) CreateReportWithBody(ctx context.Context, teamName TeamName, co return c.Client.Do(req) } -func (c *Client) CreateReport(ctx context.Context, teamName TeamName, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateReportRequest(c.Server, teamName, body) +func (c *Client) CreateSyncRunProgressWithBody(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRunProgressRequestWithBody(c.Server, syncName, syncRunId, contentType, body) if err != nil { return nil, err } @@ -9871,8 +8702,8 @@ func (c *Client) CreateReport(ctx context.Context, teamName TeamName, body Creat return c.Client.Do(req) } -func (c *Client) ListReportTemplates(ctx context.Context, teamName TeamName, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListReportTemplatesRequest(c.Server, teamName, params) +func (c *Client) CreateSyncRunProgress(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRunProgressRequest(c.Server, syncName, syncRunId, body) if err != nil { return nil, err } @@ -9883,8 +8714,8 @@ func (c *Client) ListReportTemplates(ctx context.Context, teamName TeamName, par return c.Client.Do(req) } -func (c *Client) CreateReportTemplateWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateReportTemplateRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) GetSyncRunStats(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRunStatsRequest(c.Server, syncName, syncRunId) if err != nil { return nil, err } @@ -9895,8 +8726,8 @@ func (c *Client) CreateReportTemplateWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) CreateReportTemplate(ctx context.Context, teamName TeamName, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateReportTemplateRequest(c.Server, teamName, body) +func (c *Client) GetSyncRunTables(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSyncRunTablesRequest(c.Server, syncName, syncRunId, params) if err != nil { return nil, err } @@ -9907,8 +8738,8 @@ func (c *Client) CreateReportTemplate(ctx context.Context, teamName TeamName, bo return c.Client.Do(req) } -func (c *Client) DeleteReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteReportTemplateRequest(c.Server, teamName, templateId) +func (c *Client) ListTables(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListTablesRequest(c.Server, params) if err != nil { return nil, err } @@ -9919,8 +8750,8 @@ func (c *Client) DeleteReportTemplate(ctx context.Context, teamName TeamName, te return c.Client.Do(req) } -func (c *Client) GetReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetReportTemplateRequest(c.Server, teamName, templateId) +func (c *Client) GetTablesData(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTablesDataRequest(c.Server, params) if err != nil { return nil, err } @@ -9931,8 +8762,8 @@ func (c *Client) GetReportTemplate(ctx context.Context, teamName TeamName, templ return c.Client.Do(req) } -func (c *Client) UpdateReportTemplateWithBody(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateReportTemplateRequestWithBody(c.Server, teamName, templateId, contentType, body) +func (c *Client) TablesDataActionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTablesDataActionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -9943,8 +8774,8 @@ func (c *Client) UpdateReportTemplateWithBody(ctx context.Context, teamName Team return c.Client.Do(req) } -func (c *Client) UpdateReportTemplate(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateReportTemplateRequest(c.Server, teamName, templateId, body) +func (c *Client) TablesDataAction(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTablesDataActionRequest(c.Server, body) if err != nil { return nil, err } @@ -9955,8 +8786,8 @@ func (c *Client) UpdateReportTemplate(ctx context.Context, teamName TeamName, te return c.Client.Do(req) } -func (c *Client) DeleteReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteReportRequest(c.Server, teamName, reportId) +func (c *Client) BatchTableSchemas(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewBatchTableSchemasRequest(c.Server, params) if err != nil { return nil, err } @@ -9967,8 +8798,8 @@ func (c *Client) DeleteReport(ctx context.Context, teamName TeamName, reportId o return c.Client.Do(req) } -func (c *Client) GetReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetReportRequest(c.Server, teamName, reportId) +func (c *Client) TableListColumns(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableListColumnsRequest(c.Server, tableName, params) if err != nil { return nil, err } @@ -9979,8 +8810,8 @@ func (c *Client) GetReport(ctx context.Context, teamName TeamName, reportId open return c.Client.Do(req) } -func (c *Client) UpdateReportWithBody(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateReportRequestWithBody(c.Server, teamName, reportId, contentType, body) +func (c *Client) TableColumnListValues(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableColumnListValuesRequest(c.Server, tableName, columnName, params) if err != nil { return nil, err } @@ -9991,8 +8822,8 @@ func (c *Client) UpdateReportWithBody(ctx context.Context, teamName TeamName, re return c.Client.Do(req) } -func (c *Client) UpdateReport(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateReportRequest(c.Server, teamName, reportId, body) +func (c *Client) TableListRows(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableListRowsRequest(c.Server, tableName, params) if err != nil { return nil, err } @@ -10003,8 +8834,8 @@ func (c *Client) UpdateReport(ctx context.Context, teamName TeamName, reportId o return c.Client.Do(req) } -func (c *Client) CreateSyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncDestinationTestConnectionRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) TableRowById(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableRowByIdRequest(c.Server, tableName, tableRowId, params) if err != nil { return nil, err } @@ -10015,8 +8846,8 @@ func (c *Client) CreateSyncDestinationTestConnectionWithBody(ctx context.Context return c.Client.Do(req) } -func (c *Client) CreateSyncDestinationTestConnection(ctx context.Context, teamName TeamName, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncDestinationTestConnectionRequest(c.Server, teamName, body) +func (c *Client) TableListFilters(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableListFiltersRequest(c.Server, tableName, params) if err != nil { return nil, err } @@ -10027,8 +8858,8 @@ func (c *Client) CreateSyncDestinationTestConnection(ctx context.Context, teamNa return c.Client.Do(req) } -func (c *Client) GetSyncDestinationTestConnection(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncDestinationTestConnectionRequest(c.Server, teamName, syncDestinationTestConnectionID) +func (c *Client) TableSaveFilterWithBody(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableSaveFilterRequestWithBody(c.Server, tableName, contentType, body) if err != nil { return nil, err } @@ -10039,8 +8870,8 @@ func (c *Client) GetSyncDestinationTestConnection(ctx context.Context, teamName return c.Client.Do(req) } -func (c *Client) UpdateSyncTestConnectionForSyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(c.Server, teamName, syncDestinationTestConnectionID, contentType, body) +func (c *Client) TableSaveFilter(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableSaveFilterRequest(c.Server, tableName, body) if err != nil { return nil, err } @@ -10051,8 +8882,8 @@ func (c *Client) UpdateSyncTestConnectionForSyncDestinationWithBody(ctx context. return c.Client.Do(req) } -func (c *Client) UpdateSyncTestConnectionForSyncDestination(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTestConnectionForSyncDestinationRequest(c.Server, teamName, syncDestinationTestConnectionID, body) +func (c *Client) TableListFilterTags(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableListFilterTagsRequest(c.Server, tableName, params) if err != nil { return nil, err } @@ -10063,8 +8894,8 @@ func (c *Client) UpdateSyncTestConnectionForSyncDestination(ctx context.Context, return c.Client.Do(req) } -func (c *Client) GetSyncDestinationTestConnectionLogs(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncDestinationTestConnectionLogsRequest(c.Server, teamName, syncDestinationTestConnectionID, params) +func (c *Client) TableSchema(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewTableSchemaRequest(c.Server, tableName) if err != nil { return nil, err } @@ -10075,8 +8906,8 @@ func (c *Client) GetSyncDestinationTestConnectionLogs(ctx context.Context, teamN return c.Client.Do(req) } -func (c *Client) GetSyncDestinationTestConnectionLogsLive(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncDestinationTestConnectionLogsLiveRequest(c.Server, teamName, syncDestinationTestConnectionID, params) +func (c *Client) ListTeams(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListTeamsRequest(c.Server, params) if err != nil { return nil, err } @@ -10087,8 +8918,8 @@ func (c *Client) GetSyncDestinationTestConnectionLogsLive(ctx context.Context, t return c.Client.Do(req) } -func (c *Client) GetSyncDestinationTestConnectionLogsQuery(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncDestinationTestConnectionLogsQueryRequest(c.Server, teamName, syncDestinationTestConnectionID, params) +func (c *Client) DownloadPluginAssetByTeam(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDownloadPluginAssetByTeamRequest(c.Server, teamName, pluginTeam, pluginKind, pluginName, versionName, targetName, params) if err != nil { return nil, err } @@ -10099,8 +8930,8 @@ func (c *Client) GetSyncDestinationTestConnectionLogsQuery(ctx context.Context, return c.Client.Do(req) } -func (c *Client) PromoteSyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPromoteSyncDestinationTestConnectionRequestWithBody(c.Server, teamName, syncDestinationTestConnectionID, contentType, body) +func (c *Client) UpdateSyncTestConnectionForSyncDestinationTeamWithBody(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(c.Server, teamName, syncDestinationTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -10111,8 +8942,8 @@ func (c *Client) PromoteSyncDestinationTestConnectionWithBody(ctx context.Contex return c.Client.Do(req) } -func (c *Client) PromoteSyncDestinationTestConnection(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPromoteSyncDestinationTestConnectionRequest(c.Server, teamName, syncDestinationTestConnectionID, body) +func (c *Client) UpdateSyncTestConnectionForSyncDestinationTeam(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncDestinationTeamRequest(c.Server, teamName, syncDestinationTestConnectionID, body) if err != nil { return nil, err } @@ -10123,8 +8954,8 @@ func (c *Client) PromoteSyncDestinationTestConnection(ctx context.Context, teamN return c.Client.Do(req) } -func (c *Client) ListSyncDestinations(ctx context.Context, teamName TeamName, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncDestinationsRequest(c.Server, teamName, params) +func (c *Client) UpdateSyncTestConnectionForSyncSourceTeamWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(c.Server, teamName, syncSourceTestConnectionID, contentType, body) if err != nil { return nil, err } @@ -10135,8 +8966,8 @@ func (c *Client) ListSyncDestinations(ctx context.Context, teamName TeamName, pa return c.Client.Do(req) } -func (c *Client) DeleteSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteSyncDestinationRequest(c.Server, teamName, syncDestinationName) +func (c *Client) UpdateSyncTestConnectionForSyncSourceTeam(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateSyncTestConnectionForSyncSourceTeamRequest(c.Server, teamName, syncSourceTestConnectionID, body) if err != nil { return nil, err } @@ -10147,8 +8978,8 @@ func (c *Client) DeleteSyncDestination(ctx context.Context, teamName TeamName, s return c.Client.Do(req) } -func (c *Client) GetSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncDestinationRequest(c.Server, teamName, syncDestinationName) +func (c *Client) CreateSyncRunProgressTeamWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRunProgressTeamRequestWithBody(c.Server, teamName, syncName, syncRunId, contentType, body) if err != nil { return nil, err } @@ -10159,8 +8990,8 @@ func (c *Client) GetSyncDestination(ctx context.Context, teamName TeamName, sync return c.Client.Do(req) } -func (c *Client) UpdateSyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncDestinationRequestWithBody(c.Server, teamName, syncDestinationName, contentType, body) +func (c *Client) CreateSyncRunProgressTeam(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSyncRunProgressTeamRequest(c.Server, teamName, syncName, syncRunId, body) if err != nil { return nil, err } @@ -10171,8 +9002,8 @@ func (c *Client) UpdateSyncDestinationWithBody(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) UpdateSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncDestinationRequest(c.Server, teamName, syncDestinationName, body) +func (c *Client) GetTeamUsageSummary(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTeamUsageSummaryRequest(c.Server, params) if err != nil { return nil, err } @@ -10183,8 +9014,8 @@ func (c *Client) UpdateSyncDestination(ctx context.Context, teamName TeamName, s return c.Client.Do(req) } -func (c *Client) MigrateSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewMigrateSyncDestinationRequest(c.Server, teamName, syncDestinationName) +func (c *Client) GetGroupedTeamUsageSummary(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetGroupedTeamUsageSummaryRequest(c.Server, groupBy, params) if err != nil { return nil, err } @@ -10195,8 +9026,8 @@ func (c *Client) MigrateSyncDestination(ctx context.Context, teamName TeamName, return c.Client.Do(req) } -func (c *Client) ListSyncDestinationSyncs(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncDestinationSyncsRequest(c.Server, teamName, syncDestinationName, params) +func (c *Client) GetCurrentUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCurrentUserRequest(c.Server) if err != nil { return nil, err } @@ -10207,8 +9038,8 @@ func (c *Client) ListSyncDestinationSyncs(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) GetTestConnectionForSyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTestConnectionForSyncDestinationRequest(c.Server, teamName, syncDestinationName, syncTestConnectionId) +func (c *Client) UpdateCurrentUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCurrentUserRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10219,8 +9050,8 @@ func (c *Client) GetTestConnectionForSyncDestination(ctx context.Context, teamNa return c.Client.Do(req) } -func (c *Client) CreateSyncSourceTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncSourceTestConnectionRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) UpdateCurrentUser(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCurrentUserRequest(c.Server, body) if err != nil { return nil, err } @@ -10231,8 +9062,8 @@ func (c *Client) CreateSyncSourceTestConnectionWithBody(ctx context.Context, tea return c.Client.Do(req) } -func (c *Client) CreateSyncSourceTestConnection(ctx context.Context, teamName TeamName, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncSourceTestConnectionRequest(c.Server, teamName, body) +func (c *Client) SendAnonymousEventWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendAnonymousEventRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10243,8 +9074,8 @@ func (c *Client) CreateSyncSourceTestConnection(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) GetSyncSourceTestConnection(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncSourceTestConnectionRequest(c.Server, teamName, syncSourceTestConnectionID) +func (c *Client) SendAnonymousEvent(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendAnonymousEventRequest(c.Server, body) if err != nil { return nil, err } @@ -10255,8 +9086,8 @@ func (c *Client) GetSyncSourceTestConnection(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) UpdateSyncTestConnectionForSyncSourceWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(c.Server, teamName, syncSourceTestConnectionID, contentType, body) +func (c *Client) AuthenticateUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewAuthenticateUserRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10267,8 +9098,8 @@ func (c *Client) UpdateSyncTestConnectionForSyncSourceWithBody(ctx context.Conte return c.Client.Do(req) } -func (c *Client) UpdateSyncTestConnectionForSyncSource(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTestConnectionForSyncSourceRequest(c.Server, teamName, syncSourceTestConnectionID, body) +func (c *Client) AuthenticateUser(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewAuthenticateUserRequest(c.Server, body) if err != nil { return nil, err } @@ -10279,8 +9110,8 @@ func (c *Client) UpdateSyncTestConnectionForSyncSource(ctx context.Context, team return c.Client.Do(req) } -func (c *Client) GetSyncSourceTestConnectionLogs(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncSourceTestConnectionLogsRequest(c.Server, teamName, syncSourceTestConnectionID, params) +func (c *Client) ChangeUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewChangeUserPasswordRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10291,8 +9122,8 @@ func (c *Client) GetSyncSourceTestConnectionLogs(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) GetSyncSourceTestConnectionLogsLive(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncSourceTestConnectionLogsLiveRequest(c.Server, teamName, syncSourceTestConnectionID, params) +func (c *Client) ChangeUserPassword(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewChangeUserPasswordRequest(c.Server, body) if err != nil { return nil, err } @@ -10303,8 +9134,8 @@ func (c *Client) GetSyncSourceTestConnectionLogsLive(ctx context.Context, teamNa return c.Client.Do(req) } -func (c *Client) GetSyncSourceTestConnectionLogsQuery(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncSourceTestConnectionLogsQueryRequest(c.Server, teamName, syncSourceTestConnectionID, params) +func (c *Client) UpdateCustomerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCustomerRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10315,8 +9146,8 @@ func (c *Client) GetSyncSourceTestConnectionLogsQuery(ctx context.Context, teamN return c.Client.Do(req) } -func (c *Client) PromoteSyncSourceTestConnectionWithBody(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPromoteSyncSourceTestConnectionRequestWithBody(c.Server, teamName, syncSourceTestConnectionID, contentType, body) +func (c *Client) UpdateCustomer(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateCustomerRequest(c.Server, body) if err != nil { return nil, err } @@ -10327,8 +9158,8 @@ func (c *Client) PromoteSyncSourceTestConnectionWithBody(ctx context.Context, te return c.Client.Do(req) } -func (c *Client) PromoteSyncSourceTestConnection(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPromoteSyncSourceTestConnectionRequest(c.Server, teamName, syncSourceTestConnectionID, body) +func (c *Client) SendUserEventWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendUserEventRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10339,8 +9170,8 @@ func (c *Client) PromoteSyncSourceTestConnection(ctx context.Context, teamName T return c.Client.Do(req) } -func (c *Client) ListSyncSources(ctx context.Context, teamName TeamName, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncSourcesRequest(c.Server, teamName, params) +func (c *Client) SendUserEvent(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewSendUserEventRequest(c.Server, body) if err != nil { return nil, err } @@ -10351,8 +9182,8 @@ func (c *Client) ListSyncSources(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) DeleteSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteSyncSourceRequest(c.Server, teamName, syncSourceName) +func (c *Client) LogoutUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewLogoutUserRequest(c.Server) if err != nil { return nil, err } @@ -10363,8 +9194,8 @@ func (c *Client) DeleteSyncSource(ctx context.Context, teamName TeamName, syncSo return c.Client.Do(req) } -func (c *Client) GetSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncSourceRequest(c.Server, teamName, syncSourceName) +func (c *Client) LoginUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewLoginUserRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10375,8 +9206,8 @@ func (c *Client) GetSyncSource(ctx context.Context, teamName TeamName, syncSourc return c.Client.Do(req) } -func (c *Client) UpdateSyncSourceWithBody(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncSourceRequestWithBody(c.Server, teamName, syncSourceName, contentType, body) +func (c *Client) LoginUser(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewLoginUserRequest(c.Server, body) if err != nil { return nil, err } @@ -10387,8 +9218,8 @@ func (c *Client) UpdateSyncSourceWithBody(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) UpdateSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncSourceRequest(c.Server, teamName, syncSourceName, body) +func (c *Client) UserTOTPDelete(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUserTOTPDeleteRequest(c.Server) if err != nil { return nil, err } @@ -10399,8 +9230,8 @@ func (c *Client) UpdateSyncSource(ctx context.Context, teamName TeamName, syncSo return c.Client.Do(req) } -func (c *Client) MigrateSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewMigrateSyncSourceRequest(c.Server, teamName, syncSourceName) +func (c *Client) UserTOTPSetup(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUserTOTPSetupRequest(c.Server) if err != nil { return nil, err } @@ -10411,8 +9242,8 @@ func (c *Client) MigrateSyncSource(ctx context.Context, teamName TeamName, syncS return c.Client.Do(req) } -func (c *Client) ListSyncSourceSyncs(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncSourceSyncsRequest(c.Server, teamName, syncSourceName, params) +func (c *Client) UserTOTPVerifyWithBody(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUserTOTPVerifyRequestWithBody(c.Server, params, contentType, body) if err != nil { return nil, err } @@ -10423,8 +9254,8 @@ func (c *Client) ListSyncSourceSyncs(ctx context.Context, teamName TeamName, syn return c.Client.Do(req) } -func (c *Client) GetTestConnectionForSyncSource(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTestConnectionForSyncSourceRequest(c.Server, teamName, syncSourceName, syncTestConnectionId) +func (c *Client) UserTOTPVerify(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUserTOTPVerifyRequest(c.Server, params, body) if err != nil { return nil, err } @@ -10435,8 +9266,8 @@ func (c *Client) GetTestConnectionForSyncSource(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) ListSyncTransformers(ctx context.Context, teamName TeamName, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncTransformersRequest(c.Server, teamName, params) +func (c *Client) ListUsers(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListUsersRequest(c.Server, params) if err != nil { return nil, err } @@ -10447,8 +9278,8 @@ func (c *Client) ListSyncTransformers(ctx context.Context, teamName TeamName, pa return c.Client.Do(req) } -func (c *Client) DeleteSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteSyncTransformerRequest(c.Server, teamName, syncTransformerName) +func (c *Client) AddUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewAddUserRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10459,8 +9290,8 @@ func (c *Client) DeleteSyncTransformer(ctx context.Context, teamName TeamName, s return c.Client.Do(req) } -func (c *Client) GetSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncTransformerRequest(c.Server, teamName, syncTransformerName) +func (c *Client) AddUser(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewAddUserRequest(c.Server, body) if err != nil { return nil, err } @@ -10471,8 +9302,8 @@ func (c *Client) GetSyncTransformer(ctx context.Context, teamName TeamName, sync return c.Client.Do(req) } -func (c *Client) UpdateSyncTransformerWithBody(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTransformerRequestWithBody(c.Server, teamName, syncTransformerName, contentType, body) +func (c *Client) DeleteUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteUserRequest(c.Server, userID) if err != nil { return nil, err } @@ -10483,8 +9314,8 @@ func (c *Client) UpdateSyncTransformerWithBody(ctx context.Context, teamName Tea return c.Client.Do(req) } -func (c *Client) UpdateSyncTransformer(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncTransformerRequest(c.Server, teamName, syncTransformerName, body) +func (c *Client) GetUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetUserRequest(c.Server, userID) if err != nil { return nil, err } @@ -10495,8 +9326,8 @@ func (c *Client) UpdateSyncTransformer(ctx context.Context, teamName TeamName, s return c.Client.Do(req) } -func (c *Client) ListSyncTransformerSyncDestinations(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncTransformerSyncDestinationsRequest(c.Server, teamName, syncTransformerName, params) +func (c *Client) UpdateUserWithBody(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateUserRequestWithBody(c.Server, userID, contentType, body) if err != nil { return nil, err } @@ -10507,8 +9338,8 @@ func (c *Client) ListSyncTransformerSyncDestinations(ctx context.Context, teamNa return c.Client.Do(req) } -func (c *Client) ListSyncTransformerSyncs(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncTransformerSyncsRequest(c.Server, teamName, syncTransformerName, params) +func (c *Client) UpdateUser(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateUserRequest(c.Server, userID, body) if err != nil { return nil, err } @@ -10519,8 +9350,8 @@ func (c *Client) ListSyncTransformerSyncs(ctx context.Context, teamName TeamName return c.Client.Do(req) } -func (c *Client) ListSyncUpgrades(ctx context.Context, teamName TeamName, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncUpgradesRequest(c.Server, teamName, params) +func (c *Client) DeleteUserTOTP(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteUserTOTPRequest(c.Server, userID) if err != nil { return nil, err } @@ -10531,8 +9362,8 @@ func (c *Client) ListSyncUpgrades(ctx context.Context, teamName TeamName, params return c.Client.Do(req) } -func (c *Client) ListSyncs(ctx context.Context, teamName TeamName, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncsRequest(c.Server, teamName, params) +func (c *Client) CreateV2SyncDestinationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncDestinationTestConnectionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10543,8 +9374,8 @@ func (c *Client) ListSyncs(ctx context.Context, teamName TeamName, params *ListS return c.Client.Do(req) } -func (c *Client) CreateSyncWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncRequestWithBody(c.Server, teamName, contentType, body) +func (c *Client) CreateV2SyncDestinationTestConnection(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncDestinationTestConnectionRequest(c.Server, body) if err != nil { return nil, err } @@ -10555,8 +9386,8 @@ func (c *Client) CreateSyncWithBody(ctx context.Context, teamName TeamName, cont return c.Client.Do(req) } -func (c *Client) CreateSync(ctx context.Context, teamName TeamName, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncRequest(c.Server, teamName, body) +func (c *Client) GetV2SyncDestinations(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetV2SyncDestinationsRequest(c.Server, params) if err != nil { return nil, err } @@ -10567,8 +9398,8 @@ func (c *Client) CreateSync(ctx context.Context, teamName TeamName, body CreateS return c.Client.Do(req) } -func (c *Client) GetTestConnectionConnectorCredentials(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTestConnectionConnectorCredentialsRequest(c.Server, teamName, syncTestConnectionId, connectorID) +func (c *Client) CreateV2SyncDestinationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncDestinationRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10579,8 +9410,8 @@ func (c *Client) GetTestConnectionConnectorCredentials(ctx context.Context, team return c.Client.Do(req) } -func (c *Client) GetTestConnectionConnectorIdentity(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTestConnectionConnectorIdentityRequest(c.Server, teamName, syncTestConnectionId, connectorID) +func (c *Client) CreateV2SyncDestination(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncDestinationRequest(c.Server, body) if err != nil { return nil, err } @@ -10591,8 +9422,8 @@ func (c *Client) GetTestConnectionConnectorIdentity(ctx context.Context, teamNam return c.Client.Do(req) } -func (c *Client) DeleteSync(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteSyncRequest(c.Server, teamName, syncName) +func (c *Client) DeleteV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteV2SyncDestinationRequest(c.Server, syncDestinationName) if err != nil { return nil, err } @@ -10603,8 +9434,8 @@ func (c *Client) DeleteSync(ctx context.Context, teamName TeamName, syncName Syn return c.Client.Do(req) } -func (c *Client) GetSync(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRequest(c.Server, teamName, syncName) +func (c *Client) GetV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetV2SyncDestinationRequest(c.Server, syncDestinationName) if err != nil { return nil, err } @@ -10615,8 +9446,8 @@ func (c *Client) GetSync(ctx context.Context, teamName TeamName, syncName SyncNa return c.Client.Do(req) } -func (c *Client) UpdateSyncWithBody(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncRequestWithBody(c.Server, teamName, syncName, contentType, body) +func (c *Client) PatchV2SyncDestinationWithBody(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchV2SyncDestinationRequestWithBody(c.Server, syncDestinationName, contentType, body) if err != nil { return nil, err } @@ -10627,8 +9458,8 @@ func (c *Client) UpdateSyncWithBody(ctx context.Context, teamName TeamName, sync return c.Client.Do(req) } -func (c *Client) UpdateSync(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncRequest(c.Server, teamName, syncName, body) +func (c *Client) PatchV2SyncDestination(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchV2SyncDestinationRequest(c.Server, syncDestinationName, body) if err != nil { return nil, err } @@ -10639,8 +9470,8 @@ func (c *Client) UpdateSync(ctx context.Context, teamName TeamName, syncName Syn return c.Client.Do(req) } -func (c *Client) ListSyncRuns(ctx context.Context, teamName TeamName, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListSyncRunsRequest(c.Server, teamName, syncName, params) +func (c *Client) CreateV2SyncIntegrationTestConnectionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncIntegrationTestConnectionRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10651,8 +9482,8 @@ func (c *Client) ListSyncRuns(ctx context.Context, teamName TeamName, syncName S return c.Client.Do(req) } -func (c *Client) CreateSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncRunRequest(c.Server, teamName, syncName) +func (c *Client) CreateV2SyncIntegrationTestConnection(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncIntegrationTestConnectionRequest(c.Server, body) if err != nil { return nil, err } @@ -10663,8 +9494,8 @@ func (c *Client) CreateSyncRun(ctx context.Context, teamName TeamName, syncName return c.Client.Do(req) } -func (c *Client) GetSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunRequest(c.Server, teamName, syncName, syncRunId) +func (c *Client) ListV2SyncIntegrations(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListV2SyncIntegrationsRequest(c.Server, params) if err != nil { return nil, err } @@ -10675,8 +9506,8 @@ func (c *Client) GetSyncRun(ctx context.Context, teamName TeamName, syncName Syn return c.Client.Do(req) } -func (c *Client) UpdateSyncRunWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncRunRequestWithBody(c.Server, teamName, syncName, syncRunId, contentType, body) +func (c *Client) CreateV2SyncIntegrationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncIntegrationRequestWithBody(c.Server, contentType, body) if err != nil { return nil, err } @@ -10687,8 +9518,8 @@ func (c *Client) UpdateSyncRunWithBody(ctx context.Context, teamName TeamName, s return c.Client.Do(req) } -func (c *Client) UpdateSyncRun(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateSyncRunRequest(c.Server, teamName, syncName, syncRunId, body) +func (c *Client) CreateV2SyncIntegration(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateV2SyncIntegrationRequest(c.Server, body) if err != nil { return nil, err } @@ -10699,8 +9530,8 @@ func (c *Client) UpdateSyncRun(ctx context.Context, teamName TeamName, syncName return c.Client.Do(req) } -func (c *Client) GetSyncRunConnectorCredentials(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunConnectorCredentialsRequest(c.Server, teamName, syncName, syncRunId, connectorID) +func (c *Client) DeleteV2SyncIntegration(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteV2SyncIntegrationRequest(c.Server, syncName, params) if err != nil { return nil, err } @@ -10711,8 +9542,8 @@ func (c *Client) GetSyncRunConnectorCredentials(ctx context.Context, teamName Te return c.Client.Do(req) } -func (c *Client) GetSyncRunConnectorIdentity(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunConnectorIdentityRequest(c.Server, teamName, syncName, syncRunId, connectorID) +func (c *Client) GetV2SyncIntegration(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetV2SyncIntegrationRequest(c.Server, syncName) if err != nil { return nil, err } @@ -10723,8 +9554,8 @@ func (c *Client) GetSyncRunConnectorIdentity(ctx context.Context, teamName TeamN return c.Client.Do(req) } -func (c *Client) GetSyncRunLogs(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunLogsRequest(c.Server, teamName, syncName, syncRunId, params) +func (c *Client) UpdateV2SyncIntegrationWithBody(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateV2SyncIntegrationRequestWithBody(c.Server, syncName, contentType, body) if err != nil { return nil, err } @@ -10735,8 +9566,8 @@ func (c *Client) GetSyncRunLogs(ctx context.Context, teamName TeamName, syncName return c.Client.Do(req) } -func (c *Client) GetSyncRunLogsLive(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunLogsLiveRequest(c.Server, teamName, syncName, syncRunId, params) +func (c *Client) UpdateV2SyncIntegration(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewUpdateV2SyncIntegrationRequest(c.Server, syncName, body) if err != nil { return nil, err } @@ -10747,852 +9578,362 @@ func (c *Client) GetSyncRunLogsLive(ctx context.Context, teamName TeamName, sync return c.Client.Do(req) } -func (c *Client) GetSyncRunLogsQuery(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunLogsQueryRequest(c.Server, teamName, syncName, syncRunId, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} +// NewIndexRequest generates requests for Index +func NewIndexRequest(server string) (*http.Request, error) { + var err error -func (c *Client) CreateSyncRunProgressWithBody(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncRunProgressRequestWithBody(c.Server, teamName, syncName, syncRunId, contentType, body) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) CreateSyncRunProgress(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateSyncRunProgressRequest(c.Server, teamName, syncName, syncRunId, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + operationPath := fmt.Sprintf("/") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) GetSyncRunStats(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunStatsRequest(c.Server, teamName, syncName, syncRunId) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) GetSyncRunTables(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetSyncRunTablesRequest(c.Server, teamName, syncName, syncRunId, params) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) ListTablesTeam(ctx context.Context, teamName TeamName, params *ListTablesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListTablesTeamRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + return req, nil } -func (c *Client) BatchTableSchemasTeam(ctx context.Context, teamName TeamName, params *BatchTableSchemasTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewBatchTableSchemasTeamRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} +// NewListAllAlertsRequest generates requests for ListAllAlerts +func NewListAllAlertsRequest(server string, params *ListAllAlertsParams) (*http.Request, error) { + var err error -func (c *Client) TableListColumnsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListColumnsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableListColumnsTeamRequest(c.Server, teamName, tableName, params) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) TableColumnListValuesTeam(ctx context.Context, teamName TeamName, tableName TableName, columnName ColumnName, params *TableColumnListValuesTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableColumnListValuesTeamRequest(c.Server, teamName, tableName, columnName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + operationPath := fmt.Sprintf("/alerts") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) TableListRowsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRowsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableListRowsTeamRequest(c.Server, teamName, tableName, params) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) TableRowByIdTeam(ctx context.Context, teamName TeamName, tableName TableName, tableRowId TableRowId, params *TableRowByIdTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableRowByIdTeamRequest(c.Server, teamName, tableName, tableRowId, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if params != nil { + queryValues := queryURL.Query() -func (c *Client) TableListFiltersTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFiltersTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableListFiltersTeamRequest(c.Server, teamName, tableName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if params.PerPage != nil { -func (c *Client) TableSaveFilterTeamWithBody(ctx context.Context, teamName TeamName, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableSaveFilterTeamRequestWithBody(c.Server, teamName, tableName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -func (c *Client) TableSaveFilterTeam(ctx context.Context, teamName TeamName, tableName TableName, body TableSaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableSaveFilterTeamRequest(c.Server, teamName, tableName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + } -func (c *Client) TableListFilterTagsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableListFilterTagsTeamRequest(c.Server, teamName, tableName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if params.Page != nil { -func (c *Client) TableListRelationsTeam(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRelationsTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableListRelationsTeamRequest(c.Server, teamName, tableName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -func (c *Client) TableSchemaTeam(ctx context.Context, teamName TeamName, tableName TableName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewTableSchemaTeamRequest(c.Server, teamName, tableName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + } -func (c *Client) GetTeamUsageSummary(ctx context.Context, teamName TeamName, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetTeamUsageSummaryRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if params.AlertStates != nil { -func (c *Client) GetGroupedTeamUsageSummary(ctx context.Context, teamName TeamName, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetGroupedTeamUsageSummaryRequest(c.Server, teamName, groupBy, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "state", runtime.ParamLocationQuery, params.AlertStates); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -func (c *Client) ListUsersByTeam(ctx context.Context, teamName TeamName, params *ListUsersByTeamParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListUsersByTeamRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + } -func (c *Client) UploadImageWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUploadImageRequestWithBody(c.Server, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} + if params.Enabled != nil { -func (c *Client) UploadImage(ctx context.Context, body UploadImageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUploadImageRequest(c.Server, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "enabled", runtime.ParamLocationQuery, *params.Enabled); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.QueryTags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.QueryTags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - return c.Client.Do(req) -} -func (c *Client) GetCurrentUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetCurrentUserRequest(c.Server) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + + return req, nil } -func (c *Client) UpdateCurrentUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCurrentUserRequestWithBody(c.Server, contentType, body) +// NewTestUnsavedAlertRequest calls the generic TestUnsavedAlert builder with application/json body +func NewTestUnsavedAlertRequest(server string, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + bodyReader = bytes.NewReader(buf) + return NewTestUnsavedAlertRequestWithBody(server, params, "application/json", bodyReader) } -func (c *Client) UpdateCurrentUser(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCurrentUserRequest(c.Server, body) +// NewTestUnsavedAlertRequestWithBody generates requests for TestUnsavedAlert with any type of body +func NewTestUnsavedAlertRequestWithBody(server string, params *TestUnsavedAlertParams, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + operationPath := fmt.Sprintf("/alerts/test") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) SendAnonymousEventWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendAnonymousEventRequestWithBody(c.Server, contentType, body) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + if params != nil { + queryValues := queryURL.Query() + + if params.QueryID != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_id", runtime.ParamLocationQuery, *params.QueryID); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - return c.Client.Do(req) -} -func (c *Client) SendAnonymousEvent(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendAnonymousEventRequest(c.Server, body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + + req.Header.Add("Content-Type", contentType) + + return req, nil } -func (c *Client) AuthenticateLocalUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateLocalUserRequestWithBody(c.Server, contentType, body) +// NewListAPIKeysRequest generates requests for ListAPIKeys +func NewListAPIKeysRequest(server string, params *ListAPIKeysParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + operationPath := fmt.Sprintf("/apikeys") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) AuthenticateLocalUser(ctx context.Context, body AuthenticateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewAuthenticateLocalUserRequest(c.Server, body) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - return c.Client.Do(req) -} -func (c *Client) ChangeLocalUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewChangeLocalUserPasswordRequestWithBody(c.Server, contentType, body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + + return req, nil } -func (c *Client) ChangeLocalUserPassword(ctx context.Context, body ChangeLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewChangeLocalUserPasswordRequest(c.Server, body) +// NewCreateAPIKeyRequest calls the generic CreateAPIKey builder with application/json body +func NewCreateAPIKeyRequest(server string, body CreateAPIKeyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + bodyReader = bytes.NewReader(buf) + return NewCreateAPIKeyRequestWithBody(server, "application/json", bodyReader) } -func (c *Client) UpdateCustomerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCustomerRequestWithBody(c.Server, contentType, body) +// NewCreateAPIKeyRequestWithBody generates requests for CreateAPIKey with any type of body +func NewCreateAPIKeyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + operationPath := fmt.Sprintf("/apikeys") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) UpdateCustomer(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateCustomerRequest(c.Server, body) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) SendUserEventWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendUserEventRequestWithBody(c.Server, contentType, body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + + req.Header.Add("Content-Type", contentType) + + return req, nil } -func (c *Client) SendUserEvent(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewSendUserEventRequest(c.Server, body) +// NewDeleteAPIKeyRequest generates requests for DeleteAPIKey +func NewDeleteAPIKeyRequest(server string, apiKeyID APIKeyID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "apikey_id", runtime.ParamLocationPath, apiKeyID) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) ListCurrentUserInvitations(ctx context.Context, params *ListCurrentUserInvitationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListCurrentUserInvitationsRequest(c.Server, params) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + operationPath := fmt.Sprintf("/apikeys/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) GetCurrentLocalUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetCurrentLocalUserRequest(c.Server) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} -func (c *Client) LogoutUser(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewLogoutUserRequest(c.Server) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) + + return req, nil } -func (c *Client) LoginUserWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewLoginUserRequestWithBody(c.Server, contentType, body) +// NewListAuditLogsRequest generates requests for ListAuditLogs +func NewListAuditLogsRequest(server string, params *ListAuditLogsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err + + operationPath := fmt.Sprintf("/audit-logs") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return c.Client.Do(req) -} -func (c *Client) LoginUser(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewLoginUserRequest(c.Server, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetCurrentUserMemberships(ctx context.Context, params *GetCurrentUserMembershipsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetCurrentUserMembershipsRequest(c.Server, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) ResetLocalUserPasswordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewResetLocalUserPasswordRequestWithBody(c.Server, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) ResetLocalUserPassword(ctx context.Context, body ResetLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewResetLocalUserPasswordRequest(c.Server, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateUserToken(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateUserTokenRequest(c.Server) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UserTOTPDelete(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUserTOTPDeleteRequest(c.Server) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UserTOTPSetup(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUserTOTPSetupRequest(c.Server) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UserTOTPVerifyWithBody(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUserTOTPVerifyRequestWithBody(c.Server, params, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UserTOTPVerify(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUserTOTPVerifyRequest(c.Server, params, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) DeleteUser(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteUserRequest(c.Server, userID) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncDestinationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncDestinationTestConnectionRequestWithBody(c.Server, teamName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncDestinationTestConnection(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncDestinationTestConnectionRequest(c.Server, teamName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetV2SyncDestinations(ctx context.Context, teamName TeamName, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetV2SyncDestinationsRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncDestinationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncDestinationRequestWithBody(c.Server, teamName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncDestination(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncDestinationRequest(c.Server, teamName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) DeleteV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteV2SyncDestinationRequest(c.Server, teamName, syncDestinationName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetV2SyncDestinationRequest(c.Server, teamName, syncDestinationName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) PatchV2SyncDestinationWithBody(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPatchV2SyncDestinationRequestWithBody(c.Server, teamName, syncDestinationName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) PatchV2SyncDestination(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewPatchV2SyncDestinationRequest(c.Server, teamName, syncDestinationName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncIntegrationTestConnectionWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncIntegrationTestConnectionRequestWithBody(c.Server, teamName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncIntegrationTestConnection(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncIntegrationTestConnectionRequest(c.Server, teamName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) ListV2SyncIntegrations(ctx context.Context, teamName TeamName, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewListV2SyncIntegrationsRequest(c.Server, teamName, params) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncIntegrationWithBody(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncIntegrationRequestWithBody(c.Server, teamName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) CreateV2SyncIntegration(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewCreateV2SyncIntegrationRequest(c.Server, teamName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) DeleteV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewDeleteV2SyncIntegrationRequest(c.Server, teamName, syncName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) GetV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewGetV2SyncIntegrationRequest(c.Server, teamName, syncName) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UpdateV2SyncIntegrationWithBody(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateV2SyncIntegrationRequestWithBody(c.Server, teamName, syncName, contentType, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -func (c *Client) UpdateV2SyncIntegration(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { - req, err := NewUpdateV2SyncIntegrationRequest(c.Server, teamName, syncName, body) - if err != nil { - return nil, err - } - req = req.WithContext(ctx) - if err := c.applyEditors(ctx, req, reqEditors); err != nil { - return nil, err - } - return c.Client.Do(req) -} - -// NewIndexRequest generates requests for Index -func NewIndexRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListAuditLogsRequest generates requests for ListAuditLogs -func NewListAuditLogsRequest(server string, params *ListAuditLogsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/audit-logs") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } @@ -11648,22 +9989,6 @@ func NewListAuditLogsRequest(server string, params *ListAuditLogsParams) (*http. } - if params.TeamName != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "team_name", runtime.ParamLocationQuery, *params.TeamName); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.EventType != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "event_type", runtime.ParamLocationQuery, *params.EventType); err != nil { @@ -11805,8 +10130,8 @@ func NewGetAuditLogRequest(server string, id openapi_types.UUID) (*http.Request, return req, nil } -// NewHealthCheckRequest generates requests for HealthCheck -func NewHealthCheckRequest(server string) (*http.Request, error) { +// NewGetSAMLRequest generates requests for GetSAML +func NewGetSAMLRequest(server string) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -11814,7 +10139,7 @@ func NewHealthCheckRequest(server string) (*http.Request, error) { return nil, err } - operationPath := fmt.Sprintf("/healthcheck") + operationPath := fmt.Sprintf("/auth/saml") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11832,8 +10157,19 @@ func NewHealthCheckRequest(server string) (*http.Request, error) { return req, nil } -// NewHealthCheckHeadRequest generates requests for HealthCheckHead -func NewHealthCheckHeadRequest(server string) (*http.Request, error) { +// NewUpdateSAMLRequest calls the generic UpdateSAML builder with application/json body +func NewUpdateSAMLRequest(server string, body UpdateSAMLJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSAMLRequestWithBody(server, "application/json", bodyReader) +} + +// NewUpdateSAMLRequestWithBody generates requests for UpdateSAML with any type of body +func NewUpdateSAMLRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -11841,7 +10177,7 @@ func NewHealthCheckHeadRequest(server string) (*http.Request, error) { return nil, err } - operationPath := fmt.Sprintf("/healthcheck") + operationPath := fmt.Sprintf("/auth/saml") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11851,24 +10187,73 @@ func NewHealthCheckHeadRequest(server string) (*http.Request, error) { return nil, err } - req, err := http.NewRequest("HEAD", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewCreateConversationRequest calls the generic CreateConversation builder with application/json body +func NewCreateConversationRequest(server string, body CreateConversationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateConversationRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateConversationRequestWithBody generates requests for CreateConversation with any type of body +func NewCreateConversationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/conversations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewAssetViewGetStatusRequest generates requests for AssetViewGetStatus -func NewAssetViewGetStatusRequest(server string) (*http.Request, error) { +// NewGetConversationRequest generates requests for GetConversation +func NewGetConversationRequest(server string, conversationID ConversationID) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/assetview") + operationPath := fmt.Sprintf("/conversations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11886,16 +10271,34 @@ func NewAssetViewGetStatusRequest(server string) (*http.Request, error) { return req, nil } -// NewAssetViewTriggerRequest generates requests for AssetViewTrigger -func NewAssetViewTriggerRequest(server string) (*http.Request, error) { +// NewSendMessageRequest calls the generic SendMessage builder with application/json body +func NewSendMessageRequest(server string, conversationID ConversationID, body SendMessageJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewSendMessageRequestWithBody(server, conversationID, "application/json", bodyReader) +} + +// NewSendMessageRequestWithBody generates requests for SendMessage with any type of body +func NewSendMessageRequestWithBody(server string, conversationID ConversationID, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/assetview") + operationPath := fmt.Sprintf("/conversations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11905,16 +10308,18 @@ func NewAssetViewTriggerRequest(server string) (*http.Request, error) { return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewAssetViewListLogsRequest generates requests for AssetViewListLogs -func NewAssetViewListLogsRequest(server string, params *AssetViewListLogsParams) (*http.Request, error) { +// NewListAllCustomColumnsRequest generates requests for ListAllCustomColumns +func NewListAllCustomColumnsRequest(server string, params *ListAllCustomColumnsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -11922,7 +10327,7 @@ func NewAssetViewListLogsRequest(server string, params *AssetViewListLogsParams) return nil, err } - operationPath := fmt.Sprintf("/manage/assetview/logs") + operationPath := fmt.Sprintf("/custom-columns") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11967,9 +10372,9 @@ func NewAssetViewListLogsRequest(server string, params *AssetViewListLogsParams) } - if params.AssetViewRunTypes != nil { + if params.CustomColumnSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "type", runtime.ParamLocationQuery, params.AssetViewRunTypes); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.CustomColumnSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11983,34 +10388,39 @@ func NewAssetViewListLogsRequest(server string, params *AssetViewListLogsParams) } - queryURL.RawQuery = queryValues.Encode() - } + if params.CustomColumnSortDirections != nil { - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.CustomColumnSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - return req, nil -} + } -// NewManageGetSAMLRequest generates requests for ManageGetSAML -func NewManageGetSAMLRequest(server string) (*http.Request, error) { - var err error + if params.SearchTerm != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/manage/auth/saml") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -12021,19 +10431,19 @@ func NewManageGetSAMLRequest(server string) (*http.Request, error) { return req, nil } -// NewManageUpdateSAMLRequest calls the generic ManageUpdateSAML builder with application/json body -func NewManageUpdateSAMLRequest(server string, body ManageUpdateSAMLJSONRequestBody) (*http.Request, error) { +// NewSaveCustomColumnRequest calls the generic SaveCustomColumn builder with application/json body +func NewSaveCustomColumnRequest(server string, body SaveCustomColumnJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewManageUpdateSAMLRequestWithBody(server, "application/json", bodyReader) + return NewSaveCustomColumnRequestWithBody(server, "application/json", bodyReader) } -// NewManageUpdateSAMLRequestWithBody generates requests for ManageUpdateSAML with any type of body -func NewManageUpdateSAMLRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewSaveCustomColumnRequestWithBody generates requests for SaveCustomColumn with any type of body +func NewSaveCustomColumnRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12041,7 +10451,7 @@ func NewManageUpdateSAMLRequestWithBody(server string, contentType string, body return nil, err } - operationPath := fmt.Sprintf("/manage/auth/saml") + operationPath := fmt.Sprintf("/custom-columns") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12051,7 +10461,7 @@ func NewManageUpdateSAMLRequestWithBody(server string, contentType string, body return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -12061,16 +10471,23 @@ func NewManageUpdateSAMLRequestWithBody(server string, contentType string, body return req, nil } -// NewManageGetPlatformRegistryRequest generates requests for ManageGetPlatformRegistry -func NewManageGetPlatformRegistryRequest(server string) (*http.Request, error) { +// NewDeleteCustomColumnRequest generates requests for DeleteCustomColumn +func NewDeleteCustomColumnRequest(server string, customColumnID CustomColumnID) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/register-platform") + operationPath := fmt.Sprintf("/custom-columns/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12080,7 +10497,7 @@ func NewManageGetPlatformRegistryRequest(server string) (*http.Request, error) { return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -12088,27 +10505,23 @@ func NewManageGetPlatformRegistryRequest(server string) (*http.Request, error) { return req, nil } -// NewManageRegisterPlatformRequest calls the generic ManageRegisterPlatform builder with application/json body -func NewManageRegisterPlatformRequest(server string, body ManageRegisterPlatformJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewGetCustomColumnRequest generates requests for GetCustomColumn +func NewGetCustomColumnRequest(server string, customColumnID CustomColumnID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewManageRegisterPlatformRequestWithBody(server, "application/json", bodyReader) -} - -// NewManageRegisterPlatformRequestWithBody generates requests for ManageRegisterPlatform with any type of body -func NewManageRegisterPlatformRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/register-platform") + operationPath := fmt.Sprintf("/custom-columns/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12118,37 +10531,42 @@ func NewManageRegisterPlatformRequestWithBody(server string, contentType string, return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewManageRegisterPlatformWithOfflineLicenseRequest calls the generic ManageRegisterPlatformWithOfflineLicense builder with application/json body -func NewManageRegisterPlatformWithOfflineLicenseRequest(server string, body ManageRegisterPlatformWithOfflineLicenseJSONRequestBody) (*http.Request, error) { +// NewUpdateCustomColumnRequest calls the generic UpdateCustomColumn builder with application/json body +func NewUpdateCustomColumnRequest(server string, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewManageRegisterPlatformWithOfflineLicenseRequestWithBody(server, "application/json", bodyReader) + return NewUpdateCustomColumnRequestWithBody(server, customColumnID, "application/json", bodyReader) } -// NewManageRegisterPlatformWithOfflineLicenseRequestWithBody generates requests for ManageRegisterPlatformWithOfflineLicense with any type of body -func NewManageRegisterPlatformWithOfflineLicenseRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateCustomColumnRequestWithBody generates requests for UpdateCustomColumn with any type of body +func NewUpdateCustomColumnRequestWithBody(server string, customColumnID CustomColumnID, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/register-platform/offline") + operationPath := fmt.Sprintf("/custom-columns/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12158,7 +10576,7 @@ func NewManageRegisterPlatformWithOfflineLicenseRequestWithBody(server string, c return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -12168,8 +10586,8 @@ func NewManageRegisterPlatformWithOfflineLicenseRequestWithBody(server string, c return req, nil } -// NewGetSettingsRequest generates requests for GetSettings -func NewGetSettingsRequest(server string) (*http.Request, error) { +// NewListFiltersRequest generates requests for ListFilters +func NewListFiltersRequest(server string, params *ListFiltersParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12177,7 +10595,7 @@ func NewGetSettingsRequest(server string) (*http.Request, error) { return nil, err } - operationPath := fmt.Sprintf("/manage/settings") + operationPath := fmt.Sprintf("/filters") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12187,56 +10605,102 @@ func NewGetSettingsRequest(server string) (*http.Request, error) { return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} + if params.PerPage != nil { -// NewUpdateSettingsRequest calls the generic UpdateSettings builder with application/json body -func NewUpdateSettingsRequest(server string, body UpdateSettingsJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSettingsRequestWithBody(server, "application/json", bodyReader) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUpdateSettingsRequestWithBody generates requests for UpdateSettings with any type of body -func NewUpdateSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.Page != nil { - operationPath := fmt.Sprintf("/manage/settings") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + } + + if params.FilterTags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.NameFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ExpressionFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "expression_filter", runtime.ParamLocationQuery, *params.ExpressionFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewManageListAllTeamsRequest generates requests for ManageListAllTeams -func NewManageListAllTeamsRequest(server string, params *ManageListAllTeamsParams) (*http.Request, error) { +// NewListFilterTagsRequest generates requests for ListFilterTags +func NewListFilterTagsRequest(server string, params *ListFilterTagsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12244,7 +10708,7 @@ func NewManageListAllTeamsRequest(server string, params *ManageListAllTeamsParam return nil, err } - operationPath := fmt.Sprintf("/manage/teams") + operationPath := fmt.Sprintf("/filters/tags") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12300,13 +10764,13 @@ func NewManageListAllTeamsRequest(server string, params *ManageListAllTeamsParam return req, nil } -// NewManageDeleteTeamRequest generates requests for ManageDeleteTeam -func NewManageDeleteTeamRequest(server string, teamName TeamName) (*http.Request, error) { +// NewDeleteFilterRequest generates requests for DeleteFilter +func NewDeleteFilterRequest(server string, filterID FilterID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) if err != nil { return nil, err } @@ -12316,7 +10780,7 @@ func NewManageDeleteTeamRequest(server string, teamName TeamName) (*http.Request return nil, err } - operationPath := fmt.Sprintf("/manage/teams/%s", pathParam0) + operationPath := fmt.Sprintf("/filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12334,13 +10798,13 @@ func NewManageDeleteTeamRequest(server string, teamName TeamName) (*http.Request return req, nil } -// NewManageGetTeamRequest generates requests for ManageGetTeam -func NewManageGetTeamRequest(server string, teamName TeamName) (*http.Request, error) { +// NewGetFilterByIDRequest generates requests for GetFilterByID +func NewGetFilterByIDRequest(server string, filterID FilterID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) if err != nil { return nil, err } @@ -12350,7 +10814,7 @@ func NewManageGetTeamRequest(server string, teamName TeamName) (*http.Request, e return nil, err } - operationPath := fmt.Sprintf("/manage/teams/%s", pathParam0) + operationPath := fmt.Sprintf("/filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12368,24 +10832,24 @@ func NewManageGetTeamRequest(server string, teamName TeamName) (*http.Request, e return req, nil } -// NewManageRemoveTeamMemberRequest calls the generic ManageRemoveTeamMember builder with application/json body -func NewManageRemoveTeamMemberRequest(server string, teamName TeamName, body ManageRemoveTeamMemberJSONRequestBody) (*http.Request, error) { +// NewUpdateFilterRequest calls the generic UpdateFilter builder with application/json body +func NewUpdateFilterRequest(server string, filterID FilterID, body UpdateFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewManageRemoveTeamMemberRequestWithBody(server, teamName, "application/json", bodyReader) + return NewUpdateFilterRequestWithBody(server, filterID, "application/json", bodyReader) } -// NewManageRemoveTeamMemberRequestWithBody generates requests for ManageRemoveTeamMember with any type of body -func NewManageRemoveTeamMemberRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateFilterRequestWithBody generates requests for UpdateFilter with any type of body +func NewUpdateFilterRequestWithBody(server string, filterID FilterID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) if err != nil { return nil, err } @@ -12395,7 +10859,7 @@ func NewManageRemoveTeamMemberRequestWithBody(server string, teamName TeamName, return nil, err } - operationPath := fmt.Sprintf("/manage/teams/%s/members", pathParam0) + operationPath := fmt.Sprintf("/filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12405,7 +10869,7 @@ func NewManageRemoveTeamMemberRequestWithBody(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -12415,23 +10879,70 @@ func NewManageRemoveTeamMemberRequestWithBody(server string, teamName TeamName, return req, nil } -// NewManageListTeamMembersRequest generates requests for ManageListTeamMembers -func NewManageListTeamMembersRequest(server string, teamName TeamName, params *ManageListTeamMembersParams) (*http.Request, error) { +// NewHealthCheckRequest generates requests for HealthCheck +func NewHealthCheckRequest(server string) (*http.Request, error) { var err error - var pathParam0 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + operationPath := fmt.Sprintf("/healthcheck") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewHealthCheckHeadRequest generates requests for HealthCheckHead +func NewHealthCheckHeadRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/healthcheck") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("HEAD", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewListNotificationsRequest generates requests for ListNotifications +func NewListNotificationsRequest(server string, params *ListNotificationsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/manage/teams/%s/members", pathParam0) + operationPath := fmt.Sprintf("/notifications") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12444,6 +10955,22 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M if params != nil { queryValues := queryURL.Query() + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + if params.Page != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { @@ -12460,9 +10987,9 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M } - if params.PerPage != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12476,9 +11003,9 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M } - if params.UserSearch != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "user_search", runtime.ParamLocationQuery, *params.UserSearch); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12492,9 +11019,164 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M } - if params.Role != nil { + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewDeleteNotificationDestinationRequest generates requests for DeleteNotificationDestination +func NewDeleteNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetNotificationDestinationRequest generates requests for GetNotificationDestination +func NewGetNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateNotificationDestinationRequest calls the generic UpdateNotificationDestination builder with application/json body +func NewUpdateNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateNotificationDestinationRequestWithBody(server, notificationDestinationId, "application/json", bodyReader) +} + +// NewUpdateNotificationDestinationRequestWithBody generates requests for UpdateNotificationDestination with any type of body +func NewUpdateNotificationDestinationRequestWithBody(server string, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetNotificationDestinationAlertsRequest generates requests for GetNotificationDestinationAlerts +func NewGetNotificationDestinationAlertsRequest(server string, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destination/%s/alerts", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "role", runtime.ParamLocationQuery, *params.Role); err != nil { + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12508,9 +11190,9 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M } - if params.CustomRoleId != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "custom_role_id", runtime.ParamLocationQuery, *params.CustomRoleId); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12535,24 +11217,13 @@ func NewManageListTeamMembersRequest(server string, teamName TeamName, params *M return req, nil } -// NewManageAddTeamMemberRequest calls the generic ManageAddTeamMember builder with application/json body -func NewManageAddTeamMemberRequest(server string, teamName TeamName, body ManageAddTeamMemberJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewManageAddTeamMemberRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewManageAddTeamMemberRequestWithBody generates requests for ManageAddTeamMember with any type of body -func NewManageAddTeamMemberRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewTestNotificationDestinationRequest generates requests for TestNotificationDestination +func NewTestNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } @@ -12562,7 +11233,7 @@ func NewManageAddTeamMemberRequestWithBody(server string, teamName TeamName, con return nil, err } - operationPath := fmt.Sprintf("/manage/teams/%s/members", pathParam0) + operationPath := fmt.Sprintf("/notifications/destination/%s/test", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12572,18 +11243,16 @@ func NewManageAddTeamMemberRequestWithBody(server string, teamName TeamName, con return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListLocalUsersRequest generates requests for ListLocalUsers -func NewListLocalUsersRequest(server string, params *ListLocalUsersParams) (*http.Request, error) { +// NewListAllNotificationDestinationsRequest generates requests for ListAllNotificationDestinations +func NewListAllNotificationDestinationsRequest(server string, params *ListAllNotificationDestinationsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12591,7 +11260,7 @@ func NewListLocalUsersRequest(server string, params *ListLocalUsersParams) (*htt return nil, err } - operationPath := fmt.Sprintf("/manage/users") + operationPath := fmt.Sprintf("/notifications/destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12647,19 +11316,99 @@ func NewListLocalUsersRequest(server string, params *ListLocalUsersParams) (*htt return req, nil } -// NewAddLocalUserRequest calls the generic AddLocalUser builder with application/json body -func NewAddLocalUserRequest(server string, body AddLocalUserJSONRequestBody) (*http.Request, error) { +// NewCreateNotificationDestinationRequest calls the generic CreateNotificationDestination builder with application/json body +func NewCreateNotificationDestinationRequest(server string, body CreateNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateNotificationDestinationRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateNotificationDestinationRequestWithBody generates requests for CreateNotificationDestination with any type of body +func NewCreateNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destinations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewTestUnsavedNotificationDestinationRequest calls the generic TestUnsavedNotificationDestination builder with application/json body +func NewTestUnsavedNotificationDestinationRequest(server string, body TestUnsavedNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewTestUnsavedNotificationDestinationRequestWithBody(server, "application/json", bodyReader) +} + +// NewTestUnsavedNotificationDestinationRequestWithBody generates requests for TestUnsavedNotificationDestination with any type of body +func NewTestUnsavedNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/notifications/destinations/test") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewCreateAWSOnboardingRequest calls the generic CreateAWSOnboarding builder with application/json body +func NewCreateAWSOnboardingRequest(server string, body CreateAWSOnboardingJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewAddLocalUserRequestWithBody(server, "application/json", bodyReader) + return NewCreateAWSOnboardingRequestWithBody(server, "application/json", bodyReader) } -// NewAddLocalUserRequestWithBody generates requests for AddLocalUser with any type of body -func NewAddLocalUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateAWSOnboardingRequestWithBody generates requests for CreateAWSOnboarding with any type of body +func NewCreateAWSOnboardingRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12667,7 +11416,7 @@ func NewAddLocalUserRequestWithBody(server string, contentType string, body io.R return nil, err } - operationPath := fmt.Sprintf("/manage/users/add") + operationPath := fmt.Sprintf("/onboardings/aws/oidc") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12687,13 +11436,13 @@ func NewAddLocalUserRequestWithBody(server string, contentType string, body io.R return req, nil } -// NewDeleteLocalUserRequest generates requests for DeleteLocalUser -func NewDeleteLocalUserRequest(server string, userID UserID) (*http.Request, error) { +// NewGetAWSOnboardingRequest generates requests for GetAWSOnboarding +func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12703,7 +11452,7 @@ func NewDeleteLocalUserRequest(server string, userID UserID) (*http.Request, err return nil, err } - operationPath := fmt.Sprintf("/manage/users/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12713,7 +11462,7 @@ func NewDeleteLocalUserRequest(server string, userID UserID) (*http.Request, err return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -12721,13 +11470,13 @@ func NewDeleteLocalUserRequest(server string, userID UserID) (*http.Request, err return req, nil } -// NewGetLocalUserRequest generates requests for GetLocalUser -func NewGetLocalUserRequest(server string, userID UserID) (*http.Request, error) { +// NewGetAWSAccountsInRootRequest generates requests for GetAWSAccountsInRoot +func NewGetAWSAccountsInRootRequest(server string, onboardingID OnboardingID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12737,7 +11486,7 @@ func NewGetLocalUserRequest(server string, userID UserID) (*http.Request, error) return nil, err } - operationPath := fmt.Sprintf("/manage/users/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12755,24 +11504,24 @@ func NewGetLocalUserRequest(server string, userID UserID) (*http.Request, error) return req, nil } -// NewUpdateLocalUserRequest calls the generic UpdateLocalUser builder with application/json body -func NewUpdateLocalUserRequest(server string, userID UserID, body UpdateLocalUserJSONRequestBody) (*http.Request, error) { +// NewProvisionOnboardingConfigurationRequest calls the generic ProvisionOnboardingConfiguration builder with application/json body +func NewProvisionOnboardingConfigurationRequest(server string, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateLocalUserRequestWithBody(server, userID, "application/json", bodyReader) + return NewProvisionOnboardingConfigurationRequestWithBody(server, onboardingID, "application/json", bodyReader) } -// NewUpdateLocalUserRequestWithBody generates requests for UpdateLocalUser with any type of body -func NewUpdateLocalUserRequestWithBody(server string, userID UserID, contentType string, body io.Reader) (*http.Request, error) { +// NewProvisionOnboardingConfigurationRequestWithBody generates requests for ProvisionOnboardingConfiguration with any type of body +func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12782,7 +11531,7 @@ func NewUpdateLocalUserRequestWithBody(server string, userID UserID, contentType return nil, err } - operationPath := fmt.Sprintf("/manage/users/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/provision", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12792,7 +11541,7 @@ func NewUpdateLocalUserRequestWithBody(server string, userID UserID, contentType return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -12802,13 +11551,20 @@ func NewUpdateLocalUserRequestWithBody(server string, userID UserID, contentType return req, nil } -// NewCreateLocalUserResetTokenRequest generates requests for CreateLocalUserResetToken -func NewCreateLocalUserResetTokenRequest(server string, userID UserID) (*http.Request, error) { +// NewGetAWSAccountsInParentRequest generates requests for GetAWSAccountsInParent +func NewGetAWSAccountsInParentRequest(server string, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "aws_orgunit_id", runtime.ParamLocationPath, organizationalUnitID) if err != nil { return nil, err } @@ -12818,7 +11574,7 @@ func NewCreateLocalUserResetTokenRequest(server string, userID UserID) (*http.Re return nil, err } - operationPath := fmt.Sprintf("/manage/users/%s/reset", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12828,7 +11584,7 @@ func NewCreateLocalUserResetTokenRequest(server string, userID UserID) (*http.Re return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -12836,13 +11592,24 @@ func NewCreateLocalUserResetTokenRequest(server string, userID UserID) (*http.Re return req, nil } -// NewManageUserTOTPDeleteRequest generates requests for ManageUserTOTPDelete -func NewManageUserTOTPDeleteRequest(server string, userID UserID) (*http.Request, error) { +// NewNotifyOnboardingRequest calls the generic NotifyOnboarding builder with application/json body +func NewNotifyOnboardingRequest(server string, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewNotifyOnboardingRequestWithBody(server, onboardingID, "application/json", bodyReader) +} + +// NewNotifyOnboardingRequestWithBody generates requests for NotifyOnboarding with any type of body +func NewNotifyOnboardingRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12852,7 +11619,7 @@ func NewManageUserTOTPDeleteRequest(server string, userID UserID) (*http.Request return nil, err } - operationPath := fmt.Sprintf("/manage/users/%s/totp", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/notify", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12862,11 +11629,13 @@ func NewManageUserTOTPDeleteRequest(server string, userID UserID) (*http.Request return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } @@ -13102,48 +11871,8 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ return req, nil } -// NewCreatePluginRequest calls the generic CreatePlugin builder with application/json body -func NewCreatePluginRequest(server string, body CreatePluginJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreatePluginRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreatePluginRequestWithBody generates requests for CreatePlugin with any type of body -func NewCreatePluginRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeletePluginByTeamAndPluginNameRequest generates requests for DeletePluginByTeamAndPluginName -func NewDeletePluginByTeamAndPluginNameRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName) (*http.Request, error) { +// NewGetPluginRequest generates requests for GetPlugin +func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName) (*http.Request, error) { var err error var pathParam0 string @@ -13182,7 +11911,7 @@ func NewDeletePluginByTeamAndPluginNameRequest(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -13190,8 +11919,8 @@ func NewDeletePluginByTeamAndPluginNameRequest(server string, teamName TeamName, return req, nil } -// NewGetPluginRequest generates requests for GetPlugin -func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName) (*http.Request, error) { +// NewListPluginVersionsRequest generates requests for ListPluginVersions +func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams) (*http.Request, error) { var err error var pathParam0 string @@ -13220,7 +11949,7 @@ func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions", pathParam0, pathParam1, pathParam2) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13230,119 +11959,10 @@ func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} - -// NewUpdatePluginRequest calls the generic UpdatePlugin builder with application/json body -func NewUpdatePluginRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, body UpdatePluginJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdatePluginRequestWithBody(server, teamName, pluginKind, pluginName, "application/json", bodyReader) -} - -// NewUpdatePluginRequestWithBody generates requests for UpdatePlugin with any type of body -func NewUpdatePluginRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins/%s/%s/%s", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListPluginVersionsRequest generates requests for ListPluginVersions -func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.SortBy != nil { + if params.SortBy != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { return nil, err @@ -13520,19 +12140,8 @@ func NewGetPluginVersionRequest(server string, teamName TeamName, pluginKind Plu return req, nil } -// NewUpdatePluginVersionRequest calls the generic UpdatePluginVersion builder with application/json body -func NewUpdatePluginVersionRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UpdatePluginVersionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdatePluginVersionRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} - -// NewUpdatePluginVersionRequestWithBody generates requests for UpdatePluginVersion with any type of body -func NewUpdatePluginVersionRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewDownloadPluginAssetRequest generates requests for DownloadPluginAsset +func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams) (*http.Request, error) { var err error var pathParam0 string @@ -13563,12 +12172,19 @@ func NewUpdatePluginVersionRequestWithBody(server string, teamName TeamName, plu return nil, err } + var pathParam4 string + + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13578,29 +12194,31 @@ func NewUpdatePluginVersionRequestWithBody(server string, teamName TeamName, plu return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) + if params != nil { - return req, nil -} + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } -// NewCreatePluginVersionRequest calls the generic CreatePluginVersion builder with application/json body -func NewCreatePluginVersionRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreatePluginVersionRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) + + return req, nil } -// NewCreatePluginVersionRequestWithBody generates requests for CreatePluginVersion with any type of body -func NewCreatePluginVersionRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewListPluginVersionTablesRequest generates requests for ListPluginVersionTables +func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams) (*http.Request, error) { var err error var pathParam0 string @@ -13636,7 +12254,7 @@ func NewCreatePluginVersionRequestWithBody(server string, teamName TeamName, plu return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13646,18 +12264,54 @@ func NewCreatePluginVersionRequestWithBody(server string, teamName TeamName, plu return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewDownloadPluginAssetRequest generates requests for DownloadPluginAsset -func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams) (*http.Request, error) { +// NewGetPluginVersionTableRequest generates requests for GetPluginVersionTable +func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string) (*http.Request, error) { var err error var pathParam0 string @@ -13690,7 +12344,7 @@ func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind var pathParam4 string - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -13700,7 +12354,7 @@ func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13715,79 +12369,179 @@ func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind return nil, err } + return req, nil +} + +// NewListPoliciesRequest generates requests for ListPolicies +func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + if params != nil { + queryValues := queryURL.Query() - if params.Accept != nil { - var headerParam0 string + if params.PerPage != nil { - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } } - req.Header.Set("Accept", headerParam0) } - } + if params.Page != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUploadPluginAssetRequest generates requests for UploadPluginAsset -func NewUploadPluginAssetRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.PolicyStatus != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "status", runtime.ParamLocationQuery, *params.PolicyStatus); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam1 string + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } + if params.Severities != nil { - var pathParam2 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } + } - var pathParam3 string + if params.Domain != nil { - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam4 string + } - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) - if err != nil { - return nil, err - } + if params.PolicyGroupIds != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortBy != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDir != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -13795,55 +12549,56 @@ func NewUploadPluginAssetRequest(server string, teamName TeamName, pluginKind Pl return req, nil } -// NewDeletePluginVersionDocsRequest calls the generic DeletePluginVersionDocs builder with application/json body -func NewDeletePluginVersionDocsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionDocsJSONRequestBody) (*http.Request, error) { +// NewCreatePolicyRequest calls the generic CreatePolicy builder with application/json body +func NewCreatePolicyRequest(server string, body CreatePolicyJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewDeletePluginVersionDocsRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) + return NewCreatePolicyRequestWithBody(server, "application/json", bodyReader) } -// NewDeletePluginVersionDocsRequestWithBody generates requests for DeletePluginVersionDocs with any type of body -func NewDeletePluginVersionDocsRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewCreatePolicyRequestWithBody generates requests for CreatePolicy with any type of body +func NewCreatePolicyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam1 string + operationPath := fmt.Sprintf("/policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - var pathParam3 string + req.Header.Add("Content-Type", contentType) - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } + return req, nil +} + +// NewGetPolicyMetricsRequest generates requests for GetPolicyMetrics +func NewGetPolicyMetricsRequest(server string, params *GetPolicyMetricsParams) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/docs", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/metrics") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13853,54 +12608,78 @@ func NewDeletePluginVersionDocsRequestWithBody(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.Severities != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListPluginVersionDocsRequest generates requests for ListPluginVersionDocs -func NewListPluginVersionDocsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionDocsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.Domain != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam1 string + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } + if params.PolicyGroupIds != nil { - var pathParam2 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } + } - var pathParam3 string + queryURL.RawQuery = queryValues.Encode() + } - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewGetViolationsByDomainRequest generates requests for GetViolationsByDomain +func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomainParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/docs", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/violations-by-domain") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13913,9 +12692,9 @@ func NewListPluginVersionDocsRequest(server string, teamName TeamName, pluginKin if params != nil { queryValues := queryURL.Query() - if params.Page != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13929,9 +12708,25 @@ func NewListPluginVersionDocsRequest(server string, teamName TeamName, pluginKin } - if params.PerPage != nil { + if params.Domain != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PolicyGroupIds != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13956,181 +12751,126 @@ func NewListPluginVersionDocsRequest(server string, teamName TeamName, pluginKin return req, nil } -// NewReplacePluginVersionDocsRequest calls the generic ReplacePluginVersionDocs builder with application/json body -func NewReplacePluginVersionDocsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body ReplacePluginVersionDocsJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewReplacePluginVersionDocsRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} - -// NewReplacePluginVersionDocsRequestWithBody generates requests for ReplacePluginVersionDocs with any type of body -func NewReplacePluginVersionDocsRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewGetViolationsHistoryRequest generates requests for GetViolationsHistory +func NewGetViolationsHistoryRequest(server string, params *GetViolationsHistoryParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err + operationPath := fmt.Sprintf("/policies/violations-history") + if operationPath[0] == '/' { + operationPath = "." + operationPath } - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam3 string + if params != nil { + queryValues := queryURL.Query() - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/docs", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params.StartDate != nil { - req.Header.Add("Content-Type", contentType) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_date", runtime.ParamLocationQuery, *params.StartDate); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - return req, nil -} + } -// NewCreatePluginVersionDocsRequest calls the generic CreatePluginVersionDocs builder with application/json body -func NewCreatePluginVersionDocsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionDocsJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreatePluginVersionDocsRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} + if params.EndDate != nil { -// NewCreatePluginVersionDocsRequestWithBody generates requests for CreatePluginVersionDocs with any type of body -func NewCreatePluginVersionDocsRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { - var err error + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_date", runtime.ParamLocationQuery, *params.EndDate); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam0 string + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if params.Severities != nil { - var pathParam1 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } + } - var pathParam2 string + if params.Domain != nil { - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam3 string + } - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } + if params.PolicyGroupIds != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/docs", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewDeletePluginVersionTablesRequest calls the generic DeletePluginVersionTables builder with application/json body -func NewDeletePluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionTablesJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewDeletePluginVersionTablesRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} - -// NewDeletePluginVersionTablesRequestWithBody generates requests for DeletePluginVersionTables with any type of body -func NewDeletePluginVersionTablesRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewDeletePolicyRequest generates requests for DeletePolicy +func NewDeletePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14140,7 +12880,7 @@ func NewDeletePluginVersionTablesRequestWithBody(server string, teamName TeamNam return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14150,44 +12890,21 @@ func NewDeletePluginVersionTablesRequestWithBody(server string, teamName TeamNam return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListPluginVersionTablesRequest generates requests for ListPluginVersionTables -func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams) (*http.Request, error) { +// NewGetPolicyRequest generates requests for GetPolicy +func NewGetPolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14197,7 +12914,7 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14207,44 +12924,6 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -14253,45 +12932,24 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK return req, nil } -// NewCreatePluginVersionTablesRequest calls the generic CreatePluginVersionTables builder with application/json body -func NewCreatePluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionTablesJSONRequestBody) (*http.Request, error) { +// NewUpdatePolicyRequest calls the generic UpdatePolicy builder with application/json body +func NewUpdatePolicyRequest(server string, policyID PolicyID, body UpdatePolicyJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreatePluginVersionTablesRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) + return NewUpdatePolicyRequestWithBody(server, policyID, "application/json", bodyReader) } -// NewCreatePluginVersionTablesRequestWithBody generates requests for CreatePluginVersionTables with any type of body -func NewCreatePluginVersionTablesRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdatePolicyRequestWithBody generates requests for UpdatePolicy with any type of body +func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14301,7 +12959,7 @@ func NewCreatePluginVersionTablesRequestWithBody(server string, teamName TeamNam return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14321,41 +12979,13 @@ func NewCreatePluginVersionTablesRequestWithBody(server string, teamName TeamNam return req, nil } -// NewGetPluginVersionTableRequest generates requests for GetPluginVersionTable -func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string) (*http.Request, error) { +// NewTogglePolicyRequest generates requests for TogglePolicy +func NewTogglePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } - - var pathParam4 string - - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14365,7 +12995,7 @@ func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKin return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) + operationPath := fmt.Sprintf("/policies/%s/toggle", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14375,7 +13005,7 @@ func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKin return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -14383,34 +13013,13 @@ func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKin return req, nil } -// NewRemovePluginUIAssetsRequest generates requests for RemovePluginUIAssets -func NewRemovePluginUIAssetsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName) (*http.Request, error) { +// NewGetPolicyViolationsRequest generates requests for GetPolicyViolations +func NewGetPolicyViolationsRequest(server string, policyID PolicyID, params *GetPolicyViolationsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14420,7 +13029,7 @@ func NewRemovePluginUIAssetsRequest(server string, teamName TeamName, pluginKind return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/uiassets", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/policies/%s/violations", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14430,160 +13039,85 @@ func NewRemovePluginUIAssetsRequest(server string, teamName TeamName, pluginKind return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUploadPluginUIAssetsRequest calls the generic UploadPluginUIAssets builder with application/json body -func NewUploadPluginUIAssetsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UploadPluginUIAssetsJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUploadPluginUIAssetsRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} - -// NewUploadPluginUIAssetsRequestWithBody generates requests for UploadPluginUIAssets with any type of body -func NewUploadPluginUIAssetsRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string + if params != nil { + queryValues := queryURL.Query() - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if params.Page != nil { - var pathParam1 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } + } - var pathParam2 string + if params.PerPage != nil { - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam3 string + } - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } + if params.Search != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/uiassets", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewFinalizePluginUIAssetUploadRequest calls the generic FinalizePluginUIAssetUpload builder with application/json body -func NewFinalizePluginUIAssetUploadRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body FinalizePluginUIAssetUploadJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewFinalizePluginUIAssetUploadRequestWithBody(server, teamName, pluginKind, pluginName, versionName, "application/json", bodyReader) -} - -// NewFinalizePluginUIAssetUploadRequestWithBody generates requests for FinalizePluginUIAssetUpload with any type of body -func NewFinalizePluginUIAssetUploadRequestWithBody(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader) (*http.Request, error) { +// NewGetPolicyViolationsHistoryRequest generates requests for GetPolicyViolationsHistory +func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, params *GetPolicyViolationsHistoryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/uiassets", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PUT", queryURL.String(), body) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewAuthRegistryRequestRequest generates requests for AuthRegistryRequest -func NewAuthRegistryRequestRequest(server string, params *AuthRegistryRequestParams) (*http.Request, error) { - var err error - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/registry/auth") + operationPath := fmt.Sprintf("/policies/%s/violations-history", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14596,9 +13130,9 @@ func NewAuthRegistryRequestRequest(server string, params *AuthRegistryRequestPar if params != nil { queryValues := queryURL.Query() - if params.Account != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "account", runtime.ParamLocationQuery, *params.Account); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14612,9 +13146,9 @@ func NewAuthRegistryRequestRequest(server string, params *AuthRegistryRequestPar } - if params.Service != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "service", runtime.ParamLocationQuery, *params.Service); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14628,9 +13162,9 @@ func NewAuthRegistryRequestRequest(server string, params *AuthRegistryRequestPar } - if params.Scope != nil { + if params.StartTime != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "scope", runtime.ParamLocationQuery, *params.Scope); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_time", runtime.ParamLocationQuery, *params.StartTime); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14644,45 +13178,35 @@ func NewAuthRegistryRequestRequest(server string, params *AuthRegistryRequestPar } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - if params != nil { - - if params.XMetaPluginVersion != nil { - var headerParam0 string + if params.EndTime != nil { - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "X-Meta-Plugin-Version", runtime.ParamLocationHeader, *params.XMetaPluginVersion) - if err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_time", runtime.ParamLocationQuery, *params.EndTime); err != nil { return nil, err - } - - req.Header.Set("X-Meta-Plugin-Version", headerParam0) - } - - if params.XMetaUserTeamName != nil { - var headerParam1 string - - headerParam1, err = runtime.StyleParamWithLocation("simple", false, "X-Meta-User-Team-Name", runtime.ParamLocationHeader, *params.XMetaUserTeamName) - if err != nil { + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } } - req.Header.Set("X-Meta-User-Team-Name", headerParam1) } + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err } return req, nil } -// NewListTeamsRequest generates requests for ListTeams -func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, error) { +// NewListPolicyGroupsRequest generates requests for ListPolicyGroups +func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -14690,7 +13214,7 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, return nil, err } - operationPath := fmt.Sprintf("/teams") + operationPath := fmt.Sprintf("/policy-groups") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14703,9 +13227,9 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14719,9 +13243,9 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, } - if params.Page != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14746,19 +13270,19 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, return req, nil } -// NewCreateTeamRequest calls the generic CreateTeam builder with application/json body -func NewCreateTeamRequest(server string, body CreateTeamJSONRequestBody) (*http.Request, error) { +// NewCreatePolicyGroupRequest calls the generic CreatePolicyGroup builder with application/json body +func NewCreatePolicyGroupRequest(server string, body CreatePolicyGroupJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateTeamRequestWithBody(server, "application/json", bodyReader) + return NewCreatePolicyGroupRequestWithBody(server, "application/json", bodyReader) } -// NewCreateTeamRequestWithBody generates requests for CreateTeam with any type of body -func NewCreateTeamRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewCreatePolicyGroupRequestWithBody generates requests for CreatePolicyGroup with any type of body +func NewCreatePolicyGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -14766,7 +13290,7 @@ func NewCreateTeamRequestWithBody(server string, contentType string, body io.Rea return nil, err } - operationPath := fmt.Sprintf("/teams") + operationPath := fmt.Sprintf("/policy-groups") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14786,13 +13310,13 @@ func NewCreateTeamRequestWithBody(server string, contentType string, body io.Rea return req, nil } -// NewDeleteTeamRequest generates requests for DeleteTeam -func NewDeleteTeamRequest(server string, teamName TeamName) (*http.Request, error) { +// NewDeletePolicyGroupRequest generates requests for DeletePolicyGroup +func NewDeletePolicyGroupRequest(server string, policyGroupID PolicyGroupID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) if err != nil { return nil, err } @@ -14802,7 +13326,7 @@ func NewDeleteTeamRequest(server string, teamName TeamName) (*http.Request, erro return nil, err } - operationPath := fmt.Sprintf("/teams/%s", pathParam0) + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14820,13 +13344,13 @@ func NewDeleteTeamRequest(server string, teamName TeamName) (*http.Request, erro return req, nil } -// NewGetTeamByNameRequest generates requests for GetTeamByName -func NewGetTeamByNameRequest(server string, teamName TeamName) (*http.Request, error) { +// NewListPoliciesInGroupRequest generates requests for ListPoliciesInGroup +func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) if err != nil { return nil, err } @@ -14836,7 +13360,7 @@ func NewGetTeamByNameRequest(server string, teamName TeamName) (*http.Request, e return nil, err } - operationPath := fmt.Sprintf("/teams/%s", pathParam0) + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14846,32 +13370,102 @@ func NewGetTeamByNameRequest(server string, teamName TeamName) (*http.Request, e return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortBy != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDir != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } return req, nil } -// NewUpdateTeamRequest calls the generic UpdateTeam builder with application/json body -func NewUpdateTeamRequest(server string, teamName TeamName, body UpdateTeamJSONRequestBody) (*http.Request, error) { +// NewUpdatePolicyGroupRequest calls the generic UpdatePolicyGroup builder with application/json body +func NewUpdatePolicyGroupRequest(server string, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateTeamRequestWithBody(server, teamName, "application/json", bodyReader) + return NewUpdatePolicyGroupRequestWithBody(server, policyGroupID, "application/json", bodyReader) } -// NewUpdateTeamRequestWithBody generates requests for UpdateTeam with any type of body -func NewUpdateTeamRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdatePolicyGroupRequestWithBody generates requests for UpdatePolicyGroup with any type of body +func NewUpdatePolicyGroupRequestWithBody(server string, policyGroupID PolicyGroupID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) if err != nil { return nil, err } @@ -14881,7 +13475,7 @@ func NewUpdateTeamRequestWithBody(server string, teamName TeamName, contentType return nil, err } - operationPath := fmt.Sprintf("/teams/%s", pathParam0) + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14891,7 +13485,7 @@ func NewUpdateTeamRequestWithBody(server string, teamName TeamName, contentType return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } @@ -14901,23 +13495,16 @@ func NewUpdateTeamRequestWithBody(server string, teamName TeamName, contentType return req, nil } -// NewListAllAlertsRequest generates requests for ListAllAlerts -func NewListAllAlertsRequest(server string, teamName TeamName, params *ListAllAlertsParams) (*http.Request, error) { +// NewListAllQueriesRequest generates requests for ListAllQueries +func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/alerts", pathParam0) + operationPath := fmt.Sprintf("/queries") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14962,9 +13549,9 @@ func NewListAllAlertsRequest(server string, teamName TeamName, params *ListAllAl } - if params.AlertStates != nil { + if params.QueryTags != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "state", runtime.ParamLocationQuery, params.AlertStates); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.QueryTags); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14978,9 +13565,9 @@ func NewListAllAlertsRequest(server string, teamName TeamName, params *ListAllAl } - if params.Enabled != nil { + if params.NameFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "enabled", runtime.ParamLocationQuery, *params.Enabled); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14994,60 +13581,9 @@ func NewListAllAlertsRequest(server string, teamName TeamName, params *ListAllAl } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTestUnsavedAlertRequest calls the generic TestUnsavedAlert builder with application/json body -func NewTestUnsavedAlertRequest(server string, teamName TeamName, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewTestUnsavedAlertRequestWithBody(server, teamName, params, "application/json", bodyReader) -} - -// NewTestUnsavedAlertRequestWithBody generates requests for TestUnsavedAlert with any type of body -func NewTestUnsavedAlertRequestWithBody(server string, teamName TeamName, params *TestUnsavedAlertParams, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/alerts/test", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.QueryID != nil { + if params.QueryFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_id", runtime.ParamLocationQuery, *params.QueryID); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_filter", runtime.ParamLocationQuery, *params.QueryFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15061,51 +13597,25 @@ func NewTestUnsavedAlertRequestWithBody(server string, teamName TeamName, params } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListTeamAPIKeysRequest generates requests for ListTeamAPIKeys -func NewListTeamAPIKeysRequest(server string, teamName TeamName, params *ListTeamAPIKeysParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/apikeys", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.AlertConfigured != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_configured", runtime.ParamLocationQuery, *params.AlertConfigured); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.PerPage != nil { + if params.AlertMessageFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_message_filter", runtime.ParamLocationQuery, *params.AlertMessageFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15119,9 +13629,9 @@ func NewListTeamAPIKeysRequest(server string, teamName TeamName, params *ListTea } - if params.Page != nil { + if params.AlertEnabled != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_enabled", runtime.ParamLocationQuery, *params.AlertEnabled); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15146,34 +13656,27 @@ func NewListTeamAPIKeysRequest(server string, teamName TeamName, params *ListTea return req, nil } -// NewCreateTeamAPIKeyRequest calls the generic CreateTeamAPIKey builder with application/json body -func NewCreateTeamAPIKeyRequest(server string, teamName TeamName, body CreateTeamAPIKeyJSONRequestBody) (*http.Request, error) { +// NewExecuteAdHocQueryRequest calls the generic ExecuteAdHocQuery builder with application/json body +func NewExecuteAdHocQueryRequest(server string, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateTeamAPIKeyRequestWithBody(server, teamName, "application/json", bodyReader) + return NewExecuteAdHocQueryRequestWithBody(server, params, "application/json", bodyReader) } -// NewCreateTeamAPIKeyRequestWithBody generates requests for CreateTeamAPIKey with any type of body -func NewCreateTeamAPIKeyRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewExecuteAdHocQueryRequestWithBody generates requests for ExecuteAdHocQuery with any type of body +func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQueryParams, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/apikeys", pathParam0) + operationPath := fmt.Sprintf("/queries/execute") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15183,89 +13686,92 @@ func NewCreateTeamAPIKeyRequestWithBody(server string, teamName TeamName, conten return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteTeamAPIKeyRequest generates requests for DeleteTeamAPIKey -func NewDeleteTeamAPIKeyRequest(server string, teamName TeamName, apiKeyID APIKeyID) (*http.Request, error) { - var err error - - var pathParam0 string + if params != nil { + queryValues := queryURL.Query() - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if params.Selects != nil { - var pathParam1 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "apikey_id", runtime.ParamLocationPath, apiKeyID) - if err != nil { - return nil, err - } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.FilterMode != nil { - operationPath := fmt.Sprintf("/teams/%s/apikeys/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params.Filters != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListConnectorsRequest generates requests for ListConnectors -func NewListConnectorsRequest(server string, teamName TeamName, params *ListConnectorsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.FilterIDs != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/teams/%s/connectors", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.SortBys != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.PerPage != nil { + if params.SortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15279,9 +13785,9 @@ func NewListConnectorsRequest(server string, teamName TeamName, params *ListConn } - if params.Page != nil { + if params.GroupBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15295,9 +13801,9 @@ func NewListConnectorsRequest(server string, teamName TeamName, params *ListConn } - if params.FilterType != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_type", runtime.ParamLocationQuery, *params.FilterType); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15311,9 +13817,9 @@ func NewListConnectorsRequest(server string, teamName TeamName, params *ListConn } - if params.FilterPlugin != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_plugin", runtime.ParamLocationQuery, *params.FilterPlugin); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15330,42 +13836,37 @@ func NewListConnectorsRequest(server string, teamName TeamName, params *ListConn queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewCreateConnectorRequest calls the generic CreateConnector builder with application/json body -func NewCreateConnectorRequest(server string, teamName TeamName, body CreateConnectorJSONRequestBody) (*http.Request, error) { +// NewSaveQueryRequest calls the generic SaveQuery builder with application/json body +func NewSaveQueryRequest(server string, body SaveQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateConnectorRequestWithBody(server, teamName, "application/json", bodyReader) + return NewSaveQueryRequestWithBody(server, "application/json", bodyReader) } -// NewCreateConnectorRequestWithBody generates requests for CreateConnector with any type of body -func NewCreateConnectorRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewSaveQueryRequestWithBody generates requests for SaveQuery with any type of body +func NewSaveQueryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors", pathParam0) + operationPath := fmt.Sprintf("/queries/save") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15385,30 +13886,16 @@ func NewCreateConnectorRequestWithBody(server string, teamName TeamName, content return req, nil } -// NewGetConnectorRequest generates requests for GetConnector -func NewGetConnectorRequest(server string, teamName TeamName, connectorID ConnectorID) (*http.Request, error) { +// NewListQueryTagsRequest generates requests for ListQueryTags +func NewListQueryTagsRequest(server string, params *ListQueryTagsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/tags") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15418,82 +13905,59 @@ func NewGetConnectorRequest(server string, teamName TeamName, connectorID Connec return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdateConnectorRequest calls the generic UpdateConnector builder with application/json body -func NewUpdateConnectorRequest(server string, teamName TeamName, connectorID ConnectorID, body UpdateConnectorJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateConnectorRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) -} - -// NewUpdateConnectorRequestWithBody generates requests for UpdateConnector with any type of body -func NewUpdateConnectorRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { - var err error + if params != nil { + queryValues := queryURL.Query() - var pathParam0 string + if params.PerPage != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam1 string + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } + if params.Page != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewRevokeConnectorRequest generates requests for RevokeConnector -func NewRevokeConnectorRequest(server string, teamName TeamName, connectorID ConnectorID) (*http.Request, error) { +// NewDeleteSavedQueryRequest generates requests for DeleteSavedQuery +func NewDeleteSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15503,7 +13967,7 @@ func NewRevokeConnectorRequest(server string, teamName TeamName, connectorID Con return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15521,20 +13985,13 @@ func NewRevokeConnectorRequest(server string, teamName TeamName, connectorID Con return req, nil } -// NewGetConnectorAuthStatusAWSRequest generates requests for GetConnectorAuthStatusAWS -func NewGetConnectorAuthStatusAWSRequest(server string, teamName TeamName, connectorID ConnectorID) (*http.Request, error) { +// NewGetSavedQueryRequest generates requests for GetSavedQuery +func NewGetSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15544,7 +14001,7 @@ func NewGetConnectorAuthStatusAWSRequest(server string, teamName TeamName, conne return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/aws", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15562,31 +14019,24 @@ func NewGetConnectorAuthStatusAWSRequest(server string, teamName TeamName, conne return req, nil } -// NewAuthenticateConnectorFinishAWSRequest calls the generic AuthenticateConnectorFinishAWS builder with application/json body -func NewAuthenticateConnectorFinishAWSRequest(server string, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishAWSJSONRequestBody) (*http.Request, error) { +// NewUpdateQueryRequest calls the generic UpdateQuery builder with application/json body +func NewUpdateQueryRequest(server string, queryID QueryID, body UpdateQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewAuthenticateConnectorFinishAWSRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) + return NewUpdateQueryRequestWithBody(server, queryID, "application/json", bodyReader) } -// NewAuthenticateConnectorFinishAWSRequestWithBody generates requests for AuthenticateConnectorFinishAWS with any type of body -func NewAuthenticateConnectorFinishAWSRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateQueryRequestWithBody generates requests for UpdateQuery with any type of body +func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15596,7 +14046,7 @@ func NewAuthenticateConnectorFinishAWSRequestWithBody(server string, teamName Te return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/aws", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15616,31 +14066,13 @@ func NewAuthenticateConnectorFinishAWSRequestWithBody(server string, teamName Te return req, nil } -// NewAuthenticateConnectorAWSRequest calls the generic AuthenticateConnectorAWS builder with application/json body -func NewAuthenticateConnectorAWSRequest(server string, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorAWSJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewAuthenticateConnectorAWSRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) -} - -// NewAuthenticateConnectorAWSRequestWithBody generates requests for AuthenticateConnectorAWS with any type of body -func NewAuthenticateConnectorAWSRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { +// NewDeleteAlertRequest generates requests for DeleteAlert +func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15650,7 +14082,7 @@ func NewAuthenticateConnectorAWSRequestWithBody(server string, teamName TeamName return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/aws", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s/alert", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15660,30 +14092,21 @@ func NewAuthenticateConnectorAWSRequestWithBody(server string, teamName TeamName return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetConnectorAuthStatusGCPRequest generates requests for GetConnectorAuthStatusGCP -func NewGetConnectorAuthStatusGCPRequest(server string, teamName TeamName, connectorID ConnectorID) (*http.Request, error) { +// NewExecuteSavedQueryRequest generates requests for ExecuteSavedQuery +func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *ExecuteSavedQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15693,7 +14116,7 @@ func NewGetConnectorAuthStatusGCPRequest(server string, teamName TeamName, conne return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/gcp", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s/execute", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15703,39 +14126,171 @@ func NewGetConnectorAuthStatusGCPRequest(server string, teamName TeamName, conne return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} + if params.Selects != nil { -// NewAuthenticateConnectorGCPRequest calls the generic AuthenticateConnectorGCP builder with application/json body -func NewAuthenticateConnectorGCPRequest(server string, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorGCPJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewAuthenticateConnectorGCPRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewAuthenticateConnectorGCPRequestWithBody generates requests for AuthenticateConnectorGCP with any type of body -func NewAuthenticateConnectorGCPRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.FilterMode != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.FilterIDs != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.GroupBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } - var pathParam1 string + return req, nil +} + +// NewQueryListFiltersRequest generates requests for QueryListFilters +func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryListFiltersParams) (*http.Request, error) { + var err error - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15745,7 +14300,7 @@ func NewAuthenticateConnectorGCPRequestWithBody(server string, teamName TeamName return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/gcp", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15755,30 +14310,86 @@ func NewAuthenticateConnectorGCPRequestWithBody(server string, teamName TeamName return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.FilterTags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewAuthenticateConnectorFinishGCPRequest generates requests for AuthenticateConnectorFinishGCP -func NewAuthenticateConnectorFinishGCPRequest(server string, teamName TeamName, connectorID ConnectorID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewQuerySaveFilterRequest calls the generic QuerySaveFilter builder with application/json body +func NewQuerySaveFilterRequest(server string, queryID QueryID, body QuerySaveFilterJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewQuerySaveFilterRequestWithBody(server, queryID, "application/json", bodyReader) +} - var pathParam1 string +// NewQuerySaveFilterRequestWithBody generates requests for QuerySaveFilter with any type of body +func NewQuerySaveFilterRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15788,7 +14399,7 @@ func NewAuthenticateConnectorFinishGCPRequest(server string, teamName TeamName, return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/gcp/finish", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15798,49 +14409,98 @@ func NewAuthenticateConnectorFinishGCPRequest(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewAuthenticateConnectorFinishOAuthRequest calls the generic AuthenticateConnectorFinishOAuth builder with application/json body -func NewAuthenticateConnectorFinishOAuthRequest(server string, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishOAuthJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewQueryListFilterTagsRequest generates requests for QueryListFilterTags +func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *QueryListFilterTagsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewAuthenticateConnectorFinishOAuthRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) -} -// NewAuthenticateConnectorFinishOAuthRequestWithBody generates requests for AuthenticateConnectorFinishOAuth with any type of body -func NewAuthenticateConnectorFinishOAuthRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { - var err error + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - var pathParam0 string + operationPath := fmt.Sprintf("/queries/%s/filters/tags", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam1 string + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewListAllRBACPermissionsRequest generates requests for ListAllRBACPermissions +func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissionsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/oauth", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/permissions") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15850,51 +14510,121 @@ func NewAuthenticateConnectorFinishOAuthRequestWithBody(server string, teamName return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.RBACPermissionSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACPermissionSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.RBACPermissionSortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACPermissionSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SearchTerm != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewAuthenticateConnectorOAuthRequest calls the generic AuthenticateConnectorOAuth builder with application/json body -func NewAuthenticateConnectorOAuthRequest(server string, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorOAuthJSONRequestBody) (*http.Request, error) { +// NewCreateRBACPermissionRequest calls the generic CreateRBACPermission builder with application/json body +func NewCreateRBACPermissionRequest(server string, body CreateRBACPermissionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewAuthenticateConnectorOAuthRequestWithBody(server, teamName, connectorID, "application/json", bodyReader) + return NewCreateRBACPermissionRequestWithBody(server, "application/json", bodyReader) } -// NewAuthenticateConnectorOAuthRequestWithBody generates requests for AuthenticateConnectorOAuth with any type of body -func NewAuthenticateConnectorOAuthRequestWithBody(server string, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateRBACPermissionRequestWithBody generates requests for CreateRBACPermission with any type of body +func NewCreateRBACPermissionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/connectors/%s/authenticate/oauth", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/permissions") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15914,24 +14644,13 @@ func NewAuthenticateConnectorOAuthRequestWithBody(server string, teamName TeamNa return req, nil } -// NewCreateConversationRequest calls the generic CreateConversation builder with application/json body -func NewCreateConversationRequest(server string, teamName TeamName, body CreateConversationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateConversationRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateConversationRequestWithBody generates requests for CreateConversation with any type of body -func NewCreateConversationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewDeleteRBACPermissionRequest generates requests for DeleteRBACPermission +func NewDeleteRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -15941,7 +14660,7 @@ func NewCreateConversationRequestWithBody(server string, teamName TeamName, cont return nil, err } - operationPath := fmt.Sprintf("/teams/%s/conversations", pathParam0) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15951,30 +14670,21 @@ func NewCreateConversationRequestWithBody(server string, teamName TeamName, cont return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetConversationRequest generates requests for GetConversation -func NewGetConversationRequest(server string, teamName TeamName, conversationID ConversationID) (*http.Request, error) { +// NewGetRBACPermissionRequest generates requests for GetRBACPermission +func NewGetRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -15984,7 +14694,7 @@ func NewGetConversationRequest(server string, teamName TeamName, conversationID return nil, err } - operationPath := fmt.Sprintf("/teams/%s/conversations/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16002,31 +14712,24 @@ func NewGetConversationRequest(server string, teamName TeamName, conversationID return req, nil } -// NewSendMessageRequest calls the generic SendMessage builder with application/json body -func NewSendMessageRequest(server string, teamName TeamName, conversationID ConversationID, body SendMessageJSONRequestBody) (*http.Request, error) { +// NewUpdateRBACPermissionRequest calls the generic UpdateRBACPermission builder with application/json body +func NewUpdateRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewSendMessageRequestWithBody(server, teamName, conversationID, "application/json", bodyReader) + return NewUpdateRBACPermissionRequestWithBody(server, rbacPermissionID, "application/json", bodyReader) } -// NewSendMessageRequestWithBody generates requests for SendMessage with any type of body -func NewSendMessageRequestWithBody(server string, teamName TeamName, conversationID ConversationID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateRBACPermissionRequestWithBody generates requests for UpdateRBACPermission with any type of body +func NewUpdateRBACPermissionRequestWithBody(server string, rbacPermissionID RBACPermissionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -16036,7 +14739,7 @@ func NewSendMessageRequestWithBody(server string, teamName TeamName, conversatio return nil, err } - operationPath := fmt.Sprintf("/teams/%s/conversations/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16046,7 +14749,7 @@ func NewSendMessageRequestWithBody(server string, teamName TeamName, conversatio return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -16056,23 +14759,16 @@ func NewSendMessageRequestWithBody(server string, teamName TeamName, conversatio return req, nil } -// NewListAllCustomColumnsRequest generates requests for ListAllCustomColumns -func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *ListAllCustomColumnsParams) (*http.Request, error) { +// NewListAllRBACRolesRequest generates requests for ListAllRBACRoles +func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns", pathParam0) + operationPath := fmt.Sprintf("/rbac/roles") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16117,9 +14813,9 @@ func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *Li } - if params.CustomColumnSortBys != nil { + if params.RBACRoleSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.CustomColumnSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACRoleSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16133,9 +14829,9 @@ func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *Li } - if params.CustomColumnSortDirections != nil { + if params.RBACRoleSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.CustomColumnSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACRoleSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16149,9 +14845,9 @@ func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *Li } - if params.Table != nil { + if params.SearchTerm != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16165,9 +14861,9 @@ func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *Li } - if params.SearchTerm != nil { + if params.Type != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "type", runtime.ParamLocationQuery, *params.Type); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16192,34 +14888,27 @@ func NewListAllCustomColumnsRequest(server string, teamName TeamName, params *Li return req, nil } -// NewSaveCustomColumnRequest calls the generic SaveCustomColumn builder with application/json body -func NewSaveCustomColumnRequest(server string, teamName TeamName, body SaveCustomColumnJSONRequestBody) (*http.Request, error) { +// NewCreateRBACRoleRequest calls the generic CreateRBACRole builder with application/json body +func NewCreateRBACRoleRequest(server string, body CreateRBACRoleJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewSaveCustomColumnRequestWithBody(server, teamName, "application/json", bodyReader) + return NewCreateRBACRoleRequestWithBody(server, "application/json", bodyReader) } -// NewSaveCustomColumnRequestWithBody generates requests for SaveCustomColumn with any type of body -func NewSaveCustomColumnRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateRBACRoleRequestWithBody generates requests for CreateRBACRole with any type of body +func NewCreateRBACRoleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns", pathParam0) + operationPath := fmt.Sprintf("/rbac/roles") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16239,20 +14928,13 @@ func NewSaveCustomColumnRequestWithBody(server string, teamName TeamName, conten return req, nil } -// NewDeleteCustomColumnRequest generates requests for DeleteCustomColumn -func NewDeleteCustomColumnRequest(server string, teamName TeamName, customColumnID CustomColumnID) (*http.Request, error) { +// NewDeleteRBACRoleRequest generates requests for DeleteRBACRole +func NewDeleteRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) if err != nil { return nil, err } @@ -16262,7 +14944,7 @@ func NewDeleteCustomColumnRequest(server string, teamName TeamName, customColumn return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16280,20 +14962,13 @@ func NewDeleteCustomColumnRequest(server string, teamName TeamName, customColumn return req, nil } -// NewGetCustomColumnRequest generates requests for GetCustomColumn -func NewGetCustomColumnRequest(server string, teamName TeamName, customColumnID CustomColumnID) (*http.Request, error) { +// NewGetRBACRoleRequest generates requests for GetRBACRole +func NewGetRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) if err != nil { return nil, err } @@ -16303,7 +14978,7 @@ func NewGetCustomColumnRequest(server string, teamName TeamName, customColumnID return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16321,31 +14996,24 @@ func NewGetCustomColumnRequest(server string, teamName TeamName, customColumnID return req, nil } -// NewUpdateCustomColumnRequest calls the generic UpdateCustomColumn builder with application/json body -func NewUpdateCustomColumnRequest(server string, teamName TeamName, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody) (*http.Request, error) { +// NewUpdateRBACRoleRequest calls the generic UpdateRBACRole builder with application/json body +func NewUpdateRBACRoleRequest(server string, roleID RoleID, body UpdateRBACRoleJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateCustomColumnRequestWithBody(server, teamName, customColumnID, "application/json", bodyReader) + return NewUpdateRBACRoleRequestWithBody(server, roleID, "application/json", bodyReader) } -// NewUpdateCustomColumnRequestWithBody generates requests for UpdateCustomColumn with any type of body -func NewUpdateCustomColumnRequestWithBody(server string, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateRBACRoleRequestWithBody generates requests for UpdateRBACRole with any type of body +func NewUpdateRBACRoleRequestWithBody(server string, roleID RoleID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) if err != nil { return nil, err } @@ -16355,7 +15023,7 @@ func NewUpdateCustomColumnRequestWithBody(server string, teamName TeamName, cust return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16375,41 +15043,16 @@ func NewUpdateCustomColumnRequestWithBody(server string, teamName TeamName, cust return req, nil } -// NewPutCustomColumnDataRequest calls the generic PutCustomColumnData builder with application/json body -func NewPutCustomColumnDataRequest(server string, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnDataJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewPutCustomColumnDataRequestWithBody(server, teamName, customColumnID, "application/json", bodyReader) -} - -// NewPutCustomColumnDataRequestWithBody generates requests for PutCustomColumnData with any type of body -func NewPutCustomColumnDataRequestWithBody(server string, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader) (*http.Request, error) { +// NewListReportsRequest generates requests for ListReports +func NewListReportsRequest(server string, params *ListReportsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns/%s/import", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16419,51 +15062,137 @@ func NewPutCustomColumnDataRequestWithBody(server string, teamName TeamName, cus return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.SearchTerm != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewPutCustomColumnValuesRequest calls the generic PutCustomColumnValues builder with application/json body -func NewPutCustomColumnValuesRequest(server string, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnValuesJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewPutCustomColumnValuesRequestWithBody(server, teamName, customColumnID, "application/json", bodyReader) -} + } -// NewPutCustomColumnValuesRequestWithBody generates requests for PutCustomColumnValues with any type of body -func NewPutCustomColumnValuesRequestWithBody(server string, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader) (*http.Request, error) { - var err error + if params.Visibility != nil { - var pathParam0 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "visibility", runtime.ParamLocationQuery, *params.Visibility); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ReportSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ReportSortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - var pathParam1 string + return req, nil +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "custom_column_id", runtime.ParamLocationPath, customColumnID) +// NewCreateReportRequest calls the generic CreateReport builder with application/json body +func NewCreateReportRequest(server string, body CreateReportJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateReportRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateReportRequestWithBody generates requests for CreateReport with any type of body +func NewCreateReportRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/custom-columns/%s/values", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16473,7 +15202,7 @@ func NewPutCustomColumnValuesRequestWithBody(server string, teamName TeamName, c return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -16483,23 +15212,16 @@ func NewPutCustomColumnValuesRequestWithBody(server string, teamName TeamName, c return req, nil } -// NewListFiltersTeamRequest generates requests for ListFiltersTeam -func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFiltersTeamParams) (*http.Request, error) { +// NewListReportTemplatesRequest generates requests for ListReportTemplates +func NewListReportTemplatesRequest(server string, params *ListReportTemplatesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/filters", pathParam0) + operationPath := fmt.Sprintf("/reports/templates") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16512,9 +15234,9 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { + if params.SearchTerm != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16528,9 +15250,9 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil } - if params.Page != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16544,9 +15266,9 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil } - if params.FilterTags != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16560,9 +15282,9 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil } - if params.NameFilter != nil { + if params.ReportTemplateSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportTemplateSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16576,9 +15298,9 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil } - if params.ExpressionFilter != nil { + if params.ReportTemplateSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "expression_filter", runtime.ParamLocationQuery, *params.ExpressionFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportTemplateSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16603,23 +15325,27 @@ func NewListFiltersTeamRequest(server string, teamName TeamName, params *ListFil return req, nil } -// NewListFilterTagsTeamRequest generates requests for ListFilterTagsTeam -func NewListFilterTagsTeamRequest(server string, teamName TeamName, params *ListFilterTagsTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewCreateReportTemplateRequest calls the generic CreateReportTemplate builder with application/json body +func NewCreateReportTemplateRequest(server string, body CreateReportTemplateJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateReportTemplateRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateReportTemplateRequestWithBody generates requests for CreateReportTemplate with any type of body +func NewCreateReportTemplateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/filters/tags", pathParam0) + operationPath := fmt.Sprintf("/reports/templates") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16629,66 +15355,23 @@ func NewListFilterTagsTeamRequest(server string, teamName TeamName, params *List return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewDeleteFilterTeamRequest generates requests for DeleteFilterTeam -func NewDeleteFilterTeamRequest(server string, teamName TeamName, filterID FilterID) (*http.Request, error) { +// NewDeleteReportTemplateRequest generates requests for DeleteReportTemplate +func NewDeleteReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } @@ -16698,7 +15381,7 @@ func NewDeleteFilterTeamRequest(server string, teamName TeamName, filterID Filte return nil, err } - operationPath := fmt.Sprintf("/teams/%s/filters/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16716,20 +15399,13 @@ func NewDeleteFilterTeamRequest(server string, teamName TeamName, filterID Filte return req, nil } -// NewGetFilterByIDTeamRequest generates requests for GetFilterByIDTeam -func NewGetFilterByIDTeamRequest(server string, teamName TeamName, filterID FilterID) (*http.Request, error) { +// NewGetReportTemplateRequest generates requests for GetReportTemplate +func NewGetReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } @@ -16739,7 +15415,7 @@ func NewGetFilterByIDTeamRequest(server string, teamName TeamName, filterID Filt return nil, err } - operationPath := fmt.Sprintf("/teams/%s/filters/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16757,31 +15433,24 @@ func NewGetFilterByIDTeamRequest(server string, teamName TeamName, filterID Filt return req, nil } -// NewUpdateFilterTeamRequest calls the generic UpdateFilterTeam builder with application/json body -func NewUpdateFilterTeamRequest(server string, teamName TeamName, filterID FilterID, body UpdateFilterTeamJSONRequestBody) (*http.Request, error) { +// NewUpdateReportTemplateRequest calls the generic UpdateReportTemplate builder with application/json body +func NewUpdateReportTemplateRequest(server string, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateFilterTeamRequestWithBody(server, teamName, filterID, "application/json", bodyReader) + return NewUpdateReportTemplateRequestWithBody(server, templateId, "application/json", bodyReader) } -// NewUpdateFilterTeamRequestWithBody generates requests for UpdateFilterTeam with any type of body -func NewUpdateFilterTeamRequestWithBody(server string, teamName TeamName, filterID FilterID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateReportTemplateRequestWithBody generates requests for UpdateReportTemplate with any type of body +func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "filter_id", runtime.ParamLocationPath, filterID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } @@ -16791,7 +15460,7 @@ func NewUpdateFilterTeamRequestWithBody(server string, teamName TeamName, filter return nil, err } - operationPath := fmt.Sprintf("/teams/%s/filters/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16801,7 +15470,7 @@ func NewUpdateFilterTeamRequestWithBody(server string, teamName TeamName, filter return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } @@ -16811,24 +15480,47 @@ func NewUpdateFilterTeamRequestWithBody(server string, teamName TeamName, filter return req, nil } -// NewCreateTeamImagesRequest calls the generic CreateTeamImages builder with application/json body -func NewCreateTeamImagesRequest(server string, teamName TeamName, body CreateTeamImagesJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewDeleteReportRequest generates requests for DeleteReport +func NewDeleteReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateTeamImagesRequestWithBody(server, teamName, "application/json", bodyReader) + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/reports/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil } -// NewCreateTeamImagesRequestWithBody generates requests for CreateTeamImages with any type of body -func NewCreateTeamImagesRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewGetReportRequest generates requests for GetReport +func NewGetReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) if err != nil { return nil, err } @@ -16838,7 +15530,7 @@ func NewCreateTeamImagesRequestWithBody(server string, teamName TeamName, conten return nil, err } - operationPath := fmt.Sprintf("/teams/%s/images", pathParam0) + operationPath := fmt.Sprintf("/reports/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16848,34 +15540,32 @@ func NewCreateTeamImagesRequestWithBody(server string, teamName TeamName, conten return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewDeleteTeamInvitationRequest calls the generic DeleteTeamInvitation builder with application/json body -func NewDeleteTeamInvitationRequest(server string, teamName TeamName, body DeleteTeamInvitationJSONRequestBody) (*http.Request, error) { +// NewUpdateReportRequest calls the generic UpdateReport builder with application/json body +func NewUpdateReportRequest(server string, reportId openapi_types.UUID, body UpdateReportJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewDeleteTeamInvitationRequestWithBody(server, teamName, "application/json", bodyReader) + return NewUpdateReportRequestWithBody(server, reportId, "application/json", bodyReader) } -// NewDeleteTeamInvitationRequestWithBody generates requests for DeleteTeamInvitation with any type of body -func NewDeleteTeamInvitationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateReportRequestWithBody generates requests for UpdateReport with any type of body +func NewUpdateReportRequestWithBody(server string, reportId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) if err != nil { return nil, err } @@ -16885,7 +15575,7 @@ func NewDeleteTeamInvitationRequestWithBody(server string, teamName TeamName, co return nil, err } - operationPath := fmt.Sprintf("/teams/%s/invitations", pathParam0) + operationPath := fmt.Sprintf("/reports/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16895,7 +15585,7 @@ func NewDeleteTeamInvitationRequestWithBody(server string, teamName TeamName, co return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), body) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } @@ -16905,23 +15595,54 @@ func NewDeleteTeamInvitationRequestWithBody(server string, teamName TeamName, co return req, nil } -// NewListTeamInvitationsRequest generates requests for ListTeamInvitations -func NewListTeamInvitationsRequest(server string, teamName TeamName, params *ListTeamInvitationsParams) (*http.Request, error) { +// NewGetSettingsRequest generates requests for GetSettings +func NewGetSettingsRequest(server string) (*http.Request, error) { var err error - var pathParam0 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + operationPath := fmt.Sprintf("/settings") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateSettingsRequest calls the generic UpdateSettings builder with application/json body +func NewUpdateSettingsRequest(server string, body UpdateSettingsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateSettingsRequestWithBody(server, "application/json", bodyReader) +} + +// NewUpdateSettingsRequestWithBody generates requests for UpdateSettings with any type of body +func NewUpdateSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/invitations", pathParam0) + operationPath := fmt.Sprintf("/settings") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16931,42 +15652,33 @@ func NewListTeamInvitationsRequest(server string, teamName TeamName, params *Lis return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.Page != nil { + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req.Header.Add("Content-Type", contentType) - } + return req, nil +} - if params.PerPage != nil { +// NewGetDataSettingsRequest generates requests for GetDataSettings +func NewGetDataSettingsRequest(server string) (*http.Request, error) { + var err error - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - } + operationPath := fmt.Sprintf("/settings/data") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - queryURL.RawQuery = queryValues.Encode() + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -16977,34 +15689,27 @@ func NewListTeamInvitationsRequest(server string, teamName TeamName, params *Lis return req, nil } -// NewAcceptTeamInvitationRequest calls the generic AcceptTeamInvitation builder with application/json body -func NewAcceptTeamInvitationRequest(server string, teamName TeamName, body AcceptTeamInvitationJSONRequestBody) (*http.Request, error) { +// NewUpdateDataSettingsRequest calls the generic UpdateDataSettings builder with application/json body +func NewUpdateDataSettingsRequest(server string, body UpdateDataSettingsJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewAcceptTeamInvitationRequestWithBody(server, teamName, "application/json", bodyReader) + return NewUpdateDataSettingsRequestWithBody(server, "application/json", bodyReader) } -// NewAcceptTeamInvitationRequestWithBody generates requests for AcceptTeamInvitation with any type of body -func NewAcceptTeamInvitationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateDataSettingsRequestWithBody generates requests for UpdateDataSettings with any type of body +func NewUpdateDataSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/invitations/accept", pathParam0) + operationPath := fmt.Sprintf("/settings/data") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17014,7 +15719,7 @@ func NewAcceptTeamInvitationRequestWithBody(server string, teamName TeamName, co return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -17024,34 +15729,27 @@ func NewAcceptTeamInvitationRequestWithBody(server string, teamName TeamName, co return req, nil } -// NewRemoveTeamMembershipRequest calls the generic RemoveTeamMembership builder with application/json body -func NewRemoveTeamMembershipRequest(server string, teamName TeamName, body RemoveTeamMembershipJSONRequestBody) (*http.Request, error) { +// NewCreateSlackConnectionRequest calls the generic CreateSlackConnection builder with application/json body +func NewCreateSlackConnectionRequest(server string, body CreateSlackConnectionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewRemoveTeamMembershipRequestWithBody(server, teamName, "application/json", bodyReader) + return NewCreateSlackConnectionRequestWithBody(server, "application/json", bodyReader) } -// NewRemoveTeamMembershipRequestWithBody generates requests for RemoveTeamMembership with any type of body -func NewRemoveTeamMembershipRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateSlackConnectionRequestWithBody generates requests for CreateSlackConnection with any type of body +func NewCreateSlackConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/memberships", pathParam0) + operationPath := fmt.Sprintf("/slack") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17061,7 +15759,7 @@ func NewRemoveTeamMembershipRequestWithBody(server string, teamName TeamName, co return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -17071,13 +15769,13 @@ func NewRemoveTeamMembershipRequestWithBody(server string, teamName TeamName, co return req, nil } -// NewGetTeamMembershipsRequest generates requests for GetTeamMemberships -func NewGetTeamMembershipsRequest(server string, teamName TeamName, params *GetTeamMembershipsParams) (*http.Request, error) { +// NewListSlackChannelsRequest generates requests for ListSlackChannels +func NewListSlackChannelsRequest(server string, id openapi_types.UUID, params *ListSlackChannelsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "id", runtime.ParamLocationPath, id) if err != nil { return nil, err } @@ -17087,7 +15785,7 @@ func NewGetTeamMembershipsRequest(server string, teamName TeamName, params *GetT return nil, err } - operationPath := fmt.Sprintf("/teams/%s/memberships", pathParam0) + operationPath := fmt.Sprintf("/slack/%s/channels", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17100,25 +15798,9 @@ func NewGetTeamMembershipsRequest(server string, teamName TeamName, params *GetT if params != nil { queryValues := queryURL.Query() - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PerPage != nil { + if params.Name != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name", runtime.ParamLocationQuery, *params.Name); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17143,30 +15825,27 @@ func NewGetTeamMembershipsRequest(server string, teamName TeamName, params *GetT return req, nil } -// NewDeleteTeamMembershipRequest generates requests for DeleteTeamMembership -func NewDeleteTeamMembershipRequest(server string, teamName TeamName, email EmailBasic) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewCreateSyncDestinationTestConnectionRequest calls the generic CreateSyncDestinationTestConnection builder with application/json body +func NewCreateSyncDestinationTestConnectionRequest(server string, body CreateSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateSyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "email", runtime.ParamLocationPath, email) - if err != nil { - return nil, err - } +// NewCreateSyncDestinationTestConnectionRequestWithBody generates requests for CreateSyncDestinationTestConnection with any type of body +func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/memberships/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17176,28 +15855,23 @@ func NewDeleteTeamMembershipRequest(server string, teamName TeamName, email Emai return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewDeleteNotificationDestinationRequest generates requests for DeleteNotificationDestination -func NewDeleteNotificationDestinationRequest(server string, teamName TeamName, notificationDestinationID NotificationDestinationID) (*http.Request, error) { +// NewGetSyncDestinationTestConnectionRequest generates requests for GetSyncDestinationTestConnection +func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17207,7 +15881,7 @@ func NewDeleteNotificationDestinationRequest(server string, teamName TeamName, n return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destination/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17217,7 +15891,7 @@ func NewDeleteNotificationDestinationRequest(server string, teamName TeamName, n return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -17225,20 +15899,24 @@ func NewDeleteNotificationDestinationRequest(server string, teamName TeamName, n return req, nil } -// NewGetNotificationDestinationRequest generates requests for GetNotificationDestination -func NewGetNotificationDestinationRequest(server string, teamName TeamName, notificationDestinationID NotificationDestinationID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewUpdateSyncTestConnectionForSyncDestinationRequest calls the generic UpdateSyncTestConnectionForSyncDestination builder with application/json body +func NewUpdateSyncTestConnectionForSyncDestinationRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) +} - var pathParam1 string +// NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestination with any type of body +func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationID) + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17248,7 +15926,7 @@ func NewGetNotificationDestinationRequest(server string, teamName TeamName, noti return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destination/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17258,39 +15936,23 @@ func NewGetNotificationDestinationRequest(server string, teamName TeamName, noti return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } - return req, nil -} + req.Header.Add("Content-Type", contentType) -// NewUpdateNotificationDestinationRequest calls the generic UpdateNotificationDestination builder with application/json body -func NewUpdateNotificationDestinationRequest(server string, teamName TeamName, notificationDestinationID NotificationDestinationID, body UpdateNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateNotificationDestinationRequestWithBody(server, teamName, notificationDestinationID, "application/json", bodyReader) + return req, nil } -// NewUpdateNotificationDestinationRequestWithBody generates requests for UpdateNotificationDestination with any type of body -func NewUpdateNotificationDestinationRequestWithBody(server string, teamName TeamName, notificationDestinationID NotificationDestinationID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetSyncDestinationTestConnectionLogsLiveRequest generates requests for GetSyncDestinationTestConnectionLogsLive +func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17300,7 +15962,7 @@ func NewUpdateNotificationDestinationRequestWithBody(server string, teamName Tea return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destination/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/live", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17310,30 +15972,36 @@ func NewUpdateNotificationDestinationRequestWithBody(server string, teamName Tea return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } return req, nil } -// NewGetNotificationDestinationAlertsRequest generates requests for GetNotificationDestinationAlerts -func NewGetNotificationDestinationAlertsRequest(server string, teamName TeamName, notificationDestinationID NotificationDestinationID, params *GetNotificationDestinationAlertsParams) (*http.Request, error) { +// NewGetSyncDestinationTestConnectionLogsQueryRequest generates requests for GetSyncDestinationTestConnectionLogsQuery +func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17343,7 +16011,7 @@ func NewGetNotificationDestinationAlertsRequest(server string, teamName TeamName return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destination/%s/alerts", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/query", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17356,6 +16024,22 @@ func NewGetNotificationDestinationAlertsRequest(server string, teamName TeamName if params != nil { queryValues := queryURL.Query() + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -17388,31 +16072,66 @@ func NewGetNotificationDestinationAlertsRequest(server string, teamName TeamName } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params.Download != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewTestNotificationDestinationRequest generates requests for TestNotificationDestination -func NewTestNotificationDestinationRequest(server string, teamName TeamName, notificationDestinationID NotificationDestinationID) (*http.Request, error) { - var err error + } - var pathParam0 string + queryURL.RawQuery = queryValues.Encode() + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - var pathParam1 string + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationID) + } + + return req, nil +} + +// NewPromoteSyncDestinationTestConnectionRequest calls the generic PromoteSyncDestinationTestConnection builder with application/json body +func NewPromoteSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPromoteSyncDestinationTestConnectionRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) +} + +// NewPromoteSyncDestinationTestConnectionRequestWithBody generates requests for PromoteSyncDestinationTestConnection with any type of body +func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17422,7 +16141,7 @@ func NewTestNotificationDestinationRequest(server string, teamName TeamName, not return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destination/%s/test", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/promote", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17432,31 +16151,26 @@ func NewTestNotificationDestinationRequest(server string, teamName TeamName, not return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListAllNotificationDestinationsRequest generates requests for ListAllNotificationDestinations -func NewListAllNotificationDestinationsRequest(server string, teamName TeamName, params *ListAllNotificationDestinationsParams) (*http.Request, error) { +// NewListSyncDestinationsRequest generates requests for ListSyncDestinations +func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destinations", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17501,6 +16215,54 @@ func NewListAllNotificationDestinationsRequest(server string, teamName TeamName, } + if params.Filter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SyncGenericSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SyncSortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + queryURL.RawQuery = queryValues.Encode() } @@ -17512,24 +16274,13 @@ func NewListAllNotificationDestinationsRequest(server string, teamName TeamName, return req, nil } -// NewCreateNotificationDestinationRequest calls the generic CreateNotificationDestination builder with application/json body -func NewCreateNotificationDestinationRequest(server string, teamName TeamName, body CreateNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateNotificationDestinationRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateNotificationDestinationRequestWithBody generates requests for CreateNotificationDestination with any type of body -func NewCreateNotificationDestinationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewDeleteSyncDestinationRequest generates requests for DeleteSyncDestination +func NewDeleteSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17539,7 +16290,7 @@ func NewCreateNotificationDestinationRequestWithBody(server string, teamName Tea return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destinations", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17549,34 +16300,21 @@ func NewCreateNotificationDestinationRequestWithBody(server string, teamName Tea return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewTestUnsavedNotificationDestinationRequest calls the generic TestUnsavedNotificationDestination builder with application/json body -func NewTestUnsavedNotificationDestinationRequest(server string, teamName TeamName, body TestUnsavedNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewTestUnsavedNotificationDestinationRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewTestUnsavedNotificationDestinationRequestWithBody generates requests for TestUnsavedNotificationDestination with any type of body -func NewTestUnsavedNotificationDestinationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewGetSyncDestinationRequest generates requests for GetSyncDestination +func NewGetSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17586,7 +16324,7 @@ func NewTestUnsavedNotificationDestinationRequestWithBody(server string, teamNam return nil, err } - operationPath := fmt.Sprintf("/teams/%s/notifications/destinations/test", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17596,34 +16334,32 @@ func NewTestUnsavedNotificationDestinationRequestWithBody(server string, teamNam return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewCreateAWSOnboardingRequest calls the generic CreateAWSOnboarding builder with application/json body -func NewCreateAWSOnboardingRequest(server string, teamName TeamName, body CreateAWSOnboardingJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncDestinationRequest calls the generic UpdateSyncDestination builder with application/json body +func NewUpdateSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateAWSOnboardingRequestWithBody(server, teamName, "application/json", bodyReader) + return NewUpdateSyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) } -// NewCreateAWSOnboardingRequestWithBody generates requests for CreateAWSOnboarding with any type of body -func NewCreateAWSOnboardingRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncDestinationRequestWithBody generates requests for UpdateSyncDestination with any type of body +func NewUpdateSyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17633,7 +16369,7 @@ func NewCreateAWSOnboardingRequestWithBody(server string, teamName TeamName, con return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17643,7 +16379,7 @@ func NewCreateAWSOnboardingRequestWithBody(server string, teamName TeamName, con return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -17653,20 +16389,13 @@ func NewCreateAWSOnboardingRequestWithBody(server string, teamName TeamName, con return req, nil } -// NewGetAWSOnboardingRequest generates requests for GetAWSOnboarding -func NewGetAWSOnboardingRequest(server string, teamName TeamName, onboardingID OnboardingID) (*http.Request, error) { +// NewListSyncDestinationSyncsRequest generates requests for ListSyncDestinationSyncs +func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17676,7 +16405,7 @@ func NewGetAWSOnboardingRequest(server string, teamName TeamName, onboardingID O return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destinations/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17686,6 +16415,108 @@ func NewGetAWSOnboardingRequest(server string, teamName TeamName, onboardingID O return nil, err } + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SyncSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SyncSortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Filter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.MigrationFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -17694,20 +16525,20 @@ func NewGetAWSOnboardingRequest(server string, teamName TeamName, onboardingID O return req, nil } -// NewGetAWSAccountsInRootRequest generates requests for GetAWSAccountsInRoot -func NewGetAWSAccountsInRootRequest(server string, teamName TeamName, onboardingID OnboardingID) (*http.Request, error) { +// NewGetTestConnectionForSyncDestinationRequest generates requests for GetTestConnectionForSyncDestination +func NewGetTestConnectionForSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) if err != nil { return nil, err } @@ -17717,7 +16548,7 @@ func NewGetAWSAccountsInRootRequest(server string, teamName TeamName, onboarding return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc/%s/accounts", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destinations/%s/test-connections/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17735,41 +16566,27 @@ func NewGetAWSAccountsInRootRequest(server string, teamName TeamName, onboarding return req, nil } -// NewProvisionOnboardingConfigurationRequest calls the generic ProvisionOnboardingConfiguration builder with application/json body -func NewProvisionOnboardingConfigurationRequest(server string, teamName TeamName, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody) (*http.Request, error) { +// NewCreateSyncSourceTestConnectionRequest calls the generic CreateSyncSourceTestConnection builder with application/json body +func NewCreateSyncSourceTestConnectionRequest(server string, body CreateSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewProvisionOnboardingConfigurationRequestWithBody(server, teamName, onboardingID, "application/json", bodyReader) + return NewCreateSyncSourceTestConnectionRequestWithBody(server, "application/json", bodyReader) } -// NewProvisionOnboardingConfigurationRequestWithBody generates requests for ProvisionOnboardingConfiguration with any type of body -func NewProvisionOnboardingConfigurationRequestWithBody(server string, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateSyncSourceTestConnectionRequestWithBody generates requests for CreateSyncSourceTestConnection with any type of body +func NewCreateSyncSourceTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc/%s/accounts/provision", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-source-test-connections") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17789,27 +16606,13 @@ func NewProvisionOnboardingConfigurationRequestWithBody(server string, teamName return req, nil } -// NewGetAWSAccountsInParentRequest generates requests for GetAWSAccountsInParent -func NewGetAWSAccountsInParentRequest(server string, teamName TeamName, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID) (*http.Request, error) { +// NewGetSyncSourceTestConnectionRequest generates requests for GetSyncSourceTestConnection +func NewGetSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "aws_orgunit_id", runtime.ParamLocationPath, organizationalUnitID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -17819,7 +16622,7 @@ func NewGetAWSAccountsInParentRequest(server string, teamName TeamName, onboardi return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc/%s/accounts/%s", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17837,31 +16640,24 @@ func NewGetAWSAccountsInParentRequest(server string, teamName TeamName, onboardi return req, nil } -// NewNotifyOnboardingRequest calls the generic NotifyOnboarding builder with application/json body -func NewNotifyOnboardingRequest(server string, teamName TeamName, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceRequest calls the generic UpdateSyncTestConnectionForSyncSource builder with application/json body +func NewUpdateSyncTestConnectionForSyncSourceRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewNotifyOnboardingRequestWithBody(server, teamName, onboardingID, "application/json", bodyReader) + return NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) } -// NewNotifyOnboardingRequestWithBody generates requests for NotifyOnboarding with any type of body -func NewNotifyOnboardingRequestWithBody(server string, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSource with any type of body +func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -17871,7 +16667,7 @@ func NewNotifyOnboardingRequestWithBody(server string, teamName TeamName, onboar return nil, err } - operationPath := fmt.Sprintf("/teams/%s/onboardings/aws/oidc/%s/notify", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17881,7 +16677,7 @@ func NewNotifyOnboardingRequestWithBody(server string, teamName TeamName, onboar return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -17891,13 +16687,13 @@ func NewNotifyOnboardingRequestWithBody(server string, teamName TeamName, onboar return req, nil } -// NewDeletePluginsByTeamRequest generates requests for DeletePluginsByTeam -func NewDeletePluginsByTeamRequest(server string, teamName TeamName) (*http.Request, error) { +// NewGetSyncSourceTestConnectionLogsLiveRequest generates requests for GetSyncSourceTestConnectionLogsLive +func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -17907,7 +16703,7 @@ func NewDeletePluginsByTeamRequest(server string, teamName TeamName) (*http.Requ return nil, err } - operationPath := fmt.Sprintf("/teams/%s/plugins", pathParam0) + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/live", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17917,21 +16713,36 @@ func NewDeletePluginsByTeamRequest(server string, teamName TeamName) (*http.Requ return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } + return req, nil } -// NewListPluginsByTeamRequest generates requests for ListPluginsByTeam -func NewListPluginsByTeamRequest(server string, teamName TeamName, params *ListPluginsByTeamParams) (*http.Request, error) { +// NewGetSyncSourceTestConnectionLogsQueryRequest generates requests for GetSyncSourceTestConnectionLogsQuery +func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -17941,7 +16752,7 @@ func NewListPluginsByTeamRequest(server string, teamName TeamName, params *ListP return nil, err } - operationPath := fmt.Sprintf("/teams/%s/plugins", pathParam0) + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/query", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17954,9 +16765,9 @@ func NewListPluginsByTeamRequest(server string, teamName TeamName, params *ListP if params != nil { queryValues := queryURL.Query() - if params.Page != nil { + if params.Filters != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17986,9 +16797,25 @@ func NewListPluginsByTeamRequest(server string, teamName TeamName, params *ListP } - if params.IncludePrivate != nil { + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Download != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_private", runtime.ParamLocationQuery, *params.IncludePrivate); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18010,51 +16837,42 @@ func NewListPluginsByTeamRequest(server string, teamName TeamName, params *ListP return nil, err } - return req, nil -} - -// NewDownloadPluginAssetByTeamRequest generates requests for DownloadPluginAssetByTeam -func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if params != nil { - var pathParam1 string + if params.Accept != nil { + var headerParam0 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_team", runtime.ParamLocationPath, pluginTeam) - if err != nil { - return nil, err - } + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } - var pathParam2 string + req.Header.Set("Accept", headerParam0) + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err } - var pathParam3 string + return req, nil +} - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) +// NewPromoteSyncSourceTestConnectionRequest calls the generic PromoteSyncSourceTestConnection builder with application/json body +func NewPromoteSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewPromoteSyncSourceTestConnectionRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) +} - var pathParam4 string - - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) - if err != nil { - return nil, err - } +// NewPromoteSyncSourceTestConnectionRequestWithBody generates requests for PromoteSyncSourceTestConnection with any type of body +func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error - var pathParam5 string + var pathParam0 string - pathParam5, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -18064,7 +16882,7 @@ func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, plugi return nil, err } - operationPath := fmt.Sprintf("/teams/%s/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4, pathParam5) + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/promote", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18074,46 +16892,26 @@ func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, plugi return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } + req.Header.Add("Content-Type", contentType) return req, nil } -// NewListPoliciesRequest generates requests for ListPolicies -func NewListPoliciesRequest(server string, teamName TeamName, params *ListPoliciesParams) (*http.Request, error) { +// NewListSyncSourcesRequest generates requests for ListSyncSources +func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies", pathParam0) + operationPath := fmt.Sprintf("/sync-sources") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18126,22 +16924,6 @@ func NewListPoliciesRequest(server string, teamName TeamName, params *ListPolici if params != nil { queryValues := queryURL.Query() - if params.SearchTerm != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -18174,9 +16956,9 @@ func NewListPoliciesRequest(server string, teamName TeamName, params *ListPolici } - if params.PlatformPolicySortBys != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.PlatformPolicySortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18190,9 +16972,9 @@ func NewListPoliciesRequest(server string, teamName TeamName, params *ListPolici } - if params.PlatformPolicySortDirections != nil { + if params.SyncGenericSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.PlatformPolicySortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18206,9 +16988,9 @@ func NewListPoliciesRequest(server string, teamName TeamName, params *ListPolici } - if params.Sort != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort", runtime.ParamLocationQuery, *params.Sort); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18233,24 +17015,13 @@ func NewListPoliciesRequest(server string, teamName TeamName, params *ListPolici return req, nil } -// NewCreatePolicyRequest calls the generic CreatePolicy builder with application/json body -func NewCreatePolicyRequest(server string, teamName TeamName, body CreatePolicyJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreatePolicyRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreatePolicyRequestWithBody generates requests for CreatePolicy with any type of body -func NewCreatePolicyRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewDeleteSyncSourceRequest generates requests for DeleteSyncSource +func NewDeleteSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18260,7 +17031,7 @@ func NewCreatePolicyRequestWithBody(server string, teamName TeamName, contentTyp return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18270,23 +17041,21 @@ func NewCreatePolicyRequestWithBody(server string, teamName TeamName, contentTyp return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListAllFrameworksRequest generates requests for ListAllFrameworks -func NewListAllFrameworksRequest(server string, teamName TeamName, params *ListAllFrameworksParams) (*http.Request, error) { +// NewGetSyncSourceRequest generates requests for GetSyncSource +func NewGetSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18296,7 +17065,7 @@ func NewListAllFrameworksRequest(server string, teamName TeamName, params *ListA return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/frameworks", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18306,44 +17075,6 @@ func NewListAllFrameworksRequest(server string, teamName TeamName, params *ListA return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -18352,113 +17083,24 @@ func NewListAllFrameworksRequest(server string, teamName TeamName, params *ListA return req, nil } -// NewDeletePolicyRequest generates requests for DeletePolicy -func NewDeletePolicyRequest(server string, teamName TeamName, policyId openapi_types.UUID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/policies/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetPolicyRequest generates requests for GetPolicy -func NewGetPolicyRequest(server string, teamName TeamName, policyId openapi_types.UUID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/policies/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdatePolicyRequest calls the generic UpdatePolicy builder with application/json body -func NewUpdatePolicyRequest(server string, teamName TeamName, policyId openapi_types.UUID, body UpdatePolicyJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncSourceRequest calls the generic UpdateSyncSource builder with application/json body +func NewUpdateSyncSourceRequest(server string, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdatePolicyRequestWithBody(server, teamName, policyId, "application/json", bodyReader) + return NewUpdateSyncSourceRequestWithBody(server, syncSourceName, "application/json", bodyReader) } -// NewUpdatePolicyRequestWithBody generates requests for UpdatePolicy with any type of body -func NewUpdatePolicyRequestWithBody(server string, teamName TeamName, policyId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncSourceRequestWithBody generates requests for UpdateSyncSource with any type of body +func NewUpdateSyncSourceRequestWithBody(server string, syncSourceName SyncSourceName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18468,7 +17110,7 @@ func NewUpdatePolicyRequestWithBody(server string, teamName TeamName, policyId o return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18478,7 +17120,7 @@ func NewUpdatePolicyRequestWithBody(server string, teamName TeamName, policyId o return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -18488,20 +17130,13 @@ func NewUpdatePolicyRequestWithBody(server string, teamName TeamName, policyId o return req, nil } -// NewListPolicyFrameworksRequest generates requests for ListPolicyFrameworks -func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyFrameworksParams) (*http.Request, error) { +// NewListSyncSourceSyncsRequest generates requests for ListSyncSourceSyncs +func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18511,7 +17146,7 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s/frameworks", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-sources/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18556,9 +17191,9 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o } - if params.PlatformPolicyFrameworkSortBys != nil { + if params.SyncSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.PlatformPolicyFrameworkSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18572,9 +17207,9 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o } - if params.PlatformPolicySortDirections != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.PlatformPolicySortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18588,9 +17223,9 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o } - if params.SearchTerm != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18604,9 +17239,9 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o } - if params.Sort != nil { + if params.MigrationFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort", runtime.ParamLocationQuery, *params.Sort); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18631,30 +17266,57 @@ func NewListPolicyFrameworksRequest(server string, teamName TeamName, policyId o return req, nil } -// NewListPolicyRulesRequest generates requests for ListPolicyRules -func NewListPolicyRulesRequest(server string, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyRulesParams) (*http.Request, error) { +// NewGetTestConnectionForSyncSourceRequest generates requests for GetTestConnectionForSyncSource +func NewGetTestConnectionForSyncSourceRequest(server string, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-sources/%s/test-connections/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewListSyncTransformersRequest generates requests for ListSyncTransformers +func NewListSyncTransformersRequest(server string, params *ListSyncTransformersParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s/rules", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18699,25 +17361,9 @@ func NewListPolicyRulesRequest(server string, teamName TeamName, policyId openap } - if params.PlatformPolicyRuleSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.PlatformPolicyRuleSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PlatformPolicySortDirections != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.PlatformPolicySortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18731,9 +17377,9 @@ func NewListPolicyRulesRequest(server string, teamName TeamName, policyId openap } - if params.SearchTerm != nil { + if params.SyncGenericSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18747,9 +17393,9 @@ func NewListPolicyRulesRequest(server string, teamName TeamName, policyId openap } - if params.Sort != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort", runtime.ParamLocationQuery, *params.Sort); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18774,27 +17420,47 @@ func NewListPolicyRulesRequest(server string, teamName TeamName, policyId openap return req, nil } -// NewListPolicyRuleDetailsRequest generates requests for ListPolicyRuleDetails -func NewListPolicyRuleDetailsRequest(server string, teamName TeamName, policyId openapi_types.UUID, ruleId openapi_types.UUID, params *ListPolicyRuleDetailsParams) (*http.Request, error) { +// NewDeleteSyncTransformerRequest generates requests for DeleteSyncTransformer +func NewDeleteSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } - var pathParam1 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam2 string + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetSyncTransformerRequest generates requests for GetSyncTransformer +func NewGetSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { + var err error + + var pathParam0 string - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "rule_id", runtime.ParamLocationPath, ruleId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -18804,7 +17470,7 @@ func NewListPolicyRuleDetailsRequest(server string, teamName TeamName, policyId return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s/rules/%s/details", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18814,108 +17480,6 @@ func NewListPolicyRuleDetailsRequest(server string, teamName TeamName, policyId return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PlatformPolicyRuleDetailSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.PlatformPolicyRuleDetailSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PlatformPolicySortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.PlatformPolicySortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SearchTerm != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Sort != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort", runtime.ParamLocationQuery, *params.Sort); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -18924,20 +17488,24 @@ func NewListPolicyRuleDetailsRequest(server string, teamName TeamName, policyId return req, nil } -// NewTogglePolicyRequest generates requests for TogglePolicy -func NewTogglePolicyRequest(server string, teamName TeamName, policyId openapi_types.UUID, params *TogglePolicyParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewUpdateSyncTransformerRequest calls the generic UpdateSyncTransformer builder with application/json body +func NewUpdateSyncTransformerRequest(server string, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTransformerRequestWithBody(server, syncTransformerName, "application/json", bodyReader) +} - var pathParam1 string +// NewUpdateSyncTransformerRequestWithBody generates requests for UpdateSyncTransformer with any type of body +func NewUpdateSyncTransformerRequestWithBody(server string, syncTransformerName SyncTransformerName, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -18947,7 +17515,7 @@ func NewTogglePolicyRequest(server string, teamName TeamName, policyId openapi_t return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s/toggle", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18957,46 +17525,23 @@ func NewTogglePolicyRequest(server string, teamName TeamName, policyId openapi_t return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "status", runtime.ParamLocationQuery, params.Status); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetPolicyViolationsHistoryRequest generates requests for GetPolicyViolationsHistory -func NewGetPolicyViolationsHistoryRequest(server string, teamName TeamName, policyId openapi_types.UUID, params *GetPolicyViolationsHistoryParams) (*http.Request, error) { +// NewListSyncTransformerSyncDestinationsRequest generates requests for ListSyncTransformerSyncDestinations +func NewListSyncTransformerSyncDestinationsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -19006,7 +17551,7 @@ func NewGetPolicyViolationsHistoryRequest(server string, teamName TeamName, poli return nil, err } - operationPath := fmt.Sprintf("/teams/%s/policies/%s/violations-history", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers/%s/sync-destinations", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19019,9 +17564,9 @@ func NewGetPolicyViolationsHistoryRequest(server string, teamName TeamName, poli if params != nil { queryValues := queryURL.Query() - if params.Start != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19035,9 +17580,9 @@ func NewGetPolicyViolationsHistoryRequest(server string, teamName TeamName, poli } - if params.End != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19062,13 +17607,13 @@ func NewGetPolicyViolationsHistoryRequest(server string, teamName TeamName, poli return req, nil } -// NewListAllQueriesTeamRequest generates requests for ListAllQueriesTeam -func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *ListAllQueriesTeamParams) (*http.Request, error) { +// NewListSyncTransformerSyncsRequest generates requests for ListSyncTransformerSyncs +func NewListSyncTransformerSyncsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -19078,7 +17623,7 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries", pathParam0) + operationPath := fmt.Sprintf("/sync-transformers/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19123,9 +17668,42 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.QueryTags != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.QueryTags); err != nil { + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewListSyncUpgradesRequest generates requests for ListSyncUpgrades +func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-upgrades") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19139,9 +17717,9 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.NameFilter != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19155,9 +17733,9 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.QueryFilter != nil { + if params.SyncUpgradesSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_filter", runtime.ParamLocationQuery, *params.QueryFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncUpgradesSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19171,9 +17749,9 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.AlertConfigured != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_configured", runtime.ParamLocationQuery, *params.AlertConfigured); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19187,9 +17765,9 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.AlertMessageFilter != nil { + if params.Path != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_message_filter", runtime.ParamLocationQuery, *params.AlertMessageFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "path", runtime.ParamLocationQuery, *params.Path); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19203,9 +17781,25 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List } - if params.AlertEnabled != nil { + if params.Kind != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_enabled", runtime.ParamLocationQuery, *params.AlertEnabled); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "kind", runtime.ParamLocationQuery, *params.Kind); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PlatformVersion != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "platform_version", runtime.ParamLocationQuery, *params.PlatformVersion); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19230,34 +17824,16 @@ func NewListAllQueriesTeamRequest(server string, teamName TeamName, params *List return req, nil } -// NewExecuteAdHocQueryTeamRequest calls the generic ExecuteAdHocQueryTeam builder with application/json body -func NewExecuteAdHocQueryTeamRequest(server string, teamName TeamName, params *ExecuteAdHocQueryTeamParams, body ExecuteAdHocQueryTeamJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewExecuteAdHocQueryTeamRequestWithBody(server, teamName, params, "application/json", bodyReader) -} - -// NewExecuteAdHocQueryTeamRequestWithBody generates requests for ExecuteAdHocQueryTeam with any type of body -func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, params *ExecuteAdHocQueryTeamParams, contentType string, body io.Reader) (*http.Request, error) { +// NewListSyncsRequest generates requests for ListSyncs +func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/execute", pathParam0) + operationPath := fmt.Sprintf("/syncs") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19270,57 +17846,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p if params != nil { queryValues := queryURL.Query() - if params.Selects != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filters != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterIDs != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19334,9 +17862,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p } - if params.SortBys != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19350,9 +17878,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p } - if params.SortDirections != nil { + if params.SyncSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19366,9 +17894,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p } - if params.GroupBys != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19382,9 +17910,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p } - if params.PerPage != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19398,9 +17926,9 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p } - if params.Page != nil { + if params.MigrationFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19417,44 +17945,35 @@ func NewExecuteAdHocQueryTeamRequestWithBody(server string, teamName TeamName, p queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewSaveQueryTeamRequest calls the generic SaveQueryTeam builder with application/json body -func NewSaveQueryTeamRequest(server string, teamName TeamName, body SaveQueryTeamJSONRequestBody) (*http.Request, error) { +// NewCreateSyncRequest calls the generic CreateSync builder with application/json body +func NewCreateSyncRequest(server string, body CreateSyncJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewSaveQueryTeamRequestWithBody(server, teamName, "application/json", bodyReader) + return NewCreateSyncRequestWithBody(server, "application/json", bodyReader) } -// NewSaveQueryTeamRequestWithBody generates requests for SaveQueryTeam with any type of body -func NewSaveQueryTeamRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateSyncRequestWithBody generates requests for CreateSync with any type of body +func NewCreateSyncRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/save", pathParam0) + operationPath := fmt.Sprintf("/syncs") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19474,13 +17993,13 @@ func NewSaveQueryTeamRequestWithBody(server string, teamName TeamName, contentTy return req, nil } -// NewListQueryTagsTeamRequest generates requests for ListQueryTagsTeam -func NewListQueryTagsTeamRequest(server string, teamName TeamName, params *ListQueryTagsTeamParams) (*http.Request, error) { +// NewDeleteSyncRequest generates requests for DeleteSync +func NewDeleteSyncRequest(server string, syncName SyncName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19490,7 +18009,7 @@ func NewListQueryTagsTeamRequest(server string, teamName TeamName, params *ListQ return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/tags", pathParam0) + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19500,8 +18019,139 @@ func NewListQueryTagsTeamRequest(server string, teamName TeamName, params *ListQ return nil, err } - if params != nil { - queryValues := queryURL.Query() + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetSyncRequest generates requests for GetSync +func NewGetSyncRequest(server string, syncName SyncName) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateSyncRequest calls the generic UpdateSync builder with application/json body +func NewUpdateSyncRequest(server string, syncName SyncName, body UpdateSyncJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncRequestWithBody(server, syncName, "application/json", bodyReader) +} + +// NewUpdateSyncRequestWithBody generates requests for UpdateSync with any type of body +func NewUpdateSyncRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewListSyncRunsRequest generates requests for ListSyncRuns +func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRunsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.MigrationFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } if params.PerPage != nil { @@ -19546,20 +18196,13 @@ func NewListQueryTagsTeamRequest(server string, teamName TeamName, params *ListQ return req, nil } -// NewDeleteSavedQueryTeamRequest generates requests for DeleteSavedQueryTeam -func NewDeleteSavedQueryTeamRequest(server string, teamName TeamName, queryID QueryID) (*http.Request, error) { +// NewCreateSyncRunRequest generates requests for CreateSyncRun +func NewCreateSyncRunRequest(server string, syncName SyncName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19569,7 +18212,7 @@ func NewDeleteSavedQueryTeamRequest(server string, teamName TeamName, queryID Qu return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19579,7 +18222,7 @@ func NewDeleteSavedQueryTeamRequest(server string, teamName TeamName, queryID Qu return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -19587,20 +18230,20 @@ func NewDeleteSavedQueryTeamRequest(server string, teamName TeamName, queryID Qu return req, nil } -// NewGetSavedQueryTeamRequest generates requests for GetSavedQueryTeam -func NewGetSavedQueryTeamRequest(server string, teamName TeamName, queryID QueryID) (*http.Request, error) { +// NewGetSyncRunRequest generates requests for GetSyncRun +func NewGetSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19610,7 +18253,7 @@ func NewGetSavedQueryTeamRequest(server string, teamName TeamName, queryID Query return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19628,31 +18271,31 @@ func NewGetSavedQueryTeamRequest(server string, teamName TeamName, queryID Query return req, nil } -// NewUpdateQueryTeamRequest calls the generic UpdateQueryTeam builder with application/json body -func NewUpdateQueryTeamRequest(server string, teamName TeamName, queryID QueryID, body UpdateQueryTeamJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncRunRequest calls the generic UpdateSyncRun builder with application/json body +func NewUpdateSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateQueryTeamRequestWithBody(server, teamName, queryID, "application/json", bodyReader) + return NewUpdateSyncRunRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) } -// NewUpdateQueryTeamRequestWithBody generates requests for UpdateQueryTeam with any type of body -func NewUpdateQueryTeamRequestWithBody(server string, teamName TeamName, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncRunRequestWithBody generates requests for UpdateSyncRun with any type of body +func NewUpdateSyncRunRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19662,7 +18305,7 @@ func NewUpdateQueryTeamRequestWithBody(server string, teamName TeamName, queryID return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19682,20 +18325,20 @@ func NewUpdateQueryTeamRequestWithBody(server string, teamName TeamName, queryID return req, nil } -// NewDeleteAlertRequest generates requests for DeleteAlert -func NewDeleteAlertRequest(server string, teamName TeamName, queryID QueryID) (*http.Request, error) { +// NewGetSyncRunLogsLiveRequest generates requests for GetSyncRunLogsLive +func NewGetSyncRunLogsLiveRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19705,7 +18348,7 @@ func NewDeleteAlertRequest(server string, teamName TeamName, queryID QueryID) (* return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s/alert", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/live", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19715,28 +18358,65 @@ func NewDeleteAlertRequest(server string, teamName TeamName, queryID QueryID) (* return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if params != nil { + queryValues := queryURL.Query() + + if params.Table != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } + return req, nil } -// NewExecuteSavedQueryTeamRequest generates requests for ExecuteSavedQueryTeam -func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID QueryID, params *ExecuteSavedQueryTeamParams) (*http.Request, error) { +// NewGetSyncRunLogsQueryRequest generates requests for GetSyncRunLogsQuery +func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19746,7 +18426,7 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s/execute", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/query", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19759,38 +18439,6 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q if params != nil { queryValues := queryURL.Query() - if params.Selects != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.Filters != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { @@ -19807,25 +18455,9 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q } - if params.FilterIDs != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortBys != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19839,9 +18471,9 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q } - if params.SortDirections != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19855,9 +18487,9 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q } - if params.GroupBys != nil { + if params.Download != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19871,63 +18503,57 @@ func NewExecuteSavedQueryTeamRequest(server string, teamName TeamName, queryID Q } - if params.PerPage != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - } + if params != nil { - if params.Page != nil { + if params.Accept != nil { + var headerParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } } + req.Header.Set("Accept", headerParam0) } - queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), nil) + return req, nil +} + +// NewCreateSyncRunProgressRequest calls the generic CreateSyncRunProgress builder with application/json body +func NewCreateSyncRunProgressRequest(server string, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } - - return req, nil + bodyReader = bytes.NewReader(buf) + return NewCreateSyncRunProgressRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) } -// NewQueryListFiltersTeamRequest generates requests for QueryListFiltersTeam -func NewQueryListFiltersTeamRequest(server string, teamName TeamName, queryID QueryID, params *QueryListFiltersTeamParams) (*http.Request, error) { +// NewCreateSyncRunProgressRequestWithBody generates requests for CreateSyncRunProgress with any type of body +func NewCreateSyncRunProgressRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19937,7 +18563,7 @@ func NewQueryListFiltersTeamRequest(server string, teamName TeamName, queryID Qu return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s/filters", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/progress", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19947,93 +18573,30 @@ func NewQueryListFiltersTeamRequest(server string, teamName TeamName, queryID Qu return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterTags != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - return req, nil -} + req.Header.Add("Content-Type", contentType) -// NewQuerySaveFilterTeamRequest calls the generic QuerySaveFilterTeam builder with application/json body -func NewQuerySaveFilterTeamRequest(server string, teamName TeamName, queryID QueryID, body QuerySaveFilterTeamJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewQuerySaveFilterTeamRequestWithBody(server, teamName, queryID, "application/json", bodyReader) + return req, nil } -// NewQuerySaveFilterTeamRequestWithBody generates requests for QuerySaveFilterTeam with any type of body -func NewQuerySaveFilterTeamRequestWithBody(server string, teamName TeamName, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetSyncRunStatsRequest generates requests for GetSyncRunStats +func NewGetSyncRunStatsRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -20043,7 +18606,7 @@ func NewQuerySaveFilterTeamRequestWithBody(server string, teamName TeamName, que return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s/filters", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/stats", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20053,30 +18616,28 @@ func NewQuerySaveFilterTeamRequestWithBody(server string, teamName TeamName, que return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewQueryListFilterTagsTeamRequest generates requests for QueryListFilterTagsTeam -func NewQueryListFilterTagsTeamRequest(server string, teamName TeamName, queryID QueryID, params *QueryListFilterTagsTeamParams) (*http.Request, error) { +// NewGetSyncRunTablesRequest generates requests for GetSyncRunTables +func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -20086,7 +18647,7 @@ func NewQueryListFilterTagsTeamRequest(server string, teamName TeamName, queryID return nil, err } - operationPath := fmt.Sprintf("/teams/%s/queries/%s/filters/tags", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/tables", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20131,6 +18692,38 @@ func NewQueryListFilterTagsTeamRequest(server string, teamName TeamName, queryID } + if params.SyncRunTableSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncRunTableSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + queryURL.RawQuery = queryValues.Encode() } @@ -20142,23 +18735,16 @@ func NewQueryListFilterTagsTeamRequest(server string, teamName TeamName, queryID return req, nil } -// NewListAllRBACPermissionsRequest generates requests for ListAllRBACPermissions -func NewListAllRBACPermissionsRequest(server string, teamName TeamName, params *ListAllRBACPermissionsParams) (*http.Request, error) { +// NewListTablesRequest generates requests for ListTables +func NewListTablesRequest(server string, params *ListTablesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/permissions", pathParam0) + operationPath := fmt.Sprintf("/tables") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20203,25 +18789,42 @@ func NewListAllRBACPermissionsRequest(server string, teamName TeamName, params * } - if params.RBACPermissionSortBys != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACPermissionSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - } + return req, nil +} - if params.RBACPermissionSortDirections != nil { +// NewGetTablesDataRequest generates requests for GetTablesData +func NewGetTablesDataRequest(server string, params *GetTablesDataParams) (*http.Request, error) { + var err error - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACPermissionSortDirections); err != nil { + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tables/data") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20235,9 +18838,9 @@ func NewListAllRBACPermissionsRequest(server string, teamName TeamName, params * } - if params.SearchTerm != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20262,34 +18865,27 @@ func NewListAllRBACPermissionsRequest(server string, teamName TeamName, params * return req, nil } -// NewCreateRBACPermissionRequest calls the generic CreateRBACPermission builder with application/json body -func NewCreateRBACPermissionRequest(server string, teamName TeamName, body CreateRBACPermissionJSONRequestBody) (*http.Request, error) { +// NewTablesDataActionRequest calls the generic TablesDataAction builder with application/json body +func NewTablesDataActionRequest(server string, body TablesDataActionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateRBACPermissionRequestWithBody(server, teamName, "application/json", bodyReader) + return NewTablesDataActionRequestWithBody(server, "application/json", bodyReader) } -// NewCreateRBACPermissionRequestWithBody generates requests for CreateRBACPermission with any type of body -func NewCreateRBACPermissionRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewTablesDataActionRequestWithBody generates requests for TablesDataAction with any type of body +func NewTablesDataActionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/permissions", pathParam0) + operationPath := fmt.Sprintf("/tables/data") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20309,30 +18905,16 @@ func NewCreateRBACPermissionRequestWithBody(server string, teamName TeamName, co return req, nil } -// NewDeleteRBACPermissionRequest generates requests for DeleteRBACPermission -func NewDeleteRBACPermissionRequest(server string, teamName TeamName, rbacPermissionID RBACPermissionID) (*http.Request, error) { +// NewBatchTableSchemasRequest generates requests for BatchTableSchemas +func NewBatchTableSchemasRequest(server string, params *BatchTableSchemasParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/permissions/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/schemas") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20342,7 +18924,25 @@ func NewDeleteRBACPermissionRequest(server string, teamName TeamName, rbacPermis return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if params != nil { + queryValues := queryURL.Query() + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tables", runtime.ParamLocationQuery, params.Tables); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -20350,20 +18950,13 @@ func NewDeleteRBACPermissionRequest(server string, teamName TeamName, rbacPermis return req, nil } -// NewGetRBACPermissionRequest generates requests for GetRBACPermission -func NewGetRBACPermissionRequest(server string, teamName TeamName, rbacPermissionID RBACPermissionID) (*http.Request, error) { +// NewTableListColumnsRequest generates requests for TableListColumns +func NewTableListColumnsRequest(server string, tableName TableName, params *TableListColumnsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -20373,7 +18966,7 @@ func NewGetRBACPermissionRequest(server string, teamName TeamName, rbacPermissio return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/permissions/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/%s/columns", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20383,116 +18976,12 @@ func NewGetRBACPermissionRequest(server string, teamName TeamName, rbacPermissio return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} + if params.FilterMode != nil { -// NewUpdateRBACPermissionRequest calls the generic UpdateRBACPermission builder with application/json body -func NewUpdateRBACPermissionRequest(server string, teamName TeamName, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateRBACPermissionRequestWithBody(server, teamName, rbacPermissionID, "application/json", bodyReader) -} - -// NewUpdateRBACPermissionRequestWithBody generates requests for UpdateRBACPermission with any type of body -func NewUpdateRBACPermissionRequestWithBody(server string, teamName TeamName, rbacPermissionID RBACPermissionID, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/rbac/permissions/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListAllRBACRolesRequest generates requests for ListAllRBACRoles -func NewListAllRBACRolesRequest(server string, teamName TeamName, params *ListAllRBACRolesParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/rbac/roles", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20506,9 +18995,9 @@ func NewListAllRBACRolesRequest(server string, teamName TeamName, params *ListAl } - if params.RBACRoleSortBys != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACRoleSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20522,9 +19011,9 @@ func NewListAllRBACRolesRequest(server string, teamName TeamName, params *ListAl } - if params.RBACRoleSortDirections != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACRoleSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20538,9 +19027,9 @@ func NewListAllRBACRolesRequest(server string, teamName TeamName, params *ListAl } - if params.SearchTerm != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20565,67 +19054,20 @@ func NewListAllRBACRolesRequest(server string, teamName TeamName, params *ListAl return req, nil } -// NewCreateRBACRoleRequest calls the generic CreateRBACRole builder with application/json body -func NewCreateRBACRoleRequest(server string, teamName TeamName, body CreateRBACRoleJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateRBACRoleRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateRBACRoleRequestWithBody generates requests for CreateRBACRole with any type of body -func NewCreateRBACRoleRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/rbac/roles", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteRBACRoleRequest generates requests for DeleteRBACRole -func NewDeleteRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID RBACCustomRoleID) (*http.Request, error) { +// NewTableColumnListValuesRequest generates requests for TableColumnListValues +func NewTableColumnListValuesRequest(server string, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, rbacCustomRoleID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "column_name", runtime.ParamLocationPath, columnName) if err != nil { return nil, err } @@ -20635,7 +19077,7 @@ func NewDeleteRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/roles/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/%s/columns/%s/values", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20645,45 +19087,74 @@ func NewDeleteRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} + if params.FilterMode != nil { -// NewGetRBACRoleRequest generates requests for GetRBACRole -func NewGetRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID RBACCustomRoleID) (*http.Request, error) { - var err error + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam0 string + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if params.Filter != nil { - var pathParam1 string + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, rbacCustomRoleID) - if err != nil { - return nil, err - } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.Page != nil { - operationPath := fmt.Sprintf("/teams/%s/rbac/roles/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -20694,31 +19165,13 @@ func NewGetRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID RB return req, nil } -// NewUpdateRBACRoleRequest calls the generic UpdateRBACRole builder with application/json body -func NewUpdateRBACRoleRequest(server string, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, body UpdateRBACRoleJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateRBACRoleRequestWithBody(server, teamName, rbacCustomRoleID, "application/json", bodyReader) -} - -// NewUpdateRBACRoleRequestWithBody generates requests for UpdateRBACRole with any type of body -func NewUpdateRBACRoleRequestWithBody(server string, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, contentType string, body io.Reader) (*http.Request, error) { +// NewTableListRowsRequest generates requests for TableListRows +func NewTableListRowsRequest(server string, tableName TableName, params *TableListRowsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, rbacCustomRoleID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -20728,7 +19181,7 @@ func NewUpdateRBACRoleRequestWithBody(server string, teamName TeamName, rbacCust return nil, err } - operationPath := fmt.Sprintf("/teams/%s/rbac/roles/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/%s/data", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20738,48 +19191,60 @@ func NewUpdateRBACRoleRequestWithBody(server string, teamName TeamName, rbacCust return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.Selects != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListReportsRequest generates requests for ListReports -func NewListReportsRequest(server string, teamName TeamName, params *ListReportsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.FilterMode != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/teams/%s/reports", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.Filters != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.SearchTerm != nil { + if params.FilterIDs != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20793,9 +19258,9 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports } - if params.Visibility != nil { + if params.SortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "visibility", runtime.ParamLocationQuery, *params.Visibility); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20809,9 +19274,9 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports } - if params.PerPage != nil { + if params.SortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20825,9 +19290,9 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports } - if params.Page != nil { + if params.GroupBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20841,9 +19306,9 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports } - if params.ReportSortBys != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20857,9 +19322,9 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports } - if params.ReportSortDirections != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20884,24 +19349,20 @@ func NewListReportsRequest(server string, teamName TeamName, params *ListReports return req, nil } -// NewCreateReportRequest calls the generic CreateReport builder with application/json body -func NewCreateReportRequest(server string, teamName TeamName, body CreateReportJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewTableRowByIdRequest generates requests for TableRowById +func NewTableRowByIdRequest(server string, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateReportRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateReportRequestWithBody generates requests for CreateReport with any type of body -func NewCreateReportRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - var pathParam0 string + var pathParam1 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_row_id", runtime.ParamLocationPath, tableRowId) if err != nil { return nil, err } @@ -20911,7 +19372,7 @@ func NewCreateReportRequestWithBody(server string, teamName TeamName, contentTyp return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports", pathParam0) + operationPath := fmt.Sprintf("/tables/%s/data/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20921,23 +19382,75 @@ func NewCreateReportRequestWithBody(server string, teamName TeamName, contentTyp return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if params.FilterMode != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.FilterIDs != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListReportTemplatesRequest generates requests for ListReportTemplates -func NewListReportTemplatesRequest(server string, teamName TeamName, params *ListReportTemplatesParams) (*http.Request, error) { +// NewTableListFiltersRequest generates requests for TableListFilters +func NewTableListFiltersRequest(server string, tableName TableName, params *TableListFiltersParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -20947,7 +19460,7 @@ func NewListReportTemplatesRequest(server string, teamName TeamName, params *Lis return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/templates", pathParam0) + operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20960,22 +19473,6 @@ func NewListReportTemplatesRequest(server string, teamName TeamName, params *Lis if params != nil { queryValues := queryURL.Query() - if params.SearchTerm != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -21008,25 +19505,9 @@ func NewListReportTemplatesRequest(server string, teamName TeamName, params *Lis } - if params.ReportTemplateSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportTemplateSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.ReportTemplateSortDirections != nil { + if params.FilterTags != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportTemplateSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21051,24 +19532,24 @@ func NewListReportTemplatesRequest(server string, teamName TeamName, params *Lis return req, nil } -// NewCreateReportTemplateRequest calls the generic CreateReportTemplate builder with application/json body -func NewCreateReportTemplateRequest(server string, teamName TeamName, body CreateReportTemplateJSONRequestBody) (*http.Request, error) { +// NewTableSaveFilterRequest calls the generic TableSaveFilter builder with application/json body +func NewTableSaveFilterRequest(server string, tableName TableName, body TableSaveFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateReportTemplateRequestWithBody(server, teamName, "application/json", bodyReader) + return NewTableSaveFilterRequestWithBody(server, tableName, "application/json", bodyReader) } -// NewCreateReportTemplateRequestWithBody generates requests for CreateReportTemplate with any type of body -func NewCreateReportTemplateRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewTableSaveFilterRequestWithBody generates requests for TableSaveFilter with any type of body +func NewTableSaveFilterRequestWithBody(server string, tableName TableName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -21078,7 +19559,7 @@ func NewCreateReportTemplateRequestWithBody(server string, teamName TeamName, co return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/templates", pathParam0) + operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21098,20 +19579,13 @@ func NewCreateReportTemplateRequestWithBody(server string, teamName TeamName, co return req, nil } -// NewDeleteReportTemplateRequest generates requests for DeleteReportTemplate -func NewDeleteReportTemplateRequest(server string, teamName TeamName, templateId openapi_types.UUID) (*http.Request, error) { +// NewTableListFilterTagsRequest generates requests for TableListFilterTags +func NewTableListFilterTagsRequest(server string, tableName TableName, params *TableListFilterTagsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -21121,7 +19595,7 @@ func NewDeleteReportTemplateRequest(server string, teamName TeamName, templateId return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/templates/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/%s/filters/tags", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21131,7 +19605,45 @@ func NewDeleteReportTemplateRequest(server string, teamName TeamName, templateId return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -21139,20 +19651,13 @@ func NewDeleteReportTemplateRequest(server string, teamName TeamName, templateId return req, nil } -// NewGetReportTemplateRequest generates requests for GetReportTemplate -func NewGetReportTemplateRequest(server string, teamName TeamName, templateId openapi_types.UUID) (*http.Request, error) { +// NewTableSchemaRequest generates requests for TableSchema +func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -21162,7 +19667,7 @@ func NewGetReportTemplateRequest(server string, teamName TeamName, templateId op return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/templates/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/tables/%s/schema", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21180,41 +19685,16 @@ func NewGetReportTemplateRequest(server string, teamName TeamName, templateId op return req, nil } -// NewUpdateReportTemplateRequest calls the generic UpdateReportTemplate builder with application/json body -func NewUpdateReportTemplateRequest(server string, teamName TeamName, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateReportTemplateRequestWithBody(server, teamName, templateId, "application/json", bodyReader) -} - -// NewUpdateReportTemplateRequestWithBody generates requests for UpdateReportTemplate with any type of body -func NewUpdateReportTemplateRequestWithBody(server string, teamName TeamName, templateId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { +// NewListTeamsRequest generates requests for ListTeams +func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/templates/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/teams") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21224,50 +19704,45 @@ func NewUpdateReportTemplateRequestWithBody(server string, teamName TeamName, te return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteReportRequest generates requests for DeleteReport -func NewDeleteReportRequest(server string, teamName TeamName, reportId openapi_types.UUID) (*http.Request, error) { - var err error + if params != nil { + queryValues := queryURL.Query() - var pathParam0 string + if params.PerPage != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam1 string + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) - if err != nil { - return nil, err - } + if params.Page != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/teams/%s/reports/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -21275,8 +19750,8 @@ func NewDeleteReportRequest(server string, teamName TeamName, reportId openapi_t return req, nil } -// NewGetReportRequest generates requests for GetReport -func NewGetReportRequest(server string, teamName TeamName, reportId openapi_types.UUID) (*http.Request, error) { +// NewDownloadPluginAssetByTeamRequest generates requests for DownloadPluginAssetByTeam +func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams) (*http.Request, error) { var err error var pathParam0 string @@ -21288,59 +19763,35 @@ func NewGetReportRequest(server string, teamName TeamName, reportId openapi_type var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_team", runtime.ParamLocationPath, pluginTeam) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + var pathParam2 string - req, err := http.NewRequest("GET", queryURL.String(), nil) + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) if err != nil { return nil, err } - return req, nil -} + var pathParam3 string -// NewUpdateReportRequest calls the generic UpdateReport builder with application/json body -func NewUpdateReportRequest(server string, teamName TeamName, reportId openapi_types.UUID, body UpdateReportJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUpdateReportRequestWithBody(server, teamName, reportId, "application/json", bodyReader) -} -// NewUpdateReportRequestWithBody generates requests for UpdateReport with any type of body -func NewUpdateReportRequestWithBody(server string, teamName TeamName, reportId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string + var pathParam4 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) if err != nil { return nil, err } - var pathParam1 string + var pathParam5 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) + pathParam5, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) if err != nil { return nil, err } @@ -21350,7 +19801,7 @@ func NewUpdateReportRequestWithBody(server string, teamName TeamName, reportId o return nil, err } - operationPath := fmt.Sprintf("/teams/%s/reports/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/teams/%s/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4, pathParam5) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21360,65 +19811,42 @@ func NewUpdateReportRequestWithBody(server string, teamName TeamName, reportId o return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewCreateSyncDestinationTestConnectionRequest calls the generic CreateSyncDestinationTestConnection builder with application/json body -func NewCreateSyncDestinationTestConnectionRequest(server string, teamName TeamName, body CreateSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncDestinationTestConnectionRequestWithBody(server, teamName, "application/json", bodyReader) -} -// NewCreateSyncDestinationTestConnectionRequestWithBody generates requests for CreateSyncDestinationTestConnection with any type of body -func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error + if params != nil { - var pathParam0 string + if params.Accept != nil { + var headerParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + req.Header.Set("Accept", headerParam0) + } - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + return req, nil +} - req, err := http.NewRequest("POST", queryURL.String(), body) +// NewUpdateSyncTestConnectionForSyncDestinationTeamRequest calls the generic UpdateSyncTestConnectionForSyncDestinationTeam builder with application/json body +func NewUpdateSyncTestConnectionForSyncDestinationTeamRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } - - req.Header.Add("Content-Type", contentType) - - return req, nil + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server, teamName, syncDestinationTestConnectionID, "application/json", bodyReader) } -// NewGetSyncDestinationTestConnectionRequest generates requests for GetSyncDestinationTestConnection -func NewGetSyncDestinationTestConnectionRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestinationTeam with any type of body +func NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string @@ -21450,27 +19878,29 @@ func NewGetSyncDestinationTestConnectionRequest(server string, teamName TeamName return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewUpdateSyncTestConnectionForSyncDestinationRequest calls the generic UpdateSyncTestConnectionForSyncDestination builder with application/json body -func NewUpdateSyncTestConnectionForSyncDestinationRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceTeamRequest calls the generic UpdateSyncTestConnectionForSyncSourceTeam builder with application/json body +func NewUpdateSyncTestConnectionForSyncSourceTeamRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server, teamName, syncDestinationTestConnectionID, "application/json", bodyReader) + return NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server, teamName, syncSourceTestConnectionID, "application/json", bodyReader) } -// NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestination with any type of body -func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSourceTeam with any type of body +func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string @@ -21482,7 +19912,7 @@ func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -21492,7 +19922,7 @@ func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21512,64 +19942,19 @@ func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, return req, nil } -// NewGetSyncDestinationTestConnectionLogsRequest generates requests for GetSyncDestinationTestConnectionLogs -func NewGetSyncDestinationTestConnectionLogsRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s/logs", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) +// NewCreateSyncRunProgressTeamRequest calls the generic CreateSyncRunProgressTeam builder with application/json body +func NewCreateSyncRunProgressTeamRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } - - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } - - return req, nil + bodyReader = bytes.NewReader(buf) + return NewCreateSyncRunProgressTeamRequestWithBody(server, teamName, syncName, syncRunId, "application/json", bodyReader) } -// NewGetSyncDestinationTestConnectionLogsLiveRequest generates requests for GetSyncDestinationTestConnectionLogsLive -func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams) (*http.Request, error) { +// NewCreateSyncRunProgressTeamRequestWithBody generates requests for CreateSyncRunProgressTeam with any type of body +func NewCreateSyncRunProgressTeamRequestWithBody(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string @@ -21581,7 +19966,14 @@ func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, teamName var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -21591,7 +19983,7 @@ func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, teamName return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s/logs/live", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/progress", pathParam0, pathParam1, pathParam2) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21601,53 +19993,26 @@ func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, teamName return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } + req.Header.Add("Content-Type", contentType) return req, nil } -// NewGetSyncDestinationTestConnectionLogsQueryRequest generates requests for GetSyncDestinationTestConnectionLogsQuery -func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams) (*http.Request, error) { +// NewGetTeamUsageSummaryRequest generates requests for GetTeamUsageSummary +func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s/logs/query", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/usage-summary") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21660,9 +20025,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName if params != nil { queryValues := queryURL.Query() - if params.Filters != nil { + if params.Metrics != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21676,9 +20041,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName } - if params.PerPage != nil { + if params.Start != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21692,9 +20057,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName } - if params.Page != nil { + if params.End != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21708,9 +20073,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName } - if params.Download != nil { + if params.AggregationPeriod != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21732,85 +20097,16 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, teamName return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } - - return req, nil -} - -// NewPromoteSyncDestinationTestConnectionRequest calls the generic PromoteSyncDestinationTestConnection builder with application/json body -func NewPromoteSyncDestinationTestConnectionRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewPromoteSyncDestinationTestConnectionRequestWithBody(server, teamName, syncDestinationTestConnectionID, "application/json", bodyReader) -} - -// NewPromoteSyncDestinationTestConnectionRequestWithBody generates requests for PromoteSyncDestinationTestConnection with any type of body -func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s/promote", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListSyncDestinationsRequest generates requests for ListSyncDestinations -func NewListSyncDestinationsRequest(server string, teamName TeamName, params *ListSyncDestinationsParams) (*http.Request, error) { +// NewGetGroupedTeamUsageSummaryRequest generates requests for GetGroupedTeamUsageSummary +func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "group_by", runtime.ParamLocationPath, groupBy) if err != nil { return nil, err } @@ -21820,7 +20116,7 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations", pathParam0) + operationPath := fmt.Sprintf("/usage-summary/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21833,25 +20129,9 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { + if params.Metrics != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21865,9 +20145,9 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li } - if params.Filter != nil { + if params.Start != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21881,9 +20161,9 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li } - if params.SyncGenericSortBys != nil { + if params.End != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21897,9 +20177,9 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li } - if params.SyncSortDirections != nil { + if params.AggregationPeriod != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21924,30 +20204,16 @@ func NewListSyncDestinationsRequest(server string, teamName TeamName, params *Li return req, nil } -// NewDeleteSyncDestinationRequest generates requests for DeleteSyncDestination -func NewDeleteSyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName) (*http.Request, error) { +// NewGetCurrentUserRequest generates requests for GetCurrentUser +func NewGetCurrentUserRequest(server string) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21957,7 +20223,7 @@ func NewDeleteSyncDestinationRequest(server string, teamName TeamName, syncDesti return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -21965,30 +20231,27 @@ func NewDeleteSyncDestinationRequest(server string, teamName TeamName, syncDesti return req, nil } -// NewGetSyncDestinationRequest generates requests for GetSyncDestination -func NewGetSyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewUpdateCurrentUserRequest calls the generic UpdateCurrentUser builder with application/json body +func NewUpdateCurrentUserRequest(server string, body UpdateCurrentUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateCurrentUserRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } +// NewUpdateCurrentUserRequestWithBody generates requests for UpdateCurrentUser with any type of body +func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21998,49 +20261,37 @@ func NewGetSyncDestinationRequest(server string, teamName TeamName, syncDestinat return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewUpdateSyncDestinationRequest calls the generic UpdateSyncDestination builder with application/json body -func NewUpdateSyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody) (*http.Request, error) { +// NewSendAnonymousEventRequest calls the generic SendAnonymousEvent builder with application/json body +func NewSendAnonymousEventRequest(server string, body SendAnonymousEventJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncDestinationRequestWithBody(server, teamName, syncDestinationName, "application/json", bodyReader) + return NewSendAnonymousEventRequestWithBody(server, "application/json", bodyReader) } -// NewUpdateSyncDestinationRequestWithBody generates requests for UpdateSyncDestination with any type of body -func NewUpdateSyncDestinationRequestWithBody(server string, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { +// NewSendAnonymousEventRequestWithBody generates requests for SendAnonymousEvent with any type of body +func NewSendAnonymousEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/anon-event") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22050,7 +20301,7 @@ func NewUpdateSyncDestinationRequestWithBody(server string, teamName TeamName, s return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -22060,30 +20311,27 @@ func NewUpdateSyncDestinationRequestWithBody(server string, teamName TeamName, s return req, nil } -// NewMigrateSyncDestinationRequest generates requests for MigrateSyncDestination -func NewMigrateSyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewAuthenticateUserRequest calls the generic AuthenticateUser builder with application/json body +func NewAuthenticateUserRequest(server string, body AuthenticateUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewAuthenticateUserRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } +// NewAuthenticateUserRequestWithBody generates requests for AuthenticateUser with any type of body +func NewAuthenticateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s/migrate", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/authenticate") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22093,38 +20341,37 @@ func NewMigrateSyncDestinationRequest(server string, teamName TeamName, syncDest return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListSyncDestinationSyncsRequest generates requests for ListSyncDestinationSyncs -func NewListSyncDestinationSyncsRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewChangeUserPasswordRequest calls the generic ChangeUserPassword builder with application/json body +func NewChangeUserPasswordRequest(server string, body ChangeUserPasswordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewChangeUserPasswordRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } +// NewChangeUserPasswordRequestWithBody generates requests for ChangeUserPassword with any type of body +func NewChangeUserPasswordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s/syncs", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/change-password") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22134,147 +20381,37 @@ func NewListSyncDestinationSyncsRequest(server string, teamName TeamName, syncDe return nil, err } - if params != nil { - queryValues := queryURL.Query() + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.MigrationFilter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + req.Header.Add("Content-Type", contentType) return req, nil } -// NewGetTestConnectionForSyncDestinationRequest generates requests for GetTestConnectionForSyncDestination -func NewGetTestConnectionForSyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) +// NewUpdateCustomerRequest calls the generic UpdateCustomer builder with application/json body +func NewUpdateCustomerRequest(server string, body UpdateCustomerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateCustomerRequestWithBody(server, "application/json", bodyReader) +} - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) - if err != nil { - return nil, err - } +// NewUpdateCustomerRequestWithBody generates requests for UpdateCustomer with any type of body +func NewUpdateCustomerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destinations/%s/test-connections/%s", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/user/customer") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22284,42 +20421,37 @@ func NewGetTestConnectionForSyncDestinationRequest(server string, teamName TeamN return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewCreateSyncSourceTestConnectionRequest calls the generic CreateSyncSourceTestConnection builder with application/json body -func NewCreateSyncSourceTestConnectionRequest(server string, teamName TeamName, body CreateSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { +// NewSendUserEventRequest calls the generic SendUserEvent builder with application/json body +func NewSendUserEventRequest(server string, body SendUserEventJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateSyncSourceTestConnectionRequestWithBody(server, teamName, "application/json", bodyReader) + return NewSendUserEventRequestWithBody(server, "application/json", bodyReader) } -// NewCreateSyncSourceTestConnectionRequestWithBody generates requests for CreateSyncSourceTestConnection with any type of body -func NewCreateSyncSourceTestConnectionRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { +// NewSendUserEventRequestWithBody generates requests for SendUserEvent with any type of body +func NewSendUserEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections", pathParam0) + operationPath := fmt.Sprintf("/user/event") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22339,30 +20471,16 @@ func NewCreateSyncSourceTestConnectionRequestWithBody(server string, teamName Te return req, nil } -// NewGetSyncSourceTestConnectionRequest generates requests for GetSyncSourceTestConnection -func NewGetSyncSourceTestConnectionRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID) (*http.Request, error) { +// NewLogoutUserRequest generates requests for LogoutUser +func NewLogoutUserRequest(server string) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/login") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22372,7 +20490,7 @@ func NewGetSyncSourceTestConnectionRequest(server string, teamName TeamName, syn return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -22380,41 +20498,27 @@ func NewGetSyncSourceTestConnectionRequest(server string, teamName TeamName, syn return req, nil } -// NewUpdateSyncTestConnectionForSyncSourceRequest calls the generic UpdateSyncTestConnectionForSyncSource builder with application/json body -func NewUpdateSyncTestConnectionForSyncSourceRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody) (*http.Request, error) { +// NewLoginUserRequest calls the generic LoginUser builder with application/json body +func NewLoginUserRequest(server string, body LoginUserJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server, teamName, syncSourceTestConnectionID, "application/json", bodyReader) + return NewLoginUserRequestWithBody(server, "application/json", bodyReader) } -// NewUpdateSyncTestConnectionForSyncSourceRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSource with any type of body -func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewLoginUserRequestWithBody generates requests for LoginUser with any type of body +func NewLoginUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/login") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22424,7 +20528,7 @@ func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, team return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -22434,30 +20538,43 @@ func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, team return req, nil } -// NewGetSyncSourceTestConnectionLogsRequest generates requests for GetSyncSourceTestConnectionLogs -func NewGetSyncSourceTestConnectionLogsRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsParams) (*http.Request, error) { +// NewUserTOTPDeleteRequest generates requests for UserTOTPDelete +func NewUserTOTPDeleteRequest(server string) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam1 string + operationPath := fmt.Sprintf("/user/totp") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewUserTOTPSetupRequest generates requests for UserTOTPSetup +func NewUserTOTPSetupRequest(server string) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s/logs", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/totp") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22467,53 +20584,35 @@ func NewGetSyncSourceTestConnectionLogsRequest(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } - return req, nil } -// NewGetSyncSourceTestConnectionLogsLiveRequest generates requests for GetSyncSourceTestConnectionLogsLive -func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewUserTOTPVerifyRequest calls the generic UserTOTPVerify builder with application/json body +func NewUserTOTPVerifyRequest(server string, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUserTOTPVerifyRequestWithBody(server, params, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) - if err != nil { - return nil, err - } +// NewUserTOTPVerifyRequestWithBody generates requests for UserTOTPVerify with any type of body +func NewUserTOTPVerifyRequestWithBody(server string, params *UserTOTPVerifyParams, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s/logs/live", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/user/totp/verify") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22523,53 +20622,43 @@ func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, teamName TeamN return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + if params != nil { - if params.Accept != nil { - var headerParam0 string + if params.CqpSess != nil { + var cookieParam0 string - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + cookieParam0, err = runtime.StyleParamWithLocation("simple", true, "__cqp_sess", runtime.ParamLocationCookie, *params.CqpSess) if err != nil { return nil, err } - req.Header.Set("Accept", headerParam0) + cookie0 := &http.Cookie{ + Name: "__cqp_sess", + Value: cookieParam0, + } + req.AddCookie(cookie0) } - } - return req, nil } -// NewGetSyncSourceTestConnectionLogsQueryRequest generates requests for GetSyncSourceTestConnectionLogsQuery -func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams) (*http.Request, error) { +// NewListUsersRequest generates requests for ListUsers +func NewListUsersRequest(server string, params *ListUsersParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s/logs/query", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/users") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22582,9 +20671,9 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName Team if params != nil { queryValues := queryURL.Query() - if params.Filters != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -22598,9 +20687,9 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName Team } - if params.PerPage != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -22614,9 +20703,9 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName Team } - if params.Page != nil { + if params.UserSearch != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "user_search", runtime.ParamLocationQuery, *params.UserSearch); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -22630,9 +20719,9 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName Team } - if params.Download != nil { + if params.RoleId != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "role_id", runtime.ParamLocationQuery, *params.RoleId); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -22654,49 +20743,135 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, teamName Team return nil, err } - if params != nil { + return req, nil +} - if params.Accept != nil { - var headerParam0 string +// NewAddUserRequest calls the generic AddUser builder with application/json body +func NewAddUserRequest(server string, body AddUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewAddUserRequestWithBody(server, "application/json", bodyReader) +} - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +// NewAddUserRequestWithBody generates requests for AddUser with any type of body +func NewAddUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - req.Header.Set("Accept", headerParam0) - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/users") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewPromoteSyncSourceTestConnectionRequest calls the generic PromoteSyncSourceTestConnection builder with application/json body -func NewPromoteSyncSourceTestConnectionRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewDeleteUserRequest generates requests for DeleteUser +func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewPromoteSyncSourceTestConnectionRequestWithBody(server, teamName, syncSourceTestConnectionID, "application/json", bodyReader) + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/users/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil } -// NewPromoteSyncSourceTestConnectionRequestWithBody generates requests for PromoteSyncSourceTestConnection with any type of body -func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetUserRequest generates requests for GetUser +func NewGetUserRequest(server string, userID UserID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) if err != nil { return nil, err } - var pathParam1 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + operationPath := fmt.Sprintf("/users/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateUserRequest calls the generic UpdateUser builder with application/json body +func NewUpdateUserRequest(server string, userID UserID, body UpdateUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateUserRequestWithBody(server, userID, "application/json", bodyReader) +} + +// NewUpdateUserRequestWithBody generates requests for UpdateUser with any type of body +func NewUpdateUserRequestWithBody(server string, userID UserID, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) if err != nil { return nil, err } @@ -22706,7 +20881,7 @@ func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, teamName T return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s/promote", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/users/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22716,7 +20891,7 @@ func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, teamName T return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -22726,23 +20901,90 @@ func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, teamName T return req, nil } -// NewListSyncSourcesRequest generates requests for ListSyncSources -func NewListSyncSourcesRequest(server string, teamName TeamName, params *ListSyncSourcesParams) (*http.Request, error) { +// NewDeleteUserTOTPRequest generates requests for DeleteUserTOTP +func NewDeleteUserTOTPRequest(server string, userID UserID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/users/%s/totp", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewCreateV2SyncDestinationTestConnectionRequest calls the generic CreateV2SyncDestinationTestConnection builder with application/json body +func NewCreateV2SyncDestinationTestConnectionRequest(server string, body CreateV2SyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateV2SyncDestinationTestConnectionRequestWithBody generates requests for CreateV2SyncDestinationTestConnection with any type of body +func NewCreateV2SyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/v2/sync-destination-test-connections") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetV2SyncDestinationsRequest generates requests for GetV2SyncDestinations +func NewGetV2SyncDestinationsRequest(server string, params *GetV2SyncDestinationsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources", pathParam0) + operationPath := fmt.Sprintf("/v2/sync-destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22846,30 +21088,27 @@ func NewListSyncSourcesRequest(server string, teamName TeamName, params *ListSyn return req, nil } -// NewDeleteSyncSourceRequest generates requests for DeleteSyncSource -func NewDeleteSyncSourceRequest(server string, teamName TeamName, syncSourceName SyncSourceName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewCreateV2SyncDestinationRequest calls the generic CreateV2SyncDestination builder with application/json body +func NewCreateV2SyncDestinationRequest(server string, body CreateV2SyncDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncDestinationRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) - if err != nil { - return nil, err - } +// NewCreateV2SyncDestinationRequestWithBody generates requests for CreateV2SyncDestination with any type of body +func NewCreateV2SyncDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22879,28 +21118,57 @@ func NewDeleteSyncSourceRequest(server string, teamName TeamName, syncSourceName return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetSyncSourceRequest generates requests for GetSyncSource -func NewGetSyncSourceRequest(server string, teamName TeamName, syncSourceName SyncSourceName) (*http.Request, error) { +// NewDeleteV2SyncDestinationRequest generates requests for DeleteV2SyncDestination +func NewDeleteV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } - var pathParam1 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetV2SyncDestinationRequest generates requests for GetV2SyncDestination +func NewGetV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { + var err error + + var pathParam0 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -22910,7 +21178,7 @@ func NewGetSyncSourceRequest(server string, teamName TeamName, syncSourceName Sy return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22928,31 +21196,24 @@ func NewGetSyncSourceRequest(server string, teamName TeamName, syncSourceName Sy return req, nil } -// NewUpdateSyncSourceRequest calls the generic UpdateSyncSource builder with application/json body -func NewUpdateSyncSourceRequest(server string, teamName TeamName, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody) (*http.Request, error) { +// NewPatchV2SyncDestinationRequest calls the generic PatchV2SyncDestination builder with application/json body +func NewPatchV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncSourceRequestWithBody(server, teamName, syncSourceName, "application/json", bodyReader) + return NewPatchV2SyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) } -// NewUpdateSyncSourceRequestWithBody generates requests for UpdateSyncSource with any type of body -func NewUpdateSyncSourceRequestWithBody(server string, teamName TeamName, syncSourceName SyncSourceName, contentType string, body io.Reader) (*http.Request, error) { +// NewPatchV2SyncDestinationRequestWithBody generates requests for PatchV2SyncDestination with any type of body +func NewPatchV2SyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -22962,7 +21223,7 @@ func NewUpdateSyncSourceRequestWithBody(server string, teamName TeamName, syncSo return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -22982,30 +21243,27 @@ func NewUpdateSyncSourceRequestWithBody(server string, teamName TeamName, syncSo return req, nil } -// NewMigrateSyncSourceRequest generates requests for MigrateSyncSource -func NewMigrateSyncSourceRequest(server string, teamName TeamName, syncSourceName SyncSourceName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewCreateV2SyncIntegrationTestConnectionRequest calls the generic CreateV2SyncIntegrationTestConnection builder with application/json body +func NewCreateV2SyncIntegrationTestConnectionRequest(server string, body CreateV2SyncIntegrationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) - if err != nil { - return nil, err - } +// NewCreateV2SyncIntegrationTestConnectionRequestWithBody generates requests for CreateV2SyncIntegrationTestConnection with any type of body +func NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s/migrate", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-integration-test-connections") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23015,38 +21273,26 @@ func NewMigrateSyncSourceRequest(server string, teamName TeamName, syncSourceNam return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListSyncSourceSyncsRequest generates requests for ListSyncSourceSyncs -func NewListSyncSourceSyncsRequest(server string, teamName TeamName, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams) (*http.Request, error) { +// NewListV2SyncIntegrationsRequest generates requests for ListV2SyncIntegrations +func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrationsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s/syncs", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-integrations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23139,22 +21385,6 @@ func NewListSyncSourceSyncsRequest(server string, teamName TeamName, syncSourceN } - if params.MigrationFilter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - queryURL.RawQuery = queryValues.Encode() } @@ -23166,37 +21396,27 @@ func NewListSyncSourceSyncsRequest(server string, teamName TeamName, syncSourceN return req, nil } -// NewGetTestConnectionForSyncSourceRequest generates requests for GetTestConnectionForSyncSource -func NewGetTestConnectionForSyncSourceRequest(server string, teamName TeamName, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) +// NewCreateV2SyncIntegrationRequest calls the generic CreateV2SyncIntegration builder with application/json body +func NewCreateV2SyncIntegrationRequest(server string, body CreateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncIntegrationRequestWithBody(server, "application/json", bodyReader) +} - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) - if err != nil { - return nil, err - } +// NewCreateV2SyncIntegrationRequestWithBody generates requests for CreateV2SyncIntegration with any type of body +func NewCreateV2SyncIntegrationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-sources/%s/test-connections/%s", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/v2/sync-integrations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23206,21 +21426,23 @@ func NewGetTestConnectionForSyncSourceRequest(server string, teamName TeamName, return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListSyncTransformersRequest generates requests for ListSyncTransformers -func NewListSyncTransformersRequest(server string, teamName TeamName, params *ListSyncTransformersParams) (*http.Request, error) { +// NewDeleteV2SyncIntegrationRequest generates requests for DeleteV2SyncIntegration +func NewDeleteV2SyncIntegrationRequest(server string, syncName SyncName, params *DeleteV2SyncIntegrationParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -23230,7 +21452,7 @@ func NewListSyncTransformersRequest(server string, teamName TeamName, params *Li return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-transformers", pathParam0) + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23243,73 +21465,9 @@ func NewListSyncTransformersRequest(server string, teamName TeamName, params *Li if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncGenericSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { + if params.DeleteData != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "delete_data", runtime.ParamLocationQuery, *params.DeleteData); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -23326,47 +21484,6 @@ func NewListSyncTransformersRequest(server string, teamName TeamName, params *Li queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewDeleteSyncTransformerRequest generates requests for DeleteSyncTransformer -func NewDeleteSyncTransformerRequest(server string, teamName TeamName, syncTransformerName SyncTransformerName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/sync-transformers/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err @@ -23375,20 +21492,13 @@ func NewDeleteSyncTransformerRequest(server string, teamName TeamName, syncTrans return req, nil } -// NewGetSyncTransformerRequest generates requests for GetSyncTransformer -func NewGetSyncTransformerRequest(server string, teamName TeamName, syncTransformerName SyncTransformerName) (*http.Request, error) { +// NewGetV2SyncIntegrationRequest generates requests for GetV2SyncIntegration +func NewGetV2SyncIntegrationRequest(server string, syncName SyncName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -23398,7 +21508,7 @@ func NewGetSyncTransformerRequest(server string, teamName TeamName, syncTransfor return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-transformers/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23416,31 +21526,24 @@ func NewGetSyncTransformerRequest(server string, teamName TeamName, syncTransfor return req, nil } -// NewUpdateSyncTransformerRequest calls the generic UpdateSyncTransformer builder with application/json body -func NewUpdateSyncTransformerRequest(server string, teamName TeamName, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody) (*http.Request, error) { +// NewUpdateV2SyncIntegrationRequest calls the generic UpdateV2SyncIntegration builder with application/json body +func NewUpdateV2SyncIntegrationRequest(server string, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTransformerRequestWithBody(server, teamName, syncTransformerName, "application/json", bodyReader) + return NewUpdateV2SyncIntegrationRequestWithBody(server, syncName, "application/json", bodyReader) } -// NewUpdateSyncTransformerRequestWithBody generates requests for UpdateSyncTransformer with any type of body -func NewUpdateSyncTransformerRequestWithBody(server string, teamName TeamName, syncTransformerName SyncTransformerName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateV2SyncIntegrationRequestWithBody generates requests for UpdateV2SyncIntegration with any type of body +func NewUpdateV2SyncIntegrationRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -23450,7 +21553,7 @@ func NewUpdateSyncTransformerRequestWithBody(server string, teamName TeamName, s return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-transformers/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -23470,18901 +21573,8590 @@ func NewUpdateSyncTransformerRequestWithBody(server string, teamName TeamName, s return req, nil } -// NewListSyncTransformerSyncDestinationsRequest generates requests for ListSyncTransformerSyncDestinations -func NewListSyncTransformerSyncDestinationsRequest(server string, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error { + for _, r := range c.RequestEditors { + if err := r(ctx, req); err != nil { + return err + } + } + for _, r := range additionalEditors { + if err := r(ctx, req); err != nil { + return err + } } + return nil +} - var pathParam1 string +// ClientWithResponses builds on ClientInterface to offer response payloads +type ClientWithResponses struct { + ClientInterface +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) +// NewClientWithResponses creates a new ClientWithResponses, which wraps +// Client with return type handling +func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error) { + client, err := NewClient(server, opts...) if err != nil { return nil, err } + return &ClientWithResponses{client}, nil +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// WithBaseURL overrides the baseURL. +func WithBaseURL(baseURL string) ClientOption { + return func(c *Client) error { + newBaseURL, err := url.Parse(baseURL) + if err != nil { + return err + } + c.Server = newBaseURL.String() + return nil } +} - operationPath := fmt.Sprintf("/teams/%s/sync-transformers/%s/sync-destinations", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } +// ClientWithResponsesInterface is the interface specification for the client with responses above. +type ClientWithResponsesInterface interface { + // IndexWithResponse request + IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // ListAllAlertsWithResponse request + ListAllAlertsWithResponse(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) - if params != nil { - queryValues := queryURL.Query() + // TestUnsavedAlertWithBodyWithResponse request with any body + TestUnsavedAlertWithBodyWithResponse(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) - if params.PerPage != nil { + TestUnsavedAlertWithResponse(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // ListAPIKeysWithResponse request + ListAPIKeysWithResponse(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*ListAPIKeysResponse, error) - } + // CreateAPIKeyWithBodyWithResponse request with any body + CreateAPIKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) - if params.Page != nil { + CreateAPIKeyWithResponse(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // DeleteAPIKeyWithResponse request + DeleteAPIKeyWithResponse(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteAPIKeyResponse, error) - } + // ListAuditLogsWithResponse request + ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + // GetAuditLogWithResponse request + GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // GetSAMLWithResponse request + GetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSAMLResponse, error) - return req, nil -} + // UpdateSAMLWithBodyWithResponse request with any body + UpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) -// NewListSyncTransformerSyncsRequest generates requests for ListSyncTransformerSyncs -func NewListSyncTransformerSyncsRequest(server string, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams) (*http.Request, error) { - var err error + UpdateSAMLWithResponse(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) - var pathParam0 string + // CreateConversationWithBodyWithResponse request with any body + CreateConversationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + CreateConversationWithResponse(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) - var pathParam1 string + // GetConversationWithResponse request + GetConversationWithResponse(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) - if err != nil { - return nil, err - } + // SendMessageWithBodyWithResponse request with any body + SendMessageWithBodyWithResponse(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + SendMessageWithResponse(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) - operationPath := fmt.Sprintf("/teams/%s/sync-transformers/%s/syncs", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // ListAllCustomColumnsWithResponse request + ListAllCustomColumnsWithResponse(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // SaveCustomColumnWithBodyWithResponse request with any body + SaveCustomColumnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) - if params != nil { - queryValues := queryURL.Query() + SaveCustomColumnWithResponse(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) - if params.PerPage != nil { + // DeleteCustomColumnWithResponse request + DeleteCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetCustomColumnWithResponse request + GetCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) - } + // UpdateCustomColumnWithBodyWithResponse request with any body + UpdateCustomColumnWithBodyWithResponse(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) - if params.Page != nil { + UpdateCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // ListFiltersWithResponse request + ListFiltersWithResponse(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*ListFiltersResponse, error) - } + // ListFilterTagsWithResponse request + ListFilterTagsWithResponse(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*ListFilterTagsResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + // DeleteFilterWithResponse request + DeleteFilterWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // GetFilterByIDWithResponse request + GetFilterByIDWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDResponse, error) - return req, nil -} + // UpdateFilterWithBodyWithResponse request with any body + UpdateFilterWithBodyWithResponse(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) -// NewListSyncUpgradesRequest generates requests for ListSyncUpgrades -func NewListSyncUpgradesRequest(server string, teamName TeamName, params *ListSyncUpgradesParams) (*http.Request, error) { - var err error + UpdateFilterWithResponse(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) - var pathParam0 string + // HealthCheckWithResponse request + HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // HealthCheckHeadWithResponse request + HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // ListNotificationsWithResponse request + ListNotificationsWithResponse(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*ListNotificationsResponse, error) - operationPath := fmt.Sprintf("/teams/%s/sync-upgrades", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // DeleteNotificationDestinationWithResponse request + DeleteNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // GetNotificationDestinationWithResponse request + GetNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) - if params != nil { - queryValues := queryURL.Query() + // UpdateNotificationDestinationWithBodyWithResponse request with any body + UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) - if params.PerPage != nil { + UpdateNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetNotificationDestinationAlertsWithResponse request + GetNotificationDestinationAlertsWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) - } + // TestNotificationDestinationWithResponse request + TestNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) - if params.Page != nil { + // ListAllNotificationDestinationsWithResponse request + ListAllNotificationDestinationsWithResponse(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // CreateNotificationDestinationWithBodyWithResponse request with any body + CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) - } + CreateNotificationDestinationWithResponse(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) - if params.SyncUpgradesSortBys != nil { + // TestUnsavedNotificationDestinationWithBodyWithResponse request with any body + TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncUpgradesSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + TestUnsavedNotificationDestinationWithResponse(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) - } + // CreateAWSOnboardingWithBodyWithResponse request with any body + CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) - if params.SyncSortDirections != nil { + CreateAWSOnboardingWithResponse(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetAWSOnboardingWithResponse request + GetAWSOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) - } + // GetAWSAccountsInRootWithResponse request + GetAWSAccountsInRootWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) - if params.Path != nil { + // ProvisionOnboardingConfigurationWithBodyWithResponse request with any body + ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "path", runtime.ParamLocationQuery, *params.Path); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + ProvisionOnboardingConfigurationWithResponse(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) - } + // GetAWSAccountsInParentWithResponse request + GetAWSAccountsInParentWithResponse(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) - if params.Kind != nil { + // NotifyOnboardingWithBodyWithResponse request with any body + NotifyOnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "kind", runtime.ParamLocationQuery, *params.Kind); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + NotifyOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) - } + // GetOpenAPIJSONWithResponse request + GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) - if params.PlatformVersion != nil { + // GetPlatformInfoWithResponse request + GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "platform_version", runtime.ParamLocationQuery, *params.PlatformVersion); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // ListPlatformVersionsWithResponse request + ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) - } + // ListPluginsWithResponse request + ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + // GetPluginWithResponse request + GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // ListPluginVersionsWithResponse request + ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) - return req, nil -} + // GetPluginVersionWithResponse request + GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) -// NewListSyncsRequest generates requests for ListSyncs -func NewListSyncsRequest(server string, teamName TeamName, params *ListSyncsParams) (*http.Request, error) { - var err error + // DownloadPluginAssetWithResponse request + DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) - var pathParam0 string + // ListPluginVersionTablesWithResponse request + ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // GetPluginVersionTableWithResponse request + GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // ListPoliciesWithResponse request + ListPoliciesWithResponse(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // CreatePolicyWithBodyWithResponse request with any body + CreatePolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + CreatePolicyWithResponse(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) - if params != nil { - queryValues := queryURL.Query() + // GetPolicyMetricsWithResponse request + GetPolicyMetricsWithResponse(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*GetPolicyMetricsResponse, error) - if params.PerPage != nil { + // GetViolationsByDomainWithResponse request + GetViolationsByDomainWithResponse(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*GetViolationsByDomainResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetViolationsHistoryWithResponse request + GetViolationsHistoryWithResponse(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetViolationsHistoryResponse, error) - } + // DeletePolicyWithResponse request + DeletePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) - if params.Page != nil { + // GetPolicyWithResponse request + GetPolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // UpdatePolicyWithBodyWithResponse request with any body + UpdatePolicyWithBodyWithResponse(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) - } + UpdatePolicyWithResponse(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) - if params.SyncSortBys != nil { + // TogglePolicyWithResponse request + TogglePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetPolicyViolationsWithResponse request + GetPolicyViolationsWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsResponse, error) - } + // GetPolicyViolationsHistoryWithResponse request + GetPolicyViolationsHistoryWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) - if params.SyncSortDirections != nil { + // ListPolicyGroupsWithResponse request + ListPolicyGroupsWithResponse(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*ListPolicyGroupsResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // CreatePolicyGroupWithBodyWithResponse request with any body + CreatePolicyGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) - } + CreatePolicyGroupWithResponse(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) - if params.Filter != nil { + // DeletePolicyGroupWithResponse request + DeletePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*DeletePolicyGroupResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // ListPoliciesInGroupWithResponse request + ListPoliciesInGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*ListPoliciesInGroupResponse, error) - } + // UpdatePolicyGroupWithBodyWithResponse request with any body + UpdatePolicyGroupWithBodyWithResponse(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) - if params.MigrationFilter != nil { + UpdatePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // ListAllQueriesWithResponse request + ListAllQueriesWithResponse(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*ListAllQueriesResponse, error) - } + // ExecuteAdHocQueryWithBodyWithResponse request with any body + ExecuteAdHocQueryWithBodyWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + ExecuteAdHocQueryWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // SaveQueryWithBodyWithResponse request with any body + SaveQueryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) - return req, nil -} + SaveQueryWithResponse(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) -// NewCreateSyncRequest calls the generic CreateSync builder with application/json body -func NewCreateSyncRequest(server string, teamName TeamName, body CreateSyncJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncRequestWithBody(server, teamName, "application/json", bodyReader) -} + // ListQueryTagsWithResponse request + ListQueryTagsWithResponse(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*ListQueryTagsResponse, error) -// NewCreateSyncRequestWithBody generates requests for CreateSync with any type of body -func NewCreateSyncRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error + // DeleteSavedQueryWithResponse request + DeleteSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryResponse, error) - var pathParam0 string + // GetSavedQueryWithResponse request + GetSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // UpdateQueryWithBodyWithResponse request with any body + UpdateQueryWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + UpdateQueryWithResponse(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // DeleteAlertWithResponse request + DeleteAlertWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // ExecuteSavedQueryWithResponse request + ExecuteSavedQueryWithResponse(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryResponse, error) - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + // QueryListFiltersWithResponse request + QueryListFiltersWithResponse(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*QueryListFiltersResponse, error) - req.Header.Add("Content-Type", contentType) + // QuerySaveFilterWithBodyWithResponse request with any body + QuerySaveFilterWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) - return req, nil -} + QuerySaveFilterWithResponse(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) -// NewGetTestConnectionConnectorCredentialsRequest generates requests for GetTestConnectionConnectorCredentials -func NewGetTestConnectionConnectorCredentialsRequest(server string, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID) (*http.Request, error) { - var err error + // QueryListFilterTagsWithResponse request + QueryListFilterTagsWithResponse(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsResponse, error) - var pathParam0 string + // ListAllRBACPermissionsWithResponse request + ListAllRBACPermissionsWithResponse(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // CreateRBACPermissionWithBodyWithResponse request with any body + CreateRBACPermissionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) - var pathParam1 string + CreateRBACPermissionWithResponse(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) - if err != nil { - return nil, err - } + // DeleteRBACPermissionWithResponse request + DeleteRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) - var pathParam2 string + // GetRBACPermissionWithResponse request + GetRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } + // UpdateRBACPermissionWithBodyWithResponse request with any body + UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + UpdateRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/test-connections/%s/connector/%s/credentials", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // ListAllRBACRolesWithResponse request + ListAllRBACRolesWithResponse(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // CreateRBACRoleWithBodyWithResponse request with any body + CreateRBACRoleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + CreateRBACRoleWithResponse(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) - return req, nil -} + // DeleteRBACRoleWithResponse request + DeleteRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) -// NewGetTestConnectionConnectorIdentityRequest generates requests for GetTestConnectionConnectorIdentity -func NewGetTestConnectionConnectorIdentityRequest(server string, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID) (*http.Request, error) { - var err error + // GetRBACRoleWithResponse request + GetRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) - var pathParam0 string + // UpdateRBACRoleWithBodyWithResponse request with any body + UpdateRBACRoleWithBodyWithResponse(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + UpdateRBACRoleWithResponse(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) - var pathParam1 string + // ListReportsWithResponse request + ListReportsWithResponse(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) - if err != nil { - return nil, err - } + // CreateReportWithBodyWithResponse request with any body + CreateReportWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) - var pathParam2 string + CreateReportWithResponse(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } + // ListReportTemplatesWithResponse request + ListReportTemplatesWithResponse(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // CreateReportTemplateWithBodyWithResponse request with any body + CreateReportTemplateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/test-connections/%s/connector/%s/identity", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + CreateReportTemplateWithResponse(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // DeleteReportTemplateWithResponse request + DeleteReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // GetReportTemplateWithResponse request + GetReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) - return req, nil -} + // UpdateReportTemplateWithBodyWithResponse request with any body + UpdateReportTemplateWithBodyWithResponse(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) -// NewDeleteSyncRequest generates requests for DeleteSync -func NewDeleteSyncRequest(server string, teamName TeamName, syncName SyncName) (*http.Request, error) { - var err error + UpdateReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) - var pathParam0 string + // DeleteReportWithResponse request + DeleteReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // GetReportWithResponse request + GetReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) - var pathParam1 string + // UpdateReportWithBodyWithResponse request with any body + UpdateReportWithBodyWithResponse(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + UpdateReportWithResponse(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // GetSettingsWithResponse request + GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // UpdateSettingsWithBodyWithResponse request with any body + UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } + // GetDataSettingsWithResponse request + GetDataSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataSettingsResponse, error) - return req, nil -} + // UpdateDataSettingsWithBodyWithResponse request with any body + UpdateDataSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) -// NewGetSyncRequest generates requests for GetSync -func NewGetSyncRequest(server string, teamName TeamName, syncName SyncName) (*http.Request, error) { - var err error + UpdateDataSettingsWithResponse(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) - var pathParam0 string + // CreateSlackConnectionWithBodyWithResponse request with any body + CreateSlackConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + CreateSlackConnectionWithResponse(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) - var pathParam1 string + // ListSlackChannelsWithResponse request + ListSlackChannelsWithResponse(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*ListSlackChannelsResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // CreateSyncDestinationTestConnectionWithBodyWithResponse request with any body + CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // GetSyncDestinationTestConnectionWithResponse request + GetSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) - return req, nil -} + // GetSyncDestinationTestConnectionLogsLiveWithResponse request + GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) -// NewUpdateSyncRequest calls the generic UpdateSync builder with application/json body -func NewUpdateSyncRequest(server string, teamName TeamName, syncName SyncName, body UpdateSyncJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSyncRequestWithBody(server, teamName, syncName, "application/json", bodyReader) -} + // GetSyncDestinationTestConnectionLogsQueryWithResponse request + GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) -// NewUpdateSyncRequestWithBody generates requests for UpdateSync with any type of body -func NewUpdateSyncRequestWithBody(server string, teamName TeamName, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { - var err error + // PromoteSyncDestinationTestConnectionWithBodyWithResponse request with any body + PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) - var pathParam0 string + PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // ListSyncDestinationsWithResponse request + ListSyncDestinationsWithResponse(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) - var pathParam1 string + // DeleteSyncDestinationWithResponse request + DeleteSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // GetSyncDestinationWithResponse request + GetSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // UpdateSyncDestinationWithBodyWithResponse request with any body + UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + UpdateSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // ListSyncDestinationSyncsWithResponse request + ListSyncDestinationSyncsWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + // GetTestConnectionForSyncDestinationWithResponse request + GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) - req.Header.Add("Content-Type", contentType) + // CreateSyncSourceTestConnectionWithBodyWithResponse request with any body + CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) - return req, nil -} + CreateSyncSourceTestConnectionWithResponse(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) -// NewListSyncRunsRequest generates requests for ListSyncRuns -func NewListSyncRunsRequest(server string, teamName TeamName, syncName SyncName, params *ListSyncRunsParams) (*http.Request, error) { - var err error + // GetSyncSourceTestConnectionWithResponse request + GetSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) - var pathParam0 string + // UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) - var pathParam1 string + // GetSyncSourceTestConnectionLogsLiveWithResponse request + GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // GetSyncSourceTestConnectionLogsQueryWithResponse request + GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // PromoteSyncSourceTestConnectionWithBodyWithResponse request with any body + PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // ListSyncSourcesWithResponse request + ListSyncSourcesWithResponse(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) - if params != nil { - queryValues := queryURL.Query() + // DeleteSyncSourceWithResponse request + DeleteSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) - if params.MigrationFilter != nil { + // GetSyncSourceWithResponse request + GetSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // UpdateSyncSourceWithBodyWithResponse request with any body + UpdateSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) - } + UpdateSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) - if params.PerPage != nil { + // ListSyncSourceSyncsWithResponse request + ListSyncSourceSyncsWithResponse(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetTestConnectionForSyncSourceWithResponse request + GetTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) - } + // ListSyncTransformersWithResponse request + ListSyncTransformersWithResponse(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) - if params.Page != nil { + // DeleteSyncTransformerWithResponse request + DeleteSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + // GetSyncTransformerWithResponse request + GetSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) - } + // UpdateSyncTransformerWithBodyWithResponse request with any body + UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + UpdateSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // ListSyncTransformerSyncDestinationsWithResponse request + ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) - return req, nil -} + // ListSyncTransformerSyncsWithResponse request + ListSyncTransformerSyncsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) -// NewCreateSyncRunRequest generates requests for CreateSyncRun -func NewCreateSyncRunRequest(server string, teamName TeamName, syncName SyncName) (*http.Request, error) { - var err error + // ListSyncUpgradesWithResponse request + ListSyncUpgradesWithResponse(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) - var pathParam0 string + // ListSyncsWithResponse request + ListSyncsWithResponse(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // CreateSyncWithBodyWithResponse request with any body + CreateSyncWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) - var pathParam1 string + CreateSyncWithResponse(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // DeleteSyncWithResponse request + DeleteSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // GetSyncWithResponse request + GetSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // UpdateSyncWithBodyWithResponse request with any body + UpdateSyncWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), nil) - if err != nil { - return nil, err - } + UpdateSyncWithResponse(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) - return req, nil -} + // ListSyncRunsWithResponse request + ListSyncRunsWithResponse(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) -// NewGetSyncRunRequest generates requests for GetSyncRun -func NewGetSyncRunRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { - var err error + // CreateSyncRunWithResponse request + CreateSyncRunWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) - var pathParam0 string + // GetSyncRunWithResponse request + GetSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // UpdateSyncRunWithBodyWithResponse request with any body + UpdateSyncRunWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) - var pathParam1 string + UpdateSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // GetSyncRunLogsLiveWithResponse request + GetSyncRunLogsLiveWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) - var pathParam2 string + // GetSyncRunLogsQueryWithResponse request + GetSyncRunLogsQueryWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + // CreateSyncRunProgressWithBodyWithResponse request with any body + CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + CreateSyncRunProgressWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // GetSyncRunStatsWithResponse request + GetSyncRunStatsWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // GetSyncRunTablesWithResponse request + GetSyncRunTablesWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // ListTablesWithResponse request + ListTablesWithResponse(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*ListTablesResponse, error) - return req, nil -} + // GetTablesDataWithResponse request + GetTablesDataWithResponse(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*GetTablesDataResponse, error) -// NewUpdateSyncRunRequest calls the generic UpdateSyncRun builder with application/json body -func NewUpdateSyncRunRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSyncRunRequestWithBody(server, teamName, syncName, syncRunId, "application/json", bodyReader) -} + // TablesDataActionWithBodyWithResponse request with any body + TablesDataActionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) -// NewUpdateSyncRunRequestWithBody generates requests for UpdateSyncRun with any type of body -func NewUpdateSyncRunRequestWithBody(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { - var err error + TablesDataActionWithResponse(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) - var pathParam0 string + // BatchTableSchemasWithResponse request + BatchTableSchemasWithResponse(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // TableListColumnsWithResponse request + TableListColumnsWithResponse(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*TableListColumnsResponse, error) - var pathParam1 string + // TableColumnListValuesWithResponse request + TableColumnListValuesWithResponse(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // TableListRowsWithResponse request + TableListRowsWithResponse(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*TableListRowsResponse, error) - var pathParam2 string + // TableRowByIdWithResponse request + TableRowByIdWithResponse(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*TableRowByIdResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + // TableListFiltersWithResponse request + TableListFiltersWithResponse(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*TableListFiltersResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // TableSaveFilterWithBodyWithResponse request with any body + TableSaveFilterWithBodyWithResponse(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + TableSaveFilterWithResponse(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // TableListFilterTagsWithResponse request + TableListFilterTagsWithResponse(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsResponse, error) - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + // TableSchemaWithResponse request + TableSchemaWithResponse(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaResponse, error) - req.Header.Add("Content-Type", contentType) + // ListTeamsWithResponse request + ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) - return req, nil -} + // DownloadPluginAssetByTeamWithResponse request + DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) -// NewGetSyncRunConnectorCredentialsRequest generates requests for GetSyncRunConnectorCredentials -func NewGetSyncRunConnectorCredentialsRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID) (*http.Request, error) { - var err error + // UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) - var pathParam0 string + UpdateSyncTestConnectionForSyncDestinationTeamWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) - var pathParam1 string + UpdateSyncTestConnectionForSyncSourceTeamWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // CreateSyncRunProgressTeamWithBodyWithResponse request with any body + CreateSyncRunProgressTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) - var pathParam2 string + CreateSyncRunProgressTeamWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + // GetTeamUsageSummaryWithResponse request + GetTeamUsageSummaryWithResponse(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) - var pathParam3 string + // GetGroupedTeamUsageSummaryWithResponse request + GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } + // GetCurrentUserWithResponse request + GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // UpdateCurrentUserWithBodyWithResponse request with any body + UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/connector/%s/credentials", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // SendAnonymousEventWithBodyWithResponse request with any body + SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) - return req, nil -} + // AuthenticateUserWithBodyWithResponse request with any body + AuthenticateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) -// NewGetSyncRunConnectorIdentityRequest generates requests for GetSyncRunConnectorIdentity -func NewGetSyncRunConnectorIdentityRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID) (*http.Request, error) { - var err error + AuthenticateUserWithResponse(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) - var pathParam0 string + // ChangeUserPasswordWithBodyWithResponse request with any body + ChangeUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + ChangeUserPasswordWithResponse(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) - var pathParam1 string + // UpdateCustomerWithBodyWithResponse request with any body + UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) - var pathParam2 string + // SendUserEventWithBodyWithResponse request with any body + SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) - var pathParam3 string + // LogoutUserWithResponse request + LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "connector_id", runtime.ParamLocationPath, connectorID) - if err != nil { - return nil, err - } + // LoginUserWithBodyWithResponse request with any body + LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/connector/%s/identity", pathParam0, pathParam1, pathParam2, pathParam3) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // UserTOTPDeleteWithResponse request + UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + // UserTOTPSetupWithResponse request + UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // UserTOTPVerifyWithBodyWithResponse request with any body + UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) - return req, nil -} + UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) -// NewGetSyncRunLogsRequest generates requests for GetSyncRunLogs -func NewGetSyncRunLogsRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsParams) (*http.Request, error) { - var err error + // ListUsersWithResponse request + ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) - var pathParam0 string + // AddUserWithBodyWithResponse request with any body + AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) - var pathParam1 string + // DeleteUserWithResponse request + DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + // GetUserWithResponse request + GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) - var pathParam2 string + // UpdateUserWithBodyWithResponse request with any body + UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + // DeleteUserTOTPWithResponse request + DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/logs", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + // CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with any body + CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) - if params != nil { - queryValues := queryURL.Query() + // GetV2SyncDestinationsWithResponse request + GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) - if params.Table != nil { + // CreateV2SyncDestinationWithBodyWithResponse request with any body + CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) - } + // DeleteV2SyncDestinationWithResponse request + DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) - queryURL.RawQuery = queryValues.Encode() - } + // GetV2SyncDestinationWithResponse request + GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + // PatchV2SyncDestinationWithBodyWithResponse request with any body + PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) - if params != nil { + PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) - if params.Accept != nil { - var headerParam0 string + // CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with any body + CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } + CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) - req.Header.Set("Accept", headerParam0) - } + // ListV2SyncIntegrationsWithResponse request + ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) - } + // CreateV2SyncIntegrationWithBodyWithResponse request with any body + CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) - return req, nil -} + CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) -// NewGetSyncRunLogsLiveRequest generates requests for GetSyncRunLogsLive -func NewGetSyncRunLogsLiveRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams) (*http.Request, error) { - var err error + // DeleteV2SyncIntegrationWithResponse request + DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) - var pathParam0 string + // GetV2SyncIntegrationWithResponse request + GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } + // UpdateV2SyncIntegrationWithBodyWithResponse request with any body + UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) - var pathParam1 string + UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err +type IndexResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *struct { + Errors *[]string `json:"errors,omitempty"` + FieldErrors *map[string]string `json:"field_errors,omitempty"` + Message string `json:"message"` + Status int `json:"status"` } +} - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r IndexResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r IndexResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/logs/live", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath +type ListAllAlertsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []AlertDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListAllAlertsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - if params != nil { - queryValues := queryURL.Query() - - if params.Table != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllAlertsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +type TestUnsavedAlertResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Results Notification results for the test alert + Results []AlertTestResponse `json:"results"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - if params != nil { - - if params.Accept != nil { - var headerParam0 string +// Status returns HTTPResponse.Status +func (r TestUnsavedAlertResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +// StatusCode returns HTTPResponse.StatusCode +func (r TestUnsavedAlertResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - req.Header.Set("Accept", headerParam0) - } +type ListAPIKeysResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // AllowedRoles List of allowed roles when creating a new API key + AllowedRoles []Role `json:"allowed_roles"` + Items []APIKey `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r ListAPIKeysResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return req, nil +// StatusCode returns HTTPResponse.StatusCode +func (r ListAPIKeysResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// NewGetSyncRunLogsQueryRequest generates requests for GetSyncRunLogsQuery -func NewGetSyncRunLogsQueryRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams) (*http.Request, error) { - var err error +type CreateAPIKeyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *APIKey + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - var pathParam0 string +// Status returns HTTPResponse.Status +func (r CreateAPIKeyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateAPIKeyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam1 string +type DeleteAPIKeyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteAPIKeyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteAPIKeyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +type ListAuditLogsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []AuditLogEvent `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/logs/query", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath +// Status returns HTTPResponse.Status +func (r ListAuditLogsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListAuditLogsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - if params != nil { - queryValues := queryURL.Query() - - if params.Filters != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } +type GetAuditLogResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *AuditLogEvent + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} - if params.PerPage != nil { +// Status returns HTTPResponse.Status +func (r GetAuditLogResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r GetAuditLogResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type GetSAMLResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SAMLConfig + JSON400 *BadRequest + JSON500 *InternalError +} - if params.Page != nil { +// Status returns HTTPResponse.Status +func (r GetSAMLResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r GetSAMLResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type UpdateSAMLResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SAMLConfig + JSON400 *BadRequest + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - if params.Download != nil { +// Status returns HTTPResponse.Status +func (r UpdateSAMLResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSAMLResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type CreateConversationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *Conversation + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON429 *TooManyRequests + JSON500 *InternalError +} - queryURL.RawQuery = queryValues.Encode() +// Status returns HTTPResponse.Status +func (r CreateConversationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateConversationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +type GetConversationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Conversation + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - req.Header.Set("Accept", headerParam0) - } +// Status returns HTTPResponse.Status +func (r GetConversationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r GetConversationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return req, nil +type SendMessageResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *ConversationMessage + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// NewCreateSyncRunProgressRequest calls the generic CreateSyncRunProgress builder with application/json body -func NewCreateSyncRunProgressRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r SendMessageResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncRunProgressRequestWithBody(server, teamName, syncName, syncRunId, "application/json", bodyReader) + return http.StatusText(0) } -// NewCreateSyncRunProgressRequestWithBody generates requests for CreateSyncRunProgress with any type of body -func NewCreateSyncRunProgressRequestWithBody(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string +// StatusCode returns HTTPResponse.StatusCode +func (r SendMessageResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +type ListAllCustomColumnsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []CustomColumn `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - var pathParam1 string +// Status returns HTTPResponse.Status +func (r ListAllCustomColumnsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllCustomColumnsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam2 string +type SaveCustomColumnResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *CustomColumn + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r SaveCustomColumnResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r SaveCustomColumnResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/progress", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } +type DeleteCustomColumnResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteCustomColumnResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteCustomColumnResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - - req.Header.Add("Content-Type", contentType) - - return req, nil + return 0 } -// NewGetSyncRunStatsRequest generates requests for GetSyncRunStats -func NewGetSyncRunStatsRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { - var err error +type GetCustomColumnResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *CustomColumn + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - var pathParam0 string +// Status returns HTTPResponse.Status +func (r GetCustomColumnResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetCustomColumnResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam1 string +type UpdateCustomColumnResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *CustomColumn + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateCustomColumnResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateCustomColumnResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +type ListFiltersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/stats", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath +// Status returns HTTPResponse.Status +func (r ListFiltersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListFiltersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +type ListFilterTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - return req, nil +// Status returns HTTPResponse.Status +func (r ListFilterTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) } -// NewGetSyncRunTablesRequest generates requests for GetSyncRunTables -func NewGetSyncRunTablesRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams) (*http.Request, error) { - var err error +// StatusCode returns HTTPResponse.StatusCode +func (r ListFilterTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - var pathParam0 string +type DeleteFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam2 string +type GetFilterByIDResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Filter + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetFilterByIDResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetFilterByIDResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/tables", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } +type UpdateFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Filter + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - if params != nil { - queryValues := queryURL.Query() +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if params.PerPage != nil { +type HealthCheckResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON500 *InternalError + JSON503 *ServiceUnavailable +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } +// Status returns HTTPResponse.Status +func (r HealthCheckResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.Page != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r HealthCheckResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type HealthCheckHeadResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON500 *InternalError + JSON503 *ServiceUnavailable +} - } +// Status returns HTTPResponse.Status +func (r HealthCheckHeadResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.SortBys != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r HealthCheckHeadResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type ListNotificationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []NotificationDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - } +// Status returns HTTPResponse.Status +func (r ListNotificationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.SortDirections != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r ListNotificationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type DeleteNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - } +// Status returns HTTPResponse.Status +func (r DeleteNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - queryURL.RawQuery = queryValues.Encode() +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +type GetNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *NotificationDestination + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return req, nil +// StatusCode returns HTTPResponse.StatusCode +func (r GetNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// NewListTablesTeamRequest generates requests for ListTablesTeam -func NewListTablesTeamRequest(server string, teamName TeamName, params *ListTablesTeamParams) (*http.Request, error) { - var err error +type UpdateNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *NotificationDestination + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - var pathParam0 string +// Status returns HTTPResponse.Status +func (r UpdateNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +type GetNotificationDestinationAlertsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []AlertDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - operationPath := fmt.Sprintf("/teams/%s/tables", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath +// Status returns HTTPResponse.Status +func (r GetNotificationDestinationAlertsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetNotificationDestinationAlertsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - if params != nil { - queryValues := queryURL.Query() +type TestNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *NotificationDestinationTestResponse + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError +} - if params.PerPage != nil { +// Status returns HTTPResponse.Status +func (r TestNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r TestNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type ListAllNotificationDestinationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []NotificationDestinationListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - if params.Page != nil { +// Status returns HTTPResponse.Status +func (r ListAllNotificationDestinationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllNotificationDestinationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type CreateNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *NotificationDestination + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - queryURL.RawQuery = queryValues.Encode() +// Status returns HTTPResponse.Status +func (r CreateNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - - return req, nil + return 0 } -// NewBatchTableSchemasTeamRequest generates requests for BatchTableSchemasTeam -func NewBatchTableSchemasTeamRequest(server string, teamName TeamName, params *BatchTableSchemasTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string +type TestUnsavedNotificationDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *NotificationDestinationTestResponse + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r TestUnsavedNotificationDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r TestUnsavedNotificationDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/tables/schemas", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } +type CreateAWSOnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *OnboardingAWSCreateResponse + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON500 *InternalError +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateAWSOnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - if params != nil { - queryValues := queryURL.Query() +// StatusCode returns HTTPResponse.StatusCode +func (r CreateAWSOnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tables", runtime.ParamLocationQuery, params.Tables); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type GetAWSOnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *OnboardingAWS + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - queryURL.RawQuery = queryValues.Encode() +// Status returns HTTPResponse.Status +func (r GetAWSOnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetAWSOnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - - return req, nil + return 0 } -// NewTableListColumnsTeamRequest generates requests for TableListColumnsTeam -func NewTableListColumnsTeamRequest(server string, teamName TeamName, tableName TableName, params *TableListColumnsTeamParams) (*http.Request, error) { - var err error +type GetAWSAccountsInRootResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *OnboardingAWSAccounts + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - var pathParam0 string +// Status returns HTTPResponse.Status +func (r GetAWSAccountsInRootResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetAWSAccountsInRootResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam1 string +type ProvisionOnboardingConfigurationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ProvisionOnboardingConfigurationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ProvisionOnboardingConfigurationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/tables/%s/columns", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } +type GetAWSAccountsInParentResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *OnboardingAWSAccounts + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetAWSAccountsInParentResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - if params != nil { - queryValues := queryURL.Query() +// StatusCode returns HTTPResponse.StatusCode +func (r GetAWSAccountsInParentResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type NotifyOnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON500 *InternalError +} - } +// Status returns HTTPResponse.Status +func (r NotifyOnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.Filter != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r NotifyOnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type GetOpenAPIJSONResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *map[string]interface{} + JSON400 *BadRequest +} - } +// Status returns HTTPResponse.Status +func (r GetOpenAPIJSONResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.Page != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r GetOpenAPIJSONResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type GetPlatformInfoResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + PublicIps *[]string `json:"public_ips,omitempty"` + } + JSON401 *RequiresAuthentication + JSON500 *InternalError +} - } +// Status returns HTTPResponse.Status +func (r GetPlatformInfoResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if params.PerPage != nil { +// StatusCode returns HTTPResponse.StatusCode +func (r GetPlatformInfoResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +type ListPlatformVersionsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PlatformVersion `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON500 *InternalError +} - } +// Status returns HTTPResponse.Status +func (r ListPlatformVersionsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - queryURL.RawQuery = queryValues.Encode() +// StatusCode returns HTTPResponse.StatusCode +func (r ListPlatformVersionsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +type ListPluginsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items ListPlugins `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON500 *InternalError +} - return req, nil +// Status returns HTTPResponse.Status +func (r ListPluginsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) } -// NewTableColumnListValuesTeamRequest generates requests for TableColumnListValuesTeam -func NewTableColumnListValuesTeamRequest(server string, teamName TeamName, tableName TableName, columnName ColumnName, params *TableColumnListValuesTeamParams) (*http.Request, error) { - var err error +// StatusCode returns HTTPResponse.StatusCode +func (r ListPluginsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - var pathParam0 string +type GetPluginResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *ListPlugin + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetPluginResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPluginResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam2 string +type ListPluginVersionsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PluginVersionList `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "column_name", runtime.ParamLocationPath, columnName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListPluginVersionsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListPluginVersionsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/tables/%s/columns/%s/values", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath +type GetPluginVersionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PluginVersionDetails + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetPluginVersionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPluginVersionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - if params != nil { - queryValues := queryURL.Query() +type DownloadPluginAssetResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PluginAsset + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON429 *TooManyRequests + JSON500 *InternalError +} - if params.FilterMode != nil { +// Status returns HTTPResponse.Status +func (r DownloadPluginAssetResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r DownloadPluginAssetResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type ListPluginVersionTablesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PluginTable `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - if params.Filter != nil { +// Status returns HTTPResponse.Status +func (r ListPluginVersionTablesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r ListPluginVersionTablesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type GetPluginVersionTableResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PluginTableDetails + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - if params.Page != nil { +// Status returns HTTPResponse.Status +func (r GetPluginVersionTableResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r GetPluginVersionTableResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type ListPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Policy `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} - if params.PerPage != nil { +// Status returns HTTPResponse.Status +func (r ListPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// StatusCode returns HTTPResponse.StatusCode +func (r ListPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - } +type CreatePolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *Policy + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - queryURL.RawQuery = queryValues.Encode() +// Status returns HTTPResponse.Status +func (r CreatePolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreatePolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - - return req, nil + return 0 } -// NewTableListRowsTeamRequest generates requests for TableListRowsTeam -func NewTableListRowsTeamRequest(server string, teamName TeamName, tableName TableName, params *TableListRowsTeamParams) (*http.Request, error) { - var err error +type GetPolicyMetricsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PolicyMetrics + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} - var pathParam0 string +// Status returns HTTPResponse.Status +func (r GetPolicyMetricsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPolicyMetricsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - var pathParam1 string +type GetViolationsByDomainResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *ViolationsByDomain + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetViolationsByDomainResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - serverURL, err := url.Parse(server) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetViolationsByDomainResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - operationPath := fmt.Sprintf("/teams/%s/tables/%s/data", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath +type GetViolationsHistoryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *ViolationsHistory + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetViolationsHistoryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetViolationsHistoryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - if params != nil { - queryValues := queryURL.Query() +type DeletePolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - if params.Selects != nil { +// Status returns HTTPResponse.Status +func (r DeletePolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filters != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterIDs != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.GroupBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableRowByIdTeamRequest generates requests for TableRowByIdTeam -func NewTableRowByIdTeamRequest(server string, teamName TeamName, tableName TableName, tableRowId TableRowId, params *TableRowByIdTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "table_row_id", runtime.ParamLocationPath, tableRowId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/data/%s", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filters != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterIDs != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableListFiltersTeamRequest generates requests for TableListFiltersTeam -func NewTableListFiltersTeamRequest(server string, teamName TeamName, tableName TableName, params *TableListFiltersTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/filters", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterTags != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableSaveFilterTeamRequest calls the generic TableSaveFilterTeam builder with application/json body -func NewTableSaveFilterTeamRequest(server string, teamName TeamName, tableName TableName, body TableSaveFilterTeamJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewTableSaveFilterTeamRequestWithBody(server, teamName, tableName, "application/json", bodyReader) -} - -// NewTableSaveFilterTeamRequestWithBody generates requests for TableSaveFilterTeam with any type of body -func NewTableSaveFilterTeamRequestWithBody(server string, teamName TeamName, tableName TableName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/filters", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewTableListFilterTagsTeamRequest generates requests for TableListFilterTagsTeam -func NewTableListFilterTagsTeamRequest(server string, teamName TeamName, tableName TableName, params *TableListFilterTagsTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/filters/tags", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableListRelationsTeamRequest generates requests for TableListRelationsTeam -func NewTableListRelationsTeamRequest(server string, teamName TeamName, tableName TableName, params *TableListRelationsTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/relations", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.RelationName != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "relation_name", runtime.ParamLocationQuery, *params.RelationName); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableSchemaTeamRequest generates requests for TableSchemaTeam -func NewTableSchemaTeamRequest(server string, teamName TeamName, tableName TableName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/tables/%s/schema", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetTeamUsageSummaryRequest generates requests for GetTeamUsageSummary -func NewGetTeamUsageSummaryRequest(server string, teamName TeamName, params *GetTeamUsageSummaryParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/usage-summary", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Metrics != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Start != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.End != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.AggregationPeriod != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetGroupedTeamUsageSummaryRequest generates requests for GetGroupedTeamUsageSummary -func NewGetGroupedTeamUsageSummaryRequest(server string, teamName TeamName, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "group_by", runtime.ParamLocationPath, groupBy) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/usage-summary/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Metrics != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Start != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.End != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.AggregationPeriod != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListUsersByTeamRequest generates requests for ListUsersByTeam -func NewListUsersByTeamRequest(server string, teamName TeamName, params *ListUsersByTeamParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/teams/%s/users", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUploadImageRequest calls the generic UploadImage builder with application/json body -func NewUploadImageRequest(server string, body UploadImageJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUploadImageRequestWithBody(server, "application/json", bodyReader) -} - -// NewUploadImageRequestWithBody generates requests for UploadImage with any type of body -func NewUploadImageRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/upload/image") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewGetCurrentUserRequest generates requests for GetCurrentUser -func NewGetCurrentUserRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdateCurrentUserRequest calls the generic UpdateCurrentUser builder with application/json body -func NewUpdateCurrentUserRequest(server string, body UpdateCurrentUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateCurrentUserRequestWithBody(server, "application/json", bodyReader) -} - -// NewUpdateCurrentUserRequestWithBody generates requests for UpdateCurrentUser with any type of body -func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewSendAnonymousEventRequest calls the generic SendAnonymousEvent builder with application/json body -func NewSendAnonymousEventRequest(server string, body SendAnonymousEventJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewSendAnonymousEventRequestWithBody(server, "application/json", bodyReader) -} - -// NewSendAnonymousEventRequestWithBody generates requests for SendAnonymousEvent with any type of body -func NewSendAnonymousEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/anon-event") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewAuthenticateLocalUserRequest calls the generic AuthenticateLocalUser builder with application/json body -func NewAuthenticateLocalUserRequest(server string, body AuthenticateLocalUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewAuthenticateLocalUserRequestWithBody(server, "application/json", bodyReader) -} - -// NewAuthenticateLocalUserRequestWithBody generates requests for AuthenticateLocalUser with any type of body -func NewAuthenticateLocalUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/authenticate") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewChangeLocalUserPasswordRequest calls the generic ChangeLocalUserPassword builder with application/json body -func NewChangeLocalUserPasswordRequest(server string, body ChangeLocalUserPasswordJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewChangeLocalUserPasswordRequestWithBody(server, "application/json", bodyReader) -} - -// NewChangeLocalUserPasswordRequestWithBody generates requests for ChangeLocalUserPassword with any type of body -func NewChangeLocalUserPasswordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/change-password") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewUpdateCustomerRequest calls the generic UpdateCustomer builder with application/json body -func NewUpdateCustomerRequest(server string, body UpdateCustomerJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateCustomerRequestWithBody(server, "application/json", bodyReader) -} - -// NewUpdateCustomerRequestWithBody generates requests for UpdateCustomer with any type of body -func NewUpdateCustomerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/customer") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewSendUserEventRequest calls the generic SendUserEvent builder with application/json body -func NewSendUserEventRequest(server string, body SendUserEventJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewSendUserEventRequestWithBody(server, "application/json", bodyReader) -} - -// NewSendUserEventRequestWithBody generates requests for SendUserEvent with any type of body -func NewSendUserEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/event") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListCurrentUserInvitationsRequest generates requests for ListCurrentUserInvitations -func NewListCurrentUserInvitationsRequest(server string, params *ListCurrentUserInvitationsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/invitations") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetCurrentLocalUserRequest generates requests for GetCurrentLocalUser -func NewGetCurrentLocalUserRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/local") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewLogoutUserRequest generates requests for LogoutUser -func NewLogoutUserRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/login") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewLoginUserRequest calls the generic LoginUser builder with application/json body -func NewLoginUserRequest(server string, body LoginUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewLoginUserRequestWithBody(server, "application/json", bodyReader) -} - -// NewLoginUserRequestWithBody generates requests for LoginUser with any type of body -func NewLoginUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/login") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewGetCurrentUserMembershipsRequest generates requests for GetCurrentUserMemberships -func NewGetCurrentUserMembershipsRequest(server string, params *GetCurrentUserMembershipsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/memberships") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewResetLocalUserPasswordRequest calls the generic ResetLocalUserPassword builder with application/json body -func NewResetLocalUserPasswordRequest(server string, body ResetLocalUserPasswordJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewResetLocalUserPasswordRequestWithBody(server, "application/json", bodyReader) -} - -// NewResetLocalUserPasswordRequestWithBody generates requests for ResetLocalUserPassword with any type of body -func NewResetLocalUserPasswordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/reset-password-token") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewCreateUserTokenRequest generates requests for CreateUserToken -func NewCreateUserTokenRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/token") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUserTOTPDeleteRequest generates requests for UserTOTPDelete -func NewUserTOTPDeleteRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/totp") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUserTOTPSetupRequest generates requests for UserTOTPSetup -func NewUserTOTPSetupRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/totp") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUserTOTPVerifyRequest calls the generic UserTOTPVerify builder with application/json body -func NewUserTOTPVerifyRequest(server string, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUserTOTPVerifyRequestWithBody(server, params, "application/json", bodyReader) -} - -// NewUserTOTPVerifyRequestWithBody generates requests for UserTOTPVerify with any type of body -func NewUserTOTPVerifyRequestWithBody(server string, params *UserTOTPVerifyParams, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/totp/verify") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - if params != nil { - - if params.CqpSess != nil { - var cookieParam0 string - - cookieParam0, err = runtime.StyleParamWithLocation("simple", true, "__cqp_sess", runtime.ParamLocationCookie, *params.CqpSess) - if err != nil { - return nil, err - } - - cookie0 := &http.Cookie{ - Name: "__cqp_sess", - Value: cookieParam0, - } - req.AddCookie(cookie0) - } - } - return req, nil -} - -// NewDeleteUserRequest generates requests for DeleteUser -func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/users/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewCreateV2SyncDestinationTestConnectionRequest calls the generic CreateV2SyncDestinationTestConnection builder with application/json body -func NewCreateV2SyncDestinationTestConnectionRequest(server string, teamName TeamName, body CreateV2SyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncDestinationTestConnectionRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateV2SyncDestinationTestConnectionRequestWithBody generates requests for CreateV2SyncDestinationTestConnection with any type of body -func NewCreateV2SyncDestinationTestConnectionRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destination-test-connections", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewGetV2SyncDestinationsRequest generates requests for GetV2SyncDestinations -func NewGetV2SyncDestinationsRequest(server string, teamName TeamName, params *GetV2SyncDestinationsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destinations", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncGenericSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewCreateV2SyncDestinationRequest calls the generic CreateV2SyncDestination builder with application/json body -func NewCreateV2SyncDestinationRequest(server string, teamName TeamName, body CreateV2SyncDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncDestinationRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateV2SyncDestinationRequestWithBody generates requests for CreateV2SyncDestination with any type of body -func NewCreateV2SyncDestinationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destinations", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteV2SyncDestinationRequest generates requests for DeleteV2SyncDestination -func NewDeleteV2SyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destinations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetV2SyncDestinationRequest generates requests for GetV2SyncDestination -func NewGetV2SyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destinations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewPatchV2SyncDestinationRequest calls the generic PatchV2SyncDestination builder with application/json body -func NewPatchV2SyncDestinationRequest(server string, teamName TeamName, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewPatchV2SyncDestinationRequestWithBody(server, teamName, syncDestinationName, "application/json", bodyReader) -} - -// NewPatchV2SyncDestinationRequestWithBody generates requests for PatchV2SyncDestination with any type of body -func NewPatchV2SyncDestinationRequestWithBody(server string, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-destinations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewCreateV2SyncIntegrationTestConnectionRequest calls the generic CreateV2SyncIntegrationTestConnection builder with application/json body -func NewCreateV2SyncIntegrationTestConnectionRequest(server string, teamName TeamName, body CreateV2SyncIntegrationTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateV2SyncIntegrationTestConnectionRequestWithBody generates requests for CreateV2SyncIntegrationTestConnection with any type of body -func NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integration-test-connections", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListV2SyncIntegrationsRequest generates requests for ListV2SyncIntegrations -func NewListV2SyncIntegrationsRequest(server string, teamName TeamName, params *ListV2SyncIntegrationsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integrations", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewCreateV2SyncIntegrationRequest calls the generic CreateV2SyncIntegration builder with application/json body -func NewCreateV2SyncIntegrationRequest(server string, teamName TeamName, body CreateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncIntegrationRequestWithBody(server, teamName, "application/json", bodyReader) -} - -// NewCreateV2SyncIntegrationRequestWithBody generates requests for CreateV2SyncIntegration with any type of body -func NewCreateV2SyncIntegrationRequestWithBody(server string, teamName TeamName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integrations", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteV2SyncIntegrationRequest generates requests for DeleteV2SyncIntegration -func NewDeleteV2SyncIntegrationRequest(server string, teamName TeamName, syncName SyncName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integrations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetV2SyncIntegrationRequest generates requests for GetV2SyncIntegration -func NewGetV2SyncIntegrationRequest(server string, teamName TeamName, syncName SyncName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integrations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdateV2SyncIntegrationRequest calls the generic UpdateV2SyncIntegration builder with application/json body -func NewUpdateV2SyncIntegrationRequest(server string, teamName TeamName, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateV2SyncIntegrationRequestWithBody(server, teamName, syncName, "application/json", bodyReader) -} - -// NewUpdateV2SyncIntegrationRequestWithBody generates requests for UpdateV2SyncIntegration with any type of body -func NewUpdateV2SyncIntegrationRequestWithBody(server string, teamName TeamName, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/teams/%s/sync-integrations/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error { - for _, r := range c.RequestEditors { - if err := r(ctx, req); err != nil { - return err - } - } - for _, r := range additionalEditors { - if err := r(ctx, req); err != nil { - return err - } - } - return nil -} - -// ClientWithResponses builds on ClientInterface to offer response payloads -type ClientWithResponses struct { - ClientInterface -} - -// NewClientWithResponses creates a new ClientWithResponses, which wraps -// Client with return type handling -func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error) { - client, err := NewClient(server, opts...) - if err != nil { - return nil, err - } - return &ClientWithResponses{client}, nil -} - -// WithBaseURL overrides the baseURL. -func WithBaseURL(baseURL string) ClientOption { - return func(c *Client) error { - newBaseURL, err := url.Parse(baseURL) - if err != nil { - return err - } - c.Server = newBaseURL.String() - return nil - } -} - -// ClientWithResponsesInterface is the interface specification for the client with responses above. -type ClientWithResponsesInterface interface { - // IndexWithResponse request - IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) - - // ListAuditLogsWithResponse request - ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) - - // GetAuditLogWithResponse request - GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) - - // HealthCheckWithResponse request - HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) - - // HealthCheckHeadWithResponse request - HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) - - // AssetViewGetStatusWithResponse request - AssetViewGetStatusWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*AssetViewGetStatusResponse, error) - - // AssetViewTriggerWithResponse request - AssetViewTriggerWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*AssetViewTriggerResponse, error) - - // AssetViewListLogsWithResponse request - AssetViewListLogsWithResponse(ctx context.Context, params *AssetViewListLogsParams, reqEditors ...RequestEditorFn) (*AssetViewListLogsResponse, error) - - // ManageGetSAMLWithResponse request - ManageGetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ManageGetSAMLResponse, error) - - // ManageUpdateSAMLWithBodyWithResponse request with any body - ManageUpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageUpdateSAMLResponse, error) - - ManageUpdateSAMLWithResponse(ctx context.Context, body ManageUpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageUpdateSAMLResponse, error) - - // ManageGetPlatformRegistryWithResponse request - ManageGetPlatformRegistryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ManageGetPlatformRegistryResponse, error) - - // ManageRegisterPlatformWithBodyWithResponse request with any body - ManageRegisterPlatformWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformResponse, error) - - ManageRegisterPlatformWithResponse(ctx context.Context, body ManageRegisterPlatformJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformResponse, error) - - // ManageRegisterPlatformWithOfflineLicenseWithBodyWithResponse request with any body - ManageRegisterPlatformWithOfflineLicenseWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformWithOfflineLicenseResponse, error) - - ManageRegisterPlatformWithOfflineLicenseWithResponse(ctx context.Context, body ManageRegisterPlatformWithOfflineLicenseJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformWithOfflineLicenseResponse, error) - - // GetSettingsWithResponse request - GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) - - // UpdateSettingsWithBodyWithResponse request with any body - UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) - - UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) - - // ManageListAllTeamsWithResponse request - ManageListAllTeamsWithResponse(ctx context.Context, params *ManageListAllTeamsParams, reqEditors ...RequestEditorFn) (*ManageListAllTeamsResponse, error) - - // ManageDeleteTeamWithResponse request - ManageDeleteTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*ManageDeleteTeamResponse, error) - - // ManageGetTeamWithResponse request - ManageGetTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*ManageGetTeamResponse, error) - - // ManageRemoveTeamMemberWithBodyWithResponse request with any body - ManageRemoveTeamMemberWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRemoveTeamMemberResponse, error) - - ManageRemoveTeamMemberWithResponse(ctx context.Context, teamName TeamName, body ManageRemoveTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRemoveTeamMemberResponse, error) - - // ManageListTeamMembersWithResponse request - ManageListTeamMembersWithResponse(ctx context.Context, teamName TeamName, params *ManageListTeamMembersParams, reqEditors ...RequestEditorFn) (*ManageListTeamMembersResponse, error) - - // ManageAddTeamMemberWithBodyWithResponse request with any body - ManageAddTeamMemberWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageAddTeamMemberResponse, error) - - ManageAddTeamMemberWithResponse(ctx context.Context, teamName TeamName, body ManageAddTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageAddTeamMemberResponse, error) - - // ListLocalUsersWithResponse request - ListLocalUsersWithResponse(ctx context.Context, params *ListLocalUsersParams, reqEditors ...RequestEditorFn) (*ListLocalUsersResponse, error) - - // AddLocalUserWithBodyWithResponse request with any body - AddLocalUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddLocalUserResponse, error) - - AddLocalUserWithResponse(ctx context.Context, body AddLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddLocalUserResponse, error) - - // DeleteLocalUserWithResponse request - DeleteLocalUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteLocalUserResponse, error) - - // GetLocalUserWithResponse request - GetLocalUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetLocalUserResponse, error) - - // UpdateLocalUserWithBodyWithResponse request with any body - UpdateLocalUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateLocalUserResponse, error) - - UpdateLocalUserWithResponse(ctx context.Context, userID UserID, body UpdateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateLocalUserResponse, error) - - // CreateLocalUserResetTokenWithResponse request - CreateLocalUserResetTokenWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*CreateLocalUserResetTokenResponse, error) - - // ManageUserTOTPDeleteWithResponse request - ManageUserTOTPDeleteWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*ManageUserTOTPDeleteResponse, error) - - // GetOpenAPIJSONWithResponse request - GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) - - // GetPlatformInfoWithResponse request - GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) - - // ListPlatformVersionsWithResponse request - ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) - - // ListPluginsWithResponse request - ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) - - // CreatePluginWithBodyWithResponse request with any body - CreatePluginWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginResponse, error) - - CreatePluginWithResponse(ctx context.Context, body CreatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginResponse, error) - - // DeletePluginByTeamAndPluginNameWithResponse request - DeletePluginByTeamAndPluginNameWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*DeletePluginByTeamAndPluginNameResponse, error) - - // GetPluginWithResponse request - GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) - - // UpdatePluginWithBodyWithResponse request with any body - UpdatePluginWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePluginResponse, error) - - UpdatePluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, body UpdatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePluginResponse, error) - - // ListPluginVersionsWithResponse request - ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) - - // GetPluginVersionWithResponse request - GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) - - // UpdatePluginVersionWithBodyWithResponse request with any body - UpdatePluginVersionWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePluginVersionResponse, error) - - UpdatePluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UpdatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePluginVersionResponse, error) - - // CreatePluginVersionWithBodyWithResponse request with any body - CreatePluginVersionWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionResponse, error) - - CreatePluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionResponse, error) - - // DownloadPluginAssetWithResponse request - DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) - - // UploadPluginAssetWithResponse request - UploadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, reqEditors ...RequestEditorFn) (*UploadPluginAssetResponse, error) - - // DeletePluginVersionDocsWithBodyWithResponse request with any body - DeletePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeletePluginVersionDocsResponse, error) - - DeletePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*DeletePluginVersionDocsResponse, error) - - // ListPluginVersionDocsWithResponse request - ListPluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionDocsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionDocsResponse, error) - - // ReplacePluginVersionDocsWithBodyWithResponse request with any body - ReplacePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ReplacePluginVersionDocsResponse, error) - - ReplacePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body ReplacePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*ReplacePluginVersionDocsResponse, error) - - // CreatePluginVersionDocsWithBodyWithResponse request with any body - CreatePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionDocsResponse, error) - - CreatePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionDocsResponse, error) - - // DeletePluginVersionTablesWithBodyWithResponse request with any body - DeletePluginVersionTablesWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeletePluginVersionTablesResponse, error) - - DeletePluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*DeletePluginVersionTablesResponse, error) - - // ListPluginVersionTablesWithResponse request - ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) - - // CreatePluginVersionTablesWithBodyWithResponse request with any body - CreatePluginVersionTablesWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionTablesResponse, error) - - CreatePluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionTablesResponse, error) - - // GetPluginVersionTableWithResponse request - GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) - - // RemovePluginUIAssetsWithResponse request - RemovePluginUIAssetsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*RemovePluginUIAssetsResponse, error) - - // UploadPluginUIAssetsWithBodyWithResponse request with any body - UploadPluginUIAssetsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadPluginUIAssetsResponse, error) - - UploadPluginUIAssetsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UploadPluginUIAssetsJSONRequestBody, reqEditors ...RequestEditorFn) (*UploadPluginUIAssetsResponse, error) - - // FinalizePluginUIAssetUploadWithBodyWithResponse request with any body - FinalizePluginUIAssetUploadWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*FinalizePluginUIAssetUploadResponse, error) - - FinalizePluginUIAssetUploadWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body FinalizePluginUIAssetUploadJSONRequestBody, reqEditors ...RequestEditorFn) (*FinalizePluginUIAssetUploadResponse, error) - - // AuthRegistryRequestWithResponse request - AuthRegistryRequestWithResponse(ctx context.Context, params *AuthRegistryRequestParams, reqEditors ...RequestEditorFn) (*AuthRegistryRequestResponse, error) - - // ListTeamsWithResponse request - ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) - - // CreateTeamWithBodyWithResponse request with any body - CreateTeamWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamResponse, error) - - CreateTeamWithResponse(ctx context.Context, body CreateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamResponse, error) - - // DeleteTeamWithResponse request - DeleteTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*DeleteTeamResponse, error) - - // GetTeamByNameWithResponse request - GetTeamByNameWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*GetTeamByNameResponse, error) - - // UpdateTeamWithBodyWithResponse request with any body - UpdateTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateTeamResponse, error) - - UpdateTeamWithResponse(ctx context.Context, teamName TeamName, body UpdateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateTeamResponse, error) - - // ListAllAlertsWithResponse request - ListAllAlertsWithResponse(ctx context.Context, teamName TeamName, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) - - // TestUnsavedAlertWithBodyWithResponse request with any body - TestUnsavedAlertWithBodyWithResponse(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) - - TestUnsavedAlertWithResponse(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) - - // ListTeamAPIKeysWithResponse request - ListTeamAPIKeysWithResponse(ctx context.Context, teamName TeamName, params *ListTeamAPIKeysParams, reqEditors ...RequestEditorFn) (*ListTeamAPIKeysResponse, error) - - // CreateTeamAPIKeyWithBodyWithResponse request with any body - CreateTeamAPIKeyWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamAPIKeyResponse, error) - - CreateTeamAPIKeyWithResponse(ctx context.Context, teamName TeamName, body CreateTeamAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamAPIKeyResponse, error) - - // DeleteTeamAPIKeyWithResponse request - DeleteTeamAPIKeyWithResponse(ctx context.Context, teamName TeamName, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteTeamAPIKeyResponse, error) - - // ListConnectorsWithResponse request - ListConnectorsWithResponse(ctx context.Context, teamName TeamName, params *ListConnectorsParams, reqEditors ...RequestEditorFn) (*ListConnectorsResponse, error) - - // CreateConnectorWithBodyWithResponse request with any body - CreateConnectorWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConnectorResponse, error) - - CreateConnectorWithResponse(ctx context.Context, teamName TeamName, body CreateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConnectorResponse, error) - - // GetConnectorWithResponse request - GetConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorResponse, error) - - // UpdateConnectorWithBodyWithResponse request with any body - UpdateConnectorWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateConnectorResponse, error) - - UpdateConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body UpdateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateConnectorResponse, error) - - // RevokeConnectorWithResponse request - RevokeConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*RevokeConnectorResponse, error) - - // GetConnectorAuthStatusAWSWithResponse request - GetConnectorAuthStatusAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorAuthStatusAWSResponse, error) - - // AuthenticateConnectorFinishAWSWithBodyWithResponse request with any body - AuthenticateConnectorFinishAWSWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishAWSResponse, error) - - AuthenticateConnectorFinishAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishAWSResponse, error) - - // AuthenticateConnectorAWSWithBodyWithResponse request with any body - AuthenticateConnectorAWSWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorAWSResponse, error) - - AuthenticateConnectorAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorAWSResponse, error) - - // GetConnectorAuthStatusGCPWithResponse request - GetConnectorAuthStatusGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorAuthStatusGCPResponse, error) - - // AuthenticateConnectorGCPWithBodyWithResponse request with any body - AuthenticateConnectorGCPWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorGCPResponse, error) - - AuthenticateConnectorGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorGCPJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorGCPResponse, error) - - // AuthenticateConnectorFinishGCPWithResponse request - AuthenticateConnectorFinishGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishGCPResponse, error) - - // AuthenticateConnectorFinishOAuthWithBodyWithResponse request with any body - AuthenticateConnectorFinishOAuthWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishOAuthResponse, error) - - AuthenticateConnectorFinishOAuthWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishOAuthResponse, error) - - // AuthenticateConnectorOAuthWithBodyWithResponse request with any body - AuthenticateConnectorOAuthWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorOAuthResponse, error) - - AuthenticateConnectorOAuthWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorOAuthResponse, error) - - // CreateConversationWithBodyWithResponse request with any body - CreateConversationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) - - CreateConversationWithResponse(ctx context.Context, teamName TeamName, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) - - // GetConversationWithResponse request - GetConversationWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) - - // SendMessageWithBodyWithResponse request with any body - SendMessageWithBodyWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) - - SendMessageWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) - - // ListAllCustomColumnsWithResponse request - ListAllCustomColumnsWithResponse(ctx context.Context, teamName TeamName, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) - - // SaveCustomColumnWithBodyWithResponse request with any body - SaveCustomColumnWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) - - SaveCustomColumnWithResponse(ctx context.Context, teamName TeamName, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) - - // DeleteCustomColumnWithResponse request - DeleteCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) - - // GetCustomColumnWithResponse request - GetCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) - - // UpdateCustomColumnWithBodyWithResponse request with any body - UpdateCustomColumnWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) - - UpdateCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) - - // PutCustomColumnDataWithBodyWithResponse request with any body - PutCustomColumnDataWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutCustomColumnDataResponse, error) - - PutCustomColumnDataWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnDataJSONRequestBody, reqEditors ...RequestEditorFn) (*PutCustomColumnDataResponse, error) - - // PutCustomColumnValuesWithBodyWithResponse request with any body - PutCustomColumnValuesWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutCustomColumnValuesResponse, error) - - PutCustomColumnValuesWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnValuesJSONRequestBody, reqEditors ...RequestEditorFn) (*PutCustomColumnValuesResponse, error) - - // ListFiltersTeamWithResponse request - ListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, params *ListFiltersTeamParams, reqEditors ...RequestEditorFn) (*ListFiltersTeamResponse, error) - - // ListFilterTagsTeamWithResponse request - ListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, params *ListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*ListFilterTagsTeamResponse, error) - - // DeleteFilterTeamWithResponse request - DeleteFilterTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterTeamResponse, error) - - // GetFilterByIDTeamWithResponse request - GetFilterByIDTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDTeamResponse, error) - - // UpdateFilterTeamWithBodyWithResponse request with any body - UpdateFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterTeamResponse, error) - - UpdateFilterTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, body UpdateFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterTeamResponse, error) - - // CreateTeamImagesWithBodyWithResponse request with any body - CreateTeamImagesWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamImagesResponse, error) - - CreateTeamImagesWithResponse(ctx context.Context, teamName TeamName, body CreateTeamImagesJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamImagesResponse, error) - - // DeleteTeamInvitationWithBodyWithResponse request with any body - DeleteTeamInvitationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTeamInvitationResponse, error) - - DeleteTeamInvitationWithResponse(ctx context.Context, teamName TeamName, body DeleteTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTeamInvitationResponse, error) - - // ListTeamInvitationsWithResponse request - ListTeamInvitationsWithResponse(ctx context.Context, teamName TeamName, params *ListTeamInvitationsParams, reqEditors ...RequestEditorFn) (*ListTeamInvitationsResponse, error) - - // AcceptTeamInvitationWithBodyWithResponse request with any body - AcceptTeamInvitationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AcceptTeamInvitationResponse, error) - - AcceptTeamInvitationWithResponse(ctx context.Context, teamName TeamName, body AcceptTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*AcceptTeamInvitationResponse, error) - - // RemoveTeamMembershipWithBodyWithResponse request with any body - RemoveTeamMembershipWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RemoveTeamMembershipResponse, error) - - RemoveTeamMembershipWithResponse(ctx context.Context, teamName TeamName, body RemoveTeamMembershipJSONRequestBody, reqEditors ...RequestEditorFn) (*RemoveTeamMembershipResponse, error) - - // GetTeamMembershipsWithResponse request - GetTeamMembershipsWithResponse(ctx context.Context, teamName TeamName, params *GetTeamMembershipsParams, reqEditors ...RequestEditorFn) (*GetTeamMembershipsResponse, error) - - // DeleteTeamMembershipWithResponse request - DeleteTeamMembershipWithResponse(ctx context.Context, teamName TeamName, email EmailBasic, reqEditors ...RequestEditorFn) (*DeleteTeamMembershipResponse, error) - - // DeleteNotificationDestinationWithResponse request - DeleteNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) - - // GetNotificationDestinationWithResponse request - GetNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) - - // UpdateNotificationDestinationWithBodyWithResponse request with any body - UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) - - UpdateNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) - - // GetNotificationDestinationAlertsWithResponse request - GetNotificationDestinationAlertsWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) - - // TestNotificationDestinationWithResponse request - TestNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) - - // ListAllNotificationDestinationsWithResponse request - ListAllNotificationDestinationsWithResponse(ctx context.Context, teamName TeamName, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) - - // CreateNotificationDestinationWithBodyWithResponse request with any body - CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) - - CreateNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) - - // TestUnsavedNotificationDestinationWithBodyWithResponse request with any body - TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) - - TestUnsavedNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) - - // CreateAWSOnboardingWithBodyWithResponse request with any body - CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) - - CreateAWSOnboardingWithResponse(ctx context.Context, teamName TeamName, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) - - // GetAWSOnboardingWithResponse request - GetAWSOnboardingWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) - - // GetAWSAccountsInRootWithResponse request - GetAWSAccountsInRootWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) - - // ProvisionOnboardingConfigurationWithBodyWithResponse request with any body - ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) - - ProvisionOnboardingConfigurationWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) - - // GetAWSAccountsInParentWithResponse request - GetAWSAccountsInParentWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) - - // NotifyOnboardingWithBodyWithResponse request with any body - NotifyOnboardingWithBodyWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) - - NotifyOnboardingWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) - - // DeletePluginsByTeamWithResponse request - DeletePluginsByTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*DeletePluginsByTeamResponse, error) - - // ListPluginsByTeamWithResponse request - ListPluginsByTeamWithResponse(ctx context.Context, teamName TeamName, params *ListPluginsByTeamParams, reqEditors ...RequestEditorFn) (*ListPluginsByTeamResponse, error) - - // DownloadPluginAssetByTeamWithResponse request - DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) - - // ListPoliciesWithResponse request - ListPoliciesWithResponse(ctx context.Context, teamName TeamName, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) - - // CreatePolicyWithBodyWithResponse request with any body - CreatePolicyWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) - - CreatePolicyWithResponse(ctx context.Context, teamName TeamName, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) - - // ListAllFrameworksWithResponse request - ListAllFrameworksWithResponse(ctx context.Context, teamName TeamName, params *ListAllFrameworksParams, reqEditors ...RequestEditorFn) (*ListAllFrameworksResponse, error) - - // DeletePolicyWithResponse request - DeletePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) - - // GetPolicyWithResponse request - GetPolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) - - // UpdatePolicyWithBodyWithResponse request with any body - UpdatePolicyWithBodyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) - - UpdatePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) - - // ListPolicyFrameworksWithResponse request - ListPolicyFrameworksWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyFrameworksParams, reqEditors ...RequestEditorFn) (*ListPolicyFrameworksResponse, error) - - // ListPolicyRulesWithResponse request - ListPolicyRulesWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyRulesParams, reqEditors ...RequestEditorFn) (*ListPolicyRulesResponse, error) - - // ListPolicyRuleDetailsWithResponse request - ListPolicyRuleDetailsWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, ruleId openapi_types.UUID, params *ListPolicyRuleDetailsParams, reqEditors ...RequestEditorFn) (*ListPolicyRuleDetailsResponse, error) - - // TogglePolicyWithResponse request - TogglePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *TogglePolicyParams, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) - - // GetPolicyViolationsHistoryWithResponse request - GetPolicyViolationsHistoryWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) - - // ListAllQueriesTeamWithResponse request - ListAllQueriesTeamWithResponse(ctx context.Context, teamName TeamName, params *ListAllQueriesTeamParams, reqEditors ...RequestEditorFn) (*ListAllQueriesTeamResponse, error) - - // ExecuteAdHocQueryTeamWithBodyWithResponse request with any body - ExecuteAdHocQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryTeamResponse, error) - - ExecuteAdHocQueryTeamWithResponse(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, body ExecuteAdHocQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryTeamResponse, error) - - // SaveQueryTeamWithBodyWithResponse request with any body - SaveQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryTeamResponse, error) - - SaveQueryTeamWithResponse(ctx context.Context, teamName TeamName, body SaveQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryTeamResponse, error) - - // ListQueryTagsTeamWithResponse request - ListQueryTagsTeamWithResponse(ctx context.Context, teamName TeamName, params *ListQueryTagsTeamParams, reqEditors ...RequestEditorFn) (*ListQueryTagsTeamResponse, error) - - // DeleteSavedQueryTeamWithResponse request - DeleteSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryTeamResponse, error) - - // GetSavedQueryTeamWithResponse request - GetSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryTeamResponse, error) - - // UpdateQueryTeamWithBodyWithResponse request with any body - UpdateQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryTeamResponse, error) - - UpdateQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, body UpdateQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryTeamResponse, error) - - // DeleteAlertWithResponse request - DeleteAlertWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) - - // ExecuteSavedQueryTeamWithResponse request - ExecuteSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *ExecuteSavedQueryTeamParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryTeamResponse, error) - - // QueryListFiltersTeamWithResponse request - QueryListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFiltersTeamParams, reqEditors ...RequestEditorFn) (*QueryListFiltersTeamResponse, error) - - // QuerySaveFilterTeamWithBodyWithResponse request with any body - QuerySaveFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterTeamResponse, error) - - QuerySaveFilterTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, body QuerySaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterTeamResponse, error) - - // QueryListFilterTagsTeamWithResponse request - QueryListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsTeamResponse, error) - - // ListAllRBACPermissionsWithResponse request - ListAllRBACPermissionsWithResponse(ctx context.Context, teamName TeamName, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) - - // CreateRBACPermissionWithBodyWithResponse request with any body - CreateRBACPermissionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) - - CreateRBACPermissionWithResponse(ctx context.Context, teamName TeamName, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) - - // DeleteRBACPermissionWithResponse request - DeleteRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) - - // GetRBACPermissionWithResponse request - GetRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) - - // UpdateRBACPermissionWithBodyWithResponse request with any body - UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) - - UpdateRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) - - // ListAllRBACRolesWithResponse request - ListAllRBACRolesWithResponse(ctx context.Context, teamName TeamName, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) - - // CreateRBACRoleWithBodyWithResponse request with any body - CreateRBACRoleWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) - - CreateRBACRoleWithResponse(ctx context.Context, teamName TeamName, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) - - // DeleteRBACRoleWithResponse request - DeleteRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) - - // GetRBACRoleWithResponse request - GetRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) - - // UpdateRBACRoleWithBodyWithResponse request with any body - UpdateRBACRoleWithBodyWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) - - UpdateRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) - - // ListReportsWithResponse request - ListReportsWithResponse(ctx context.Context, teamName TeamName, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) - - // CreateReportWithBodyWithResponse request with any body - CreateReportWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) - - CreateReportWithResponse(ctx context.Context, teamName TeamName, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) - - // ListReportTemplatesWithResponse request - ListReportTemplatesWithResponse(ctx context.Context, teamName TeamName, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) - - // CreateReportTemplateWithBodyWithResponse request with any body - CreateReportTemplateWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) - - CreateReportTemplateWithResponse(ctx context.Context, teamName TeamName, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) - - // DeleteReportTemplateWithResponse request - DeleteReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) - - // GetReportTemplateWithResponse request - GetReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) - - // UpdateReportTemplateWithBodyWithResponse request with any body - UpdateReportTemplateWithBodyWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) - - UpdateReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) - - // DeleteReportWithResponse request - DeleteReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) - - // GetReportWithResponse request - GetReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) - - // UpdateReportWithBodyWithResponse request with any body - UpdateReportWithBodyWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) - - UpdateReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) - - // CreateSyncDestinationTestConnectionWithBodyWithResponse request with any body - CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) - - CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) - - // GetSyncDestinationTestConnectionWithResponse request - GetSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) - - // UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) - - UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) - - // GetSyncDestinationTestConnectionLogsWithResponse request - GetSyncDestinationTestConnectionLogsWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsResponse, error) - - // GetSyncDestinationTestConnectionLogsLiveWithResponse request - GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) - - // GetSyncDestinationTestConnectionLogsQueryWithResponse request - GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) - - // PromoteSyncDestinationTestConnectionWithBodyWithResponse request with any body - PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) - - PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) - - // ListSyncDestinationsWithResponse request - ListSyncDestinationsWithResponse(ctx context.Context, teamName TeamName, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) - - // DeleteSyncDestinationWithResponse request - DeleteSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) - - // GetSyncDestinationWithResponse request - GetSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) - - // UpdateSyncDestinationWithBodyWithResponse request with any body - UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) - - UpdateSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) - - // MigrateSyncDestinationWithResponse request - MigrateSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*MigrateSyncDestinationResponse, error) - - // ListSyncDestinationSyncsWithResponse request - ListSyncDestinationSyncsWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) - - // GetTestConnectionForSyncDestinationWithResponse request - GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) - - // CreateSyncSourceTestConnectionWithBodyWithResponse request with any body - CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) - - CreateSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) - - // GetSyncSourceTestConnectionWithResponse request - GetSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) - - // UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) - - UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) - - // GetSyncSourceTestConnectionLogsWithResponse request - GetSyncSourceTestConnectionLogsWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsResponse, error) - - // GetSyncSourceTestConnectionLogsLiveWithResponse request - GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) - - // GetSyncSourceTestConnectionLogsQueryWithResponse request - GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) - - // PromoteSyncSourceTestConnectionWithBodyWithResponse request with any body - PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) - - PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) - - // ListSyncSourcesWithResponse request - ListSyncSourcesWithResponse(ctx context.Context, teamName TeamName, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) - - // DeleteSyncSourceWithResponse request - DeleteSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) - - // GetSyncSourceWithResponse request - GetSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) - - // UpdateSyncSourceWithBodyWithResponse request with any body - UpdateSyncSourceWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) - - UpdateSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) - - // MigrateSyncSourceWithResponse request - MigrateSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*MigrateSyncSourceResponse, error) - - // ListSyncSourceSyncsWithResponse request - ListSyncSourceSyncsWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) - - // GetTestConnectionForSyncSourceWithResponse request - GetTestConnectionForSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) - - // ListSyncTransformersWithResponse request - ListSyncTransformersWithResponse(ctx context.Context, teamName TeamName, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) - - // DeleteSyncTransformerWithResponse request - DeleteSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) - - // GetSyncTransformerWithResponse request - GetSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) - - // UpdateSyncTransformerWithBodyWithResponse request with any body - UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) - - UpdateSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) - - // ListSyncTransformerSyncDestinationsWithResponse request - ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) - - // ListSyncTransformerSyncsWithResponse request - ListSyncTransformerSyncsWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) - - // ListSyncUpgradesWithResponse request - ListSyncUpgradesWithResponse(ctx context.Context, teamName TeamName, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) - - // ListSyncsWithResponse request - ListSyncsWithResponse(ctx context.Context, teamName TeamName, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) - - // CreateSyncWithBodyWithResponse request with any body - CreateSyncWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) - - CreateSyncWithResponse(ctx context.Context, teamName TeamName, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) - - // GetTestConnectionConnectorCredentialsWithResponse request - GetTestConnectionConnectorCredentialsWithResponse(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetTestConnectionConnectorCredentialsResponse, error) - - // GetTestConnectionConnectorIdentityWithResponse request - GetTestConnectionConnectorIdentityWithResponse(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetTestConnectionConnectorIdentityResponse, error) - - // DeleteSyncWithResponse request - DeleteSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) - - // GetSyncWithResponse request - GetSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) - - // UpdateSyncWithBodyWithResponse request with any body - UpdateSyncWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) - - UpdateSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) - - // ListSyncRunsWithResponse request - ListSyncRunsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) - - // CreateSyncRunWithResponse request - CreateSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) - - // GetSyncRunWithResponse request - GetSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) - - // UpdateSyncRunWithBodyWithResponse request with any body - UpdateSyncRunWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) - - UpdateSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) - - // GetSyncRunConnectorCredentialsWithResponse request - GetSyncRunConnectorCredentialsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetSyncRunConnectorCredentialsResponse, error) - - // GetSyncRunConnectorIdentityWithResponse request - GetSyncRunConnectorIdentityWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetSyncRunConnectorIdentityResponse, error) - - // GetSyncRunLogsWithResponse request - GetSyncRunLogsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsResponse, error) - - // GetSyncRunLogsLiveWithResponse request - GetSyncRunLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) - - // GetSyncRunLogsQueryWithResponse request - GetSyncRunLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) - - // CreateSyncRunProgressWithBodyWithResponse request with any body - CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) - - CreateSyncRunProgressWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) - - // GetSyncRunStatsWithResponse request - GetSyncRunStatsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) - - // GetSyncRunTablesWithResponse request - GetSyncRunTablesWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) - - // ListTablesTeamWithResponse request - ListTablesTeamWithResponse(ctx context.Context, teamName TeamName, params *ListTablesTeamParams, reqEditors ...RequestEditorFn) (*ListTablesTeamResponse, error) - - // BatchTableSchemasTeamWithResponse request - BatchTableSchemasTeamWithResponse(ctx context.Context, teamName TeamName, params *BatchTableSchemasTeamParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasTeamResponse, error) - - // TableListColumnsTeamWithResponse request - TableListColumnsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListColumnsTeamParams, reqEditors ...RequestEditorFn) (*TableListColumnsTeamResponse, error) - - // TableColumnListValuesTeamWithResponse request - TableColumnListValuesTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, columnName ColumnName, params *TableColumnListValuesTeamParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesTeamResponse, error) - - // TableListRowsTeamWithResponse request - TableListRowsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRowsTeamParams, reqEditors ...RequestEditorFn) (*TableListRowsTeamResponse, error) - - // TableRowByIdTeamWithResponse request - TableRowByIdTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, tableRowId TableRowId, params *TableRowByIdTeamParams, reqEditors ...RequestEditorFn) (*TableRowByIdTeamResponse, error) - - // TableListFiltersTeamWithResponse request - TableListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFiltersTeamParams, reqEditors ...RequestEditorFn) (*TableListFiltersTeamResponse, error) - - // TableSaveFilterTeamWithBodyWithResponse request with any body - TableSaveFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterTeamResponse, error) - - TableSaveFilterTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, body TableSaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterTeamResponse, error) - - // TableListFilterTagsTeamWithResponse request - TableListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsTeamResponse, error) - - // TableListRelationsTeamWithResponse request - TableListRelationsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRelationsTeamParams, reqEditors ...RequestEditorFn) (*TableListRelationsTeamResponse, error) - - // TableSchemaTeamWithResponse request - TableSchemaTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaTeamResponse, error) - - // GetTeamUsageSummaryWithResponse request - GetTeamUsageSummaryWithResponse(ctx context.Context, teamName TeamName, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) - - // GetGroupedTeamUsageSummaryWithResponse request - GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, teamName TeamName, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) - - // ListUsersByTeamWithResponse request - ListUsersByTeamWithResponse(ctx context.Context, teamName TeamName, params *ListUsersByTeamParams, reqEditors ...RequestEditorFn) (*ListUsersByTeamResponse, error) - - // UploadImageWithBodyWithResponse request with any body - UploadImageWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadImageResponse, error) - - UploadImageWithResponse(ctx context.Context, body UploadImageJSONRequestBody, reqEditors ...RequestEditorFn) (*UploadImageResponse, error) - - // GetCurrentUserWithResponse request - GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) - - // UpdateCurrentUserWithBodyWithResponse request with any body - UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) - - UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) - - // SendAnonymousEventWithBodyWithResponse request with any body - SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) - - SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) - - // AuthenticateLocalUserWithBodyWithResponse request with any body - AuthenticateLocalUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateLocalUserResponse, error) - - AuthenticateLocalUserWithResponse(ctx context.Context, body AuthenticateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateLocalUserResponse, error) - - // ChangeLocalUserPasswordWithBodyWithResponse request with any body - ChangeLocalUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeLocalUserPasswordResponse, error) - - ChangeLocalUserPasswordWithResponse(ctx context.Context, body ChangeLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeLocalUserPasswordResponse, error) - - // UpdateCustomerWithBodyWithResponse request with any body - UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) - - UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) - - // SendUserEventWithBodyWithResponse request with any body - SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) - - SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) - - // ListCurrentUserInvitationsWithResponse request - ListCurrentUserInvitationsWithResponse(ctx context.Context, params *ListCurrentUserInvitationsParams, reqEditors ...RequestEditorFn) (*ListCurrentUserInvitationsResponse, error) - - // GetCurrentLocalUserWithResponse request - GetCurrentLocalUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentLocalUserResponse, error) - - // LogoutUserWithResponse request - LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) - - // LoginUserWithBodyWithResponse request with any body - LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) - - LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) - - // GetCurrentUserMembershipsWithResponse request - GetCurrentUserMembershipsWithResponse(ctx context.Context, params *GetCurrentUserMembershipsParams, reqEditors ...RequestEditorFn) (*GetCurrentUserMembershipsResponse, error) - - // ResetLocalUserPasswordWithBodyWithResponse request with any body - ResetLocalUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ResetLocalUserPasswordResponse, error) - - ResetLocalUserPasswordWithResponse(ctx context.Context, body ResetLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ResetLocalUserPasswordResponse, error) - - // CreateUserTokenWithResponse request - CreateUserTokenWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateUserTokenResponse, error) - - // UserTOTPDeleteWithResponse request - UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) - - // UserTOTPSetupWithResponse request - UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) - - // UserTOTPVerifyWithBodyWithResponse request with any body - UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) - - UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) - - // DeleteUserWithResponse request - DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) - - // CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with any body - CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) - - CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) - - // GetV2SyncDestinationsWithResponse request - GetV2SyncDestinationsWithResponse(ctx context.Context, teamName TeamName, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) - - // CreateV2SyncDestinationWithBodyWithResponse request with any body - CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) - - CreateV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) - - // DeleteV2SyncDestinationWithResponse request - DeleteV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) - - // GetV2SyncDestinationWithResponse request - GetV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) - - // PatchV2SyncDestinationWithBodyWithResponse request with any body - PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) - - PatchV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) - - // CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with any body - CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) - - CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) - - // ListV2SyncIntegrationsWithResponse request - ListV2SyncIntegrationsWithResponse(ctx context.Context, teamName TeamName, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) - - // CreateV2SyncIntegrationWithBodyWithResponse request with any body - CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) - - CreateV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) - - // DeleteV2SyncIntegrationWithResponse request - DeleteV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) - - // GetV2SyncIntegrationWithResponse request - GetV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) - - // UpdateV2SyncIntegrationWithBodyWithResponse request with any body - UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) - - UpdateV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) -} - -type IndexResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *struct { - Errors *[]string `json:"errors,omitempty"` - FieldErrors *map[string]string `json:"field_errors,omitempty"` - Message string `json:"message"` - Status int `json:"status"` - } -} - -// Status returns HTTPResponse.Status -func (r IndexResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r IndexResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAuditLogsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []AuditLogEvent `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAuditLogsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAuditLogsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetAuditLogResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *AuditLogEvent - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetAuditLogResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetAuditLogResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type HealthCheckResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON500 *InternalError - JSON503 *ServiceUnavailable -} - -// Status returns HTTPResponse.Status -func (r HealthCheckResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r HealthCheckResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type HealthCheckHeadResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON500 *InternalError - JSON503 *ServiceUnavailable -} - -// Status returns HTTPResponse.Status -func (r HealthCheckHeadResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r HealthCheckHeadResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AssetViewGetStatusResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // IsRunning Whether the assetview is currently running - IsRunning bool `json:"is_running"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AssetViewGetStatusResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AssetViewGetStatusResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AssetViewTriggerResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON403 *Forbidden - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AssetViewTriggerResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AssetViewTriggerResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AssetViewListLogsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []AssetViewRun `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AssetViewListLogsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AssetViewListLogsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageGetSAMLResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SAMLConfig - JSON400 *BadRequest - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageGetSAMLResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageGetSAMLResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageUpdateSAMLResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SAMLConfig - JSON400 *BadRequest - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageUpdateSAMLResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageUpdateSAMLResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageGetPlatformRegistryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // ActivationID Activation ID - ActivationID *openapi_types.UUID `json:"activation_id,omitempty"` - - // APIKeyLastFour Last 4 characters of the API key - APIKeyLastFour *string `json:"api_key_last_four,omitempty"` - - // InstallationID Installation ID - InstallationID string `json:"installation_id"` - - // LastActivatedAt Timestamp of the last activation - LastActivatedAt *time.Time `json:"last_activated_at,omitempty"` - - // NextActivationAt Timestamp of the next activation - NextActivationAt *time.Time `json:"next_activation_at,omitempty"` - - // OfflineLicenseExpiresAt Timestamp of the offline license expiration - OfflineLicenseExpiresAt *time.Time `json:"offline_license_expires_at,omitempty"` - - // OfflineLicenseRegisteredTo Name the offline license is registered to - OfflineLicenseRegisteredTo *string `json:"offline_license_registered_to,omitempty"` - - // TeamName Name of the team that was activated - TeamName *string `json:"team_name,omitempty"` - } - JSON400 *BadRequest - JSON404 *NotFound - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageGetPlatformRegistryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageGetPlatformRegistryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageRegisterPlatformResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // TeamName Name of the team that was activated - TeamName string `json:"team_name"` - } - JSON205 *struct { - // ButtonText Text for the button - ButtonText *string `json:"button_text,omitempty"` - - // ButtonURL URL for the button - ButtonURL *string `json:"button_url,omitempty"` - - // Error Error message - Error string `json:"error"` - } - JSON400 *BadRequest - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageRegisterPlatformResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageRegisterPlatformResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageRegisterPlatformWithOfflineLicenseResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // ExpiresAt Timestamp of the offline license expiration - ExpiresAt time.Time `json:"expires_at"` - - // RegisteredTo Name the offline license is registered to - RegisteredTo string `json:"registered_to"` - } - JSON400 *BadRequest - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageRegisterPlatformWithOfflineLicenseResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageRegisterPlatformWithOfflineLicenseResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSettingsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PlatformSettings - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSettingsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSettingsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSettingsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PlatformSettings - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSettingsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSettingsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageListAllTeamsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Team `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageListAllTeamsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageListAllTeamsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageDeleteTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageDeleteTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageDeleteTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageGetTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Team - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageGetTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageGetTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageRemoveTeamMemberResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageRemoveTeamMemberResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageRemoveTeamMemberResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageListTeamMembersResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []MembershipWithUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageListTeamMembersResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageListTeamMembersResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageAddTeamMemberResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageAddTeamMemberResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageAddTeamMemberResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListLocalUsersResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []LocalUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListLocalUsersResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListLocalUsersResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AddLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *LocalUser - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AddLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AddLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *LocalUserWithTeams - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *LocalUser - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateLocalUserResetTokenResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - ResetToken string `json:"reset_token"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateLocalUserResetTokenResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateLocalUserResetTokenResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ManageUserTOTPDeleteResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ManageUserTOTPDeleteResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ManageUserTOTPDeleteResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetOpenAPIJSONResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *map[string]interface{} - JSON400 *BadRequest -} - -// Status returns HTTPResponse.Status -func (r GetOpenAPIJSONResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetOpenAPIJSONResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPlatformInfoResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - PublicIps *[]string `json:"public_ips,omitempty"` - } - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetPlatformInfoResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPlatformInfoResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPlatformVersionsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []PlatformVersion `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPlatformVersionsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPlatformVersionsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPluginsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items ListPlugins `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPluginsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPluginsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreatePluginResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *Plugin - JSON400 *BadRequest - JSON403 *Forbidden - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreatePluginResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreatePluginResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeletePluginByTeamAndPluginNameResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeletePluginByTeamAndPluginNameResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeletePluginByTeamAndPluginNameResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPluginResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ListPlugin - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetPluginResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPluginResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdatePluginResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Plugin - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdatePluginResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdatePluginResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPluginVersionsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []PluginVersionList `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPluginVersionsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPluginVersionsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPluginVersionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginVersionDetails - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetPluginVersionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPluginVersionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdatePluginVersionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginVersion - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdatePluginVersionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdatePluginVersionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreatePluginVersionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginVersion - JSON201 *PluginVersion - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreatePluginVersionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreatePluginVersionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DownloadPluginAssetResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginAsset - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DownloadPluginAssetResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DownloadPluginAssetResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UploadPluginAssetResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *ReleaseURL - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UploadPluginAssetResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UploadPluginAssetResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeletePluginVersionDocsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeletePluginVersionDocsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeletePluginVersionDocsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPluginVersionDocsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []PluginDocsPage `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPluginVersionDocsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPluginVersionDocsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ReplacePluginVersionDocsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Names *[]PluginDocsPageName `json:"names,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ReplacePluginVersionDocsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ReplacePluginVersionDocsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreatePluginVersionDocsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Names *[]PluginDocsPageName `json:"names,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreatePluginVersionDocsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreatePluginVersionDocsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeletePluginVersionTablesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeletePluginVersionTablesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeletePluginVersionTablesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPluginVersionTablesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []PluginTable `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPluginVersionTablesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPluginVersionTablesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreatePluginVersionTablesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Names *[]PluginTableName `json:"names,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreatePluginVersionTablesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreatePluginVersionTablesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPluginVersionTableResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginTableDetails - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetPluginVersionTableResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPluginVersionTableResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type RemovePluginUIAssetsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r RemovePluginUIAssetsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r RemovePluginUIAssetsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UploadPluginUIAssetsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Assets []PluginUIAsset `json:"assets"` - - // UIID ID representing this upload - UIID string `json:"ui_id"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON409 *Conflict - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UploadPluginUIAssetsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UploadPluginUIAssetsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type FinalizePluginUIAssetUploadResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r FinalizePluginUIAssetUploadResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r FinalizePluginUIAssetUploadResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthRegistryRequestResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *RegistryAuthToken - JSON400 *DockerError - JSON401 *DockerError - JSON404 *DockerError - JSON422 *DockerError - JSON500 *DockerError -} - -// Status returns HTTPResponse.Status -func (r AuthRegistryRequestResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthRegistryRequestResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListTeamsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Team `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListTeamsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListTeamsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *Team - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTeamByNameResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Team - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTeamByNameResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTeamByNameResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Team - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllAlertsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []AlertDetail `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllAlertsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllAlertsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TestUnsavedAlertResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Results Notification results for the test alert - Results []AlertTestResponse `json:"results"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TestUnsavedAlertResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TestUnsavedAlertResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListTeamAPIKeysResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // AllowedRoles List of allowed roles when creating a new API key - AllowedRoles []APIKeyTeamRole `json:"allowed_roles"` - Items []APIKey `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListTeamAPIKeysResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListTeamAPIKeysResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateTeamAPIKeyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *APIKey - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateTeamAPIKeyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateTeamAPIKeyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteTeamAPIKeyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteTeamAPIKeyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteTeamAPIKeyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListConnectorsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Connector `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListConnectorsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListConnectorsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateConnectorResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *Connector - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateConnectorResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateConnectorResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetConnectorResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Connector - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetConnectorResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetConnectorResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateConnectorResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Connector - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateConnectorResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateConnectorResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type RevokeConnectorResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r RevokeConnectorResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r RevokeConnectorResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetConnectorAuthStatusAWSResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // ExternalID External ID used for the role - ExternalID *string `json:"external_id,omitempty"` - - // RoleARN ARN of role created by the user - RoleARN *string `json:"role_arn,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetConnectorAuthStatusAWSResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetConnectorAuthStatusAWSResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorFinishAWSResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorFinishAWSResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorFinishAWSResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorAWSResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ConnectorAuthResponseAWS - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorAWSResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorAWSResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetConnectorAuthStatusGCPResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // ServiceAccount CloudQuery GCP Service Account to grant access to - ServiceAccount *string `json:"service_account,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetConnectorAuthStatusGCPResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetConnectorAuthStatusGCPResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorGCPResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ConnectorAuthResponseGCP - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorGCPResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorGCPResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorFinishGCPResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorFinishGCPResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorFinishGCPResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorFinishOAuthResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ConnectorAuthResponseOAuth - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorFinishOAuthResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorFinishOAuthResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateConnectorOAuthResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ConnectorAuthResponseOAuth - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateConnectorOAuthResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateConnectorOAuthResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateConversationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *Conversation - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateConversationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateConversationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetConversationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Conversation - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetConversationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetConversationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type SendMessageResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *ConversationMessage - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r SendMessageResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r SendMessageResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllCustomColumnsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []CustomColumn `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllCustomColumnsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllCustomColumnsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type SaveCustomColumnResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *CustomColumn - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r SaveCustomColumnResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r SaveCustomColumnResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteCustomColumnResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteCustomColumnResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteCustomColumnResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetCustomColumnResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *CustomColumn - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetCustomColumnResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetCustomColumnResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateCustomColumnResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *CustomColumn - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateCustomColumnResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateCustomColumnResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type PutCustomColumnDataResponse struct { - Body []byte - HTTPResponse *http.Response - JSON202 *struct { - Data CustomColumnDataImportAccepted `json:"data"` - } - JSON400 *BadRequest - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r PutCustomColumnDataResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r PutCustomColumnDataResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type PutCustomColumnValuesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *map[string]interface{} - JSON400 *BadRequest - JSON404 *NotFound - JSON422 *UnprocessableEntity -} - -// Status returns HTTPResponse.Status -func (r PutCustomColumnValuesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r PutCustomColumnValuesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListFiltersTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListFiltersTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListFiltersTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListFilterTagsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListFilterTagsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListFilterTagsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteFilterTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteFilterTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteFilterTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetFilterByIDTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Filter - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetFilterByIDTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetFilterByIDTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateFilterTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Filter - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateFilterTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateFilterTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateTeamImagesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Items []TeamImage `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateTeamImagesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateTeamImagesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteTeamInvitationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteTeamInvitationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteTeamInvitationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListTeamInvitationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Invitation `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListTeamInvitationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListTeamInvitationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AcceptTeamInvitationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *MembershipWithTeam - JSON303 *MembershipWithTeam - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AcceptTeamInvitationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AcceptTeamInvitationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type RemoveTeamMembershipResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r RemoveTeamMembershipResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r RemoveTeamMembershipResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTeamMembershipsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []MembershipWithUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTeamMembershipsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTeamMembershipsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteTeamMembershipResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteTeamMembershipResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteTeamMembershipResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *NotificationDestination - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *NotificationDestination - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetNotificationDestinationAlertsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []AlertDetail `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetNotificationDestinationAlertsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetNotificationDestinationAlertsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TestNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *NotificationDestinationTestResponse - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TestNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TestNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllNotificationDestinationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []NotificationDestinationListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllNotificationDestinationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllNotificationDestinationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *NotificationDestination - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TestUnsavedNotificationDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *NotificationDestinationTestResponse - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TestUnsavedNotificationDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TestUnsavedNotificationDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateAWSOnboardingResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *OnboardingAWSCreateResponse - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateAWSOnboardingResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateAWSOnboardingResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetAWSOnboardingResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *OnboardingAWS - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetAWSOnboardingResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetAWSOnboardingResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetAWSAccountsInRootResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *OnboardingAWSAccounts - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetAWSAccountsInRootResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetAWSAccountsInRootResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ProvisionOnboardingConfigurationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ProvisionOnboardingConfigurationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ProvisionOnboardingConfigurationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetAWSAccountsInParentResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *OnboardingAWSAccounts - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetAWSAccountsInParentResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetAWSAccountsInParentResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type NotifyOnboardingResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r NotifyOnboardingResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r NotifyOnboardingResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeletePluginsByTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeletePluginsByTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeletePluginsByTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPluginsByTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Plugin `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListPluginsByTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPluginsByTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DownloadPluginAssetByTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *PluginAsset - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DownloadPluginAssetByTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DownloadPluginAssetByTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPoliciesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Metadata ListMetadata `json:"metadata"` - Policies []PlatformPolicy `json:"policies"` - } - JSON400 *BadRequest - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListPoliciesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPoliciesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreatePolicyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Data PlatformPolicy `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden -} - -// Status returns HTTPResponse.Status -func (r CreatePolicyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreatePolicyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllFrameworksResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Frameworks []PlatformPolicyFramework `json:"frameworks"` - Metadata ListMetadata `json:"metadata"` - } - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListAllFrameworksResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllFrameworksResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeletePolicyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r DeletePolicyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeletePolicyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPolicyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data PlatformPolicy `json:"data"` - } - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r GetPolicyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPolicyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdatePolicyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data PlatformPolicy `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r UpdatePolicyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdatePolicyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPolicyFrameworksResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Frameworks []PlatformPolicyFramework `json:"frameworks"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListPolicyFrameworksResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPolicyFrameworksResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPolicyRulesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Metadata ListMetadata `json:"metadata"` - Rules []PlatformPolicyRule `json:"rules"` - } - JSON400 *BadRequest - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListPolicyRulesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPolicyRulesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListPolicyRuleDetailsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Details []PlatformPolicyRuleDetail `json:"details"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListPolicyRuleDetailsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListPolicyRuleDetailsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TogglePolicyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r TogglePolicyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TogglePolicyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetPolicyViolationsHistoryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Details []PlatformPolicyViolationHistory `json:"details"` - } - JSON400 *BadRequest -} - -// Status returns HTTPResponse.Status -func (r GetPolicyViolationsHistoryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetPolicyViolationsHistoryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllQueriesTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Query `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllQueriesTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllQueriesTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ExecuteAdHocQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ExecuteAdHocQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ExecuteAdHocQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type SaveQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *QueryDetail - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r SaveQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r SaveQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListQueryTagsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []QueryTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListQueryTagsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListQueryTagsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteSavedQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteSavedQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteSavedQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSavedQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *QueryDetail - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSavedQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSavedQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *QueryDetail - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteAlertResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteAlertResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteAlertResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ExecuteSavedQueryTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ExecuteSavedQueryTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ExecuteSavedQueryTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type QueryListFiltersTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r QueryListFiltersTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r QueryListFiltersTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type QuerySaveFilterTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Filter - JSON201 *Filter - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r QuerySaveFilterTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r QuerySaveFilterTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type QueryListFilterTagsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r QueryListFilterTagsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r QueryListFilterTagsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllRBACPermissionsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []RBACPermission `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllRBACPermissionsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllRBACPermissionsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateRBACPermissionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *RBACPermission - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateRBACPermissionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateRBACPermissionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteRBACPermissionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteRBACPermissionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteRBACPermissionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetRBACPermissionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *RBACPermission - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetRBACPermissionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetRBACPermissionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateRBACPermissionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *RBACPermission - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateRBACPermissionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateRBACPermissionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListAllRBACRolesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []RBACRole `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListAllRBACRolesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllRBACRolesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateRBACRoleResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *RBACRole - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateRBACRoleResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateRBACRoleResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteRBACRoleResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteRBACRoleResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteRBACRoleResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetRBACRoleResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *RBACRole - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetRBACRoleResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetRBACRoleResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateRBACRoleResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *RBACRole - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateRBACRoleResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateRBACRoleResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListReportsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Metadata ListMetadata `json:"metadata"` - Reports []Report `json:"reports"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListReportsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListReportsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateReportResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Data Report `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden -} - -// Status returns HTTPResponse.Status -func (r CreateReportResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateReportResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListReportTemplatesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Metadata ListMetadata `json:"metadata"` - Templates []ReportTemplate `json:"templates"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r ListReportTemplatesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListReportTemplatesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateReportTemplateResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - Data ReportTemplate `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden -} - -// Status returns HTTPResponse.Status -func (r CreateReportTemplateResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateReportTemplateResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteReportTemplateResponse struct { - Body []byte - HTTPResponse *http.Response - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r DeleteReportTemplateResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteReportTemplateResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetReportTemplateResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data ReportTemplate `json:"data"` - } - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r GetReportTemplateResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetReportTemplateResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateReportTemplateResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data ReportTemplate `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r UpdateReportTemplateResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateReportTemplateResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteReportResponse struct { - Body []byte - HTTPResponse *http.Response - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r DeleteReportResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteReportResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetReportResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data Report `json:"data"` - } - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r GetReportResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetReportResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateReportResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data Report `json:"data"` - } - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound -} - -// Status returns HTTPResponse.Status -func (r UpdateReportResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateReportResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateSyncDestinationTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncDestinationTestConnection - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateSyncDestinationTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateSyncDestinationTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncDestinationTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestinationTestConnection - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncDestinationTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncDestinationTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncTestConnectionForSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestinationTestConnection - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncTestConnectionForSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncTestConnectionForSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncDestinationTestConnectionLogsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Location The location to download the test connection logs from - Location string `json:"location"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncDestinationTestConnectionLogsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncDestinationTestConnectionLogsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncDestinationTestConnectionLogsLiveResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncDestinationTestConnectionLogsLiveResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncDestinationTestConnectionLogsLiveResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncDestinationTestConnectionLogsQueryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncDestinationTestConnectionLogsQueryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncDestinationTestConnectionLogsQueryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type PromoteSyncDestinationTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestination - JSON201 *SyncDestination - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r PromoteSyncDestinationTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r PromoteSyncDestinationTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncDestinationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncDestination `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncDestinationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncDestinationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestination - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestination - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type MigrateSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r MigrateSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r MigrateSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncDestinationSyncsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []ListSync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncDestinationSyncsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncDestinationSyncsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTestConnectionForSyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncTestConnection - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTestConnectionForSyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTestConnectionForSyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateSyncSourceTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncSourceTestConnection - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateSyncSourceTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateSyncSourceTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncSourceTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncSourceTestConnection - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncSourceTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncSourceTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncTestConnectionForSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncSourceTestConnection - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncTestConnectionForSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncTestConnectionForSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncSourceTestConnectionLogsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Location The location to download the test connection logs from - Location string `json:"location"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncSourceTestConnectionLogsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncSourceTestConnectionLogsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncSourceTestConnectionLogsLiveResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncSourceTestConnectionLogsLiveResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncSourceTestConnectionLogsLiveResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncSourceTestConnectionLogsQueryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncSourceTestConnectionLogsQueryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncSourceTestConnectionLogsQueryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type PromoteSyncSourceTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncSource - JSON201 *SyncSource - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r PromoteSyncSourceTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r PromoteSyncSourceTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncSourcesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncSource `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncSourcesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncSourcesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncSource - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncSource - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type MigrateSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r MigrateSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r MigrateSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncSourceSyncsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []ListSync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncSourceSyncsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncSourceSyncsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTestConnectionForSyncSourceResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncTestConnection - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTestConnectionForSyncSourceResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTestConnectionForSyncSourceResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncTransformersResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncTransformer `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncTransformersResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncTransformersResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteSyncTransformerResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteSyncTransformerResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteSyncTransformerResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncTransformerResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncTransformer - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncTransformerResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncTransformerResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncTransformerResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncTransformer - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncTransformerResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncTransformerResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncTransformerSyncDestinationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncDestination `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncTransformerSyncDestinationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncTransformerSyncDestinationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncTransformerSyncsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Sync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncTransformerSyncsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncTransformerSyncsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncUpgradesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncUpgrade `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncUpgradesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncUpgradesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []ListSync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateSyncResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *Sync - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateSyncResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateSyncResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTestConnectionConnectorCredentialsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Aws AWS connector credentials response - Aws *ConnectorCredentialsResponseAWS `json:"aws,omitempty"` - - // Oauth OAuth connector credentials response - Oauth *ConnectorCredentialsResponseOAuth `json:"oauth,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTestConnectionConnectorCredentialsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTestConnectionConnectorCredentialsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTestConnectionConnectorIdentityResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Aws AWS connector identity response - Aws *ConnectorIdentityResponseAWS `json:"aws,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTestConnectionConnectorIdentityResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTestConnectionConnectorIdentityResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteSyncResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteSyncResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteSyncResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Sync - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Sync - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListSyncRunsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncRun `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListSyncRunsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListSyncRunsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateSyncRunResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncRun - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateSyncRunResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateSyncRunResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncRunDetails - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateSyncRunResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncRun - JSON400 *BadRequest - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateSyncRunResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateSyncRunResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunConnectorCredentialsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Aws AWS connector credentials response - Aws *ConnectorCredentialsResponseAWS `json:"aws,omitempty"` - - // Oauth OAuth connector credentials response - Oauth *ConnectorCredentialsResponseOAuth `json:"oauth,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunConnectorCredentialsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunConnectorCredentialsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunConnectorIdentityResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Aws AWS connector identity response - Aws *ConnectorIdentityResponseAWS `json:"aws,omitempty"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunConnectorIdentityResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunConnectorIdentityResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunLogsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Location The location to download the sync run logs from - Location string `json:"location"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunLogsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunLogsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunLogsLiveResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunLogsLiveResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunLogsLiveResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunLogsQueryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunLogsQueryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunLogsQueryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateSyncRunProgressResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateSyncRunProgressResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateSyncRunProgressResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunStatsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncRunStats - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunStatsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunStatsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetSyncRunTablesResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncRunTableStat `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetSyncRunTablesResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetSyncRunTablesResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListTablesTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []TableListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListTablesTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListTablesTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type BatchTableSchemasTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []BatchTableSchemaItem `json:"items"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r BatchTableSchemasTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r BatchTableSchemasTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableListColumnsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []TableColumnListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableListColumnsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableListColumnsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableColumnListValuesTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []TableColumnValueListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableColumnListValuesTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableColumnListValuesTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableListRowsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableListRowsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableListRowsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableRowByIdTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data TableRow `json:"data"` - Matches []TableRowFieldMatch `json:"matches"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableRowByIdTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableRowByIdTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableListFiltersTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableListFiltersTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableListFiltersTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableSaveFilterTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *Filter - JSON201 *Filter - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableSaveFilterTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableSaveFilterTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableListFilterTagsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableListFilterTagsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableListFilterTagsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableListRelationsTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Data []TableRelation `json:"data"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableListRelationsTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableListRelationsTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type TableSchemaTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - DefaultColumns []string `json:"default_columns"` - Schema TableSchema `json:"schema"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r TableSchemaTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r TableSchemaTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetTeamUsageSummaryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *UsageSummary - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetTeamUsageSummaryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetTeamUsageSummaryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetGroupedTeamUsageSummaryResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *UsageSummary - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetGroupedTeamUsageSummaryResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetGroupedTeamUsageSummaryResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListUsersByTeamResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []User `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListUsersByTeamResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListUsersByTeamResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UploadImageResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *ImageURL - JSON400 *BadRequest - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UploadImageResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UploadImageResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetCurrentUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - Email string `json:"email"` - EventIdentifiers *map[string]interface{} `json:"event_identifiers,omitempty"` - GroupIdentifier *string `json:"group_identifier,omitempty"` - - // ID ID of the User - ID openapi_types.UUID `json:"id"` - LastLoginAt *time.Time `json:"last_login_at,omitempty"` - - // Name The unique name for the user. - Name *UserName `json:"name,omitempty"` - - // ProfileImageURL Profile image URL of user - ProfileImageURL *string `json:"profile_image_url,omitempty"` - - // RegisteredTeamInternal Whether the team is internal or not - RegisteredTeamInternal *bool `json:"registered_team_internal,omitempty"` - - // RegisteredTeamName The name of the team that the platform is registered with - RegisteredTeamName *string `json:"registered_team_name,omitempty"` - UpdatedAt *time.Time `json:"updated_at,omitempty"` - } - JSON401 *struct { - Message string `json:"message"` - - // PasswordResetRequired Whether the user needs to reset their password - PasswordResetRequired *bool `json:"password_reset_required,omitempty"` - Status int `json:"status"` - } - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetCurrentUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetCurrentUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateCurrentUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *User - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateCurrentUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateCurrentUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type SendAnonymousEventResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON404 *NotFound - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r SendAnonymousEventResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r SendAnonymousEventResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type AuthenticateLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - IDToken string `json:"id_token"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r AuthenticateLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r AuthenticateLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ChangeLocalUserPasswordResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ChangeLocalUserPasswordResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ChangeLocalUserPasswordResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateCustomerResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateCustomerResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateCustomerResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type SendUserEventResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r SendUserEventResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r SendUserEventResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListCurrentUserInvitationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []InvitationWithToken `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListCurrentUserInvitationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListCurrentUserInvitationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetCurrentLocalUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *LocalUserWithTeams - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetCurrentLocalUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetCurrentLocalUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type LogoutUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r LogoutUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r LogoutUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type LoginUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r LoginUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r LoginUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetCurrentUserMembershipsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []MembershipWithTeam `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetCurrentUserMembershipsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetCurrentUserMembershipsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ResetLocalUserPasswordResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ResetLocalUserPasswordResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ResetLocalUserPasswordResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateUserTokenResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *struct { - // CustomToken Token to exchange for refresh token - CustomToken string `json:"custom_token"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateUserTokenResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateUserTokenResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UserTOTPDeleteResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UserTOTPDeleteResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UserTOTPDeleteResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UserTOTPSetupResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Secret string `json:"secret"` - Url string `json:"url"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UserTOTPSetupResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UserTOTPSetupResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UserTOTPVerifyResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UserTOTPVerifyResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UserTOTPVerifyResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteUserResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteUserResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteUserResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateV2SyncDestinationTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncDestinationTestConnectionV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateV2SyncDestinationTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateV2SyncDestinationTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetV2SyncDestinationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncDestinationV2 `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetV2SyncDestinationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetV2SyncDestinationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateV2SyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestinationV2 - JSON201 *SyncDestinationV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateV2SyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateV2SyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteV2SyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteV2SyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteV2SyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetV2SyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestinationV2 - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetV2SyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetV2SyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type PatchV2SyncDestinationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncDestination - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r PatchV2SyncDestinationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r PatchV2SyncDestinationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateV2SyncIntegrationTestConnectionResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncIntegrationTestConnectionV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON429 *TooManyRequests - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateV2SyncIntegrationTestConnectionResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateV2SyncIntegrationTestConnectionResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type ListV2SyncIntegrationsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []SyncIntegrationExpandedV2 `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r ListV2SyncIntegrationsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r ListV2SyncIntegrationsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type CreateV2SyncIntegrationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON201 *SyncIntegrationV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r CreateV2SyncIntegrationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r CreateV2SyncIntegrationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type DeleteV2SyncIntegrationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON405 *MethodNotAllowed - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r DeleteV2SyncIntegrationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r DeleteV2SyncIntegrationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type GetV2SyncIntegrationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncIntegrationExpandedV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r GetV2SyncIntegrationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r GetV2SyncIntegrationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -type UpdateV2SyncIntegrationResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *SyncIntegrationV2 - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} - -// Status returns HTTPResponse.Status -func (r UpdateV2SyncIntegrationResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} - -// StatusCode returns HTTPResponse.StatusCode -func (r UpdateV2SyncIntegrationResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} - -// IndexWithResponse request returning *IndexResponse -func (c *ClientWithResponses) IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) { - rsp, err := c.Index(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseIndexResponse(rsp) -} - -// ListAuditLogsWithResponse request returning *ListAuditLogsResponse -func (c *ClientWithResponses) ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) { - rsp, err := c.ListAuditLogs(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListAuditLogsResponse(rsp) -} - -// GetAuditLogWithResponse request returning *GetAuditLogResponse -func (c *ClientWithResponses) GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) { - rsp, err := c.GetAuditLog(ctx, id, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetAuditLogResponse(rsp) -} - -// HealthCheckWithResponse request returning *HealthCheckResponse -func (c *ClientWithResponses) HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) { - rsp, err := c.HealthCheck(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseHealthCheckResponse(rsp) -} - -// HealthCheckHeadWithResponse request returning *HealthCheckHeadResponse -func (c *ClientWithResponses) HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) { - rsp, err := c.HealthCheckHead(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseHealthCheckHeadResponse(rsp) -} - -// AssetViewGetStatusWithResponse request returning *AssetViewGetStatusResponse -func (c *ClientWithResponses) AssetViewGetStatusWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*AssetViewGetStatusResponse, error) { - rsp, err := c.AssetViewGetStatus(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseAssetViewGetStatusResponse(rsp) -} - -// AssetViewTriggerWithResponse request returning *AssetViewTriggerResponse -func (c *ClientWithResponses) AssetViewTriggerWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*AssetViewTriggerResponse, error) { - rsp, err := c.AssetViewTrigger(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseAssetViewTriggerResponse(rsp) -} - -// AssetViewListLogsWithResponse request returning *AssetViewListLogsResponse -func (c *ClientWithResponses) AssetViewListLogsWithResponse(ctx context.Context, params *AssetViewListLogsParams, reqEditors ...RequestEditorFn) (*AssetViewListLogsResponse, error) { - rsp, err := c.AssetViewListLogs(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseAssetViewListLogsResponse(rsp) -} - -// ManageGetSAMLWithResponse request returning *ManageGetSAMLResponse -func (c *ClientWithResponses) ManageGetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ManageGetSAMLResponse, error) { - rsp, err := c.ManageGetSAML(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageGetSAMLResponse(rsp) -} - -// ManageUpdateSAMLWithBodyWithResponse request with arbitrary body returning *ManageUpdateSAMLResponse -func (c *ClientWithResponses) ManageUpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageUpdateSAMLResponse, error) { - rsp, err := c.ManageUpdateSAMLWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageUpdateSAMLResponse(rsp) -} - -func (c *ClientWithResponses) ManageUpdateSAMLWithResponse(ctx context.Context, body ManageUpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageUpdateSAMLResponse, error) { - rsp, err := c.ManageUpdateSAML(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageUpdateSAMLResponse(rsp) -} - -// ManageGetPlatformRegistryWithResponse request returning *ManageGetPlatformRegistryResponse -func (c *ClientWithResponses) ManageGetPlatformRegistryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ManageGetPlatformRegistryResponse, error) { - rsp, err := c.ManageGetPlatformRegistry(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageGetPlatformRegistryResponse(rsp) -} - -// ManageRegisterPlatformWithBodyWithResponse request with arbitrary body returning *ManageRegisterPlatformResponse -func (c *ClientWithResponses) ManageRegisterPlatformWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformResponse, error) { - rsp, err := c.ManageRegisterPlatformWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRegisterPlatformResponse(rsp) -} - -func (c *ClientWithResponses) ManageRegisterPlatformWithResponse(ctx context.Context, body ManageRegisterPlatformJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformResponse, error) { - rsp, err := c.ManageRegisterPlatform(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRegisterPlatformResponse(rsp) -} - -// ManageRegisterPlatformWithOfflineLicenseWithBodyWithResponse request with arbitrary body returning *ManageRegisterPlatformWithOfflineLicenseResponse -func (c *ClientWithResponses) ManageRegisterPlatformWithOfflineLicenseWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformWithOfflineLicenseResponse, error) { - rsp, err := c.ManageRegisterPlatformWithOfflineLicenseWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRegisterPlatformWithOfflineLicenseResponse(rsp) -} - -func (c *ClientWithResponses) ManageRegisterPlatformWithOfflineLicenseWithResponse(ctx context.Context, body ManageRegisterPlatformWithOfflineLicenseJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRegisterPlatformWithOfflineLicenseResponse, error) { - rsp, err := c.ManageRegisterPlatformWithOfflineLicense(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRegisterPlatformWithOfflineLicenseResponse(rsp) -} - -// GetSettingsWithResponse request returning *GetSettingsResponse -func (c *ClientWithResponses) GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) { - rsp, err := c.GetSettings(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetSettingsResponse(rsp) -} - -// UpdateSettingsWithBodyWithResponse request with arbitrary body returning *UpdateSettingsResponse -func (c *ClientWithResponses) UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) { - rsp, err := c.UpdateSettingsWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateSettingsResponse(rsp) -} - -func (c *ClientWithResponses) UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) { - rsp, err := c.UpdateSettings(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateSettingsResponse(rsp) -} - -// ManageListAllTeamsWithResponse request returning *ManageListAllTeamsResponse -func (c *ClientWithResponses) ManageListAllTeamsWithResponse(ctx context.Context, params *ManageListAllTeamsParams, reqEditors ...RequestEditorFn) (*ManageListAllTeamsResponse, error) { - rsp, err := c.ManageListAllTeams(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageListAllTeamsResponse(rsp) -} - -// ManageDeleteTeamWithResponse request returning *ManageDeleteTeamResponse -func (c *ClientWithResponses) ManageDeleteTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*ManageDeleteTeamResponse, error) { - rsp, err := c.ManageDeleteTeam(ctx, teamName, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageDeleteTeamResponse(rsp) -} - -// ManageGetTeamWithResponse request returning *ManageGetTeamResponse -func (c *ClientWithResponses) ManageGetTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*ManageGetTeamResponse, error) { - rsp, err := c.ManageGetTeam(ctx, teamName, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageGetTeamResponse(rsp) -} - -// ManageRemoveTeamMemberWithBodyWithResponse request with arbitrary body returning *ManageRemoveTeamMemberResponse -func (c *ClientWithResponses) ManageRemoveTeamMemberWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageRemoveTeamMemberResponse, error) { - rsp, err := c.ManageRemoveTeamMemberWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRemoveTeamMemberResponse(rsp) -} - -func (c *ClientWithResponses) ManageRemoveTeamMemberWithResponse(ctx context.Context, teamName TeamName, body ManageRemoveTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageRemoveTeamMemberResponse, error) { - rsp, err := c.ManageRemoveTeamMember(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageRemoveTeamMemberResponse(rsp) -} - -// ManageListTeamMembersWithResponse request returning *ManageListTeamMembersResponse -func (c *ClientWithResponses) ManageListTeamMembersWithResponse(ctx context.Context, teamName TeamName, params *ManageListTeamMembersParams, reqEditors ...RequestEditorFn) (*ManageListTeamMembersResponse, error) { - rsp, err := c.ManageListTeamMembers(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageListTeamMembersResponse(rsp) -} - -// ManageAddTeamMemberWithBodyWithResponse request with arbitrary body returning *ManageAddTeamMemberResponse -func (c *ClientWithResponses) ManageAddTeamMemberWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ManageAddTeamMemberResponse, error) { - rsp, err := c.ManageAddTeamMemberWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageAddTeamMemberResponse(rsp) -} - -func (c *ClientWithResponses) ManageAddTeamMemberWithResponse(ctx context.Context, teamName TeamName, body ManageAddTeamMemberJSONRequestBody, reqEditors ...RequestEditorFn) (*ManageAddTeamMemberResponse, error) { - rsp, err := c.ManageAddTeamMember(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageAddTeamMemberResponse(rsp) -} - -// ListLocalUsersWithResponse request returning *ListLocalUsersResponse -func (c *ClientWithResponses) ListLocalUsersWithResponse(ctx context.Context, params *ListLocalUsersParams, reqEditors ...RequestEditorFn) (*ListLocalUsersResponse, error) { - rsp, err := c.ListLocalUsers(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListLocalUsersResponse(rsp) -} - -// AddLocalUserWithBodyWithResponse request with arbitrary body returning *AddLocalUserResponse -func (c *ClientWithResponses) AddLocalUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddLocalUserResponse, error) { - rsp, err := c.AddLocalUserWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAddLocalUserResponse(rsp) -} - -func (c *ClientWithResponses) AddLocalUserWithResponse(ctx context.Context, body AddLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddLocalUserResponse, error) { - rsp, err := c.AddLocalUser(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAddLocalUserResponse(rsp) -} - -// DeleteLocalUserWithResponse request returning *DeleteLocalUserResponse -func (c *ClientWithResponses) DeleteLocalUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteLocalUserResponse, error) { - rsp, err := c.DeleteLocalUser(ctx, userID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteLocalUserResponse(rsp) -} - -// GetLocalUserWithResponse request returning *GetLocalUserResponse -func (c *ClientWithResponses) GetLocalUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetLocalUserResponse, error) { - rsp, err := c.GetLocalUser(ctx, userID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetLocalUserResponse(rsp) -} - -// UpdateLocalUserWithBodyWithResponse request with arbitrary body returning *UpdateLocalUserResponse -func (c *ClientWithResponses) UpdateLocalUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateLocalUserResponse, error) { - rsp, err := c.UpdateLocalUserWithBody(ctx, userID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateLocalUserResponse(rsp) -} - -func (c *ClientWithResponses) UpdateLocalUserWithResponse(ctx context.Context, userID UserID, body UpdateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateLocalUserResponse, error) { - rsp, err := c.UpdateLocalUser(ctx, userID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateLocalUserResponse(rsp) -} - -// CreateLocalUserResetTokenWithResponse request returning *CreateLocalUserResetTokenResponse -func (c *ClientWithResponses) CreateLocalUserResetTokenWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*CreateLocalUserResetTokenResponse, error) { - rsp, err := c.CreateLocalUserResetToken(ctx, userID, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateLocalUserResetTokenResponse(rsp) -} - -// ManageUserTOTPDeleteWithResponse request returning *ManageUserTOTPDeleteResponse -func (c *ClientWithResponses) ManageUserTOTPDeleteWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*ManageUserTOTPDeleteResponse, error) { - rsp, err := c.ManageUserTOTPDelete(ctx, userID, reqEditors...) - if err != nil { - return nil, err - } - return ParseManageUserTOTPDeleteResponse(rsp) -} - -// GetOpenAPIJSONWithResponse request returning *GetOpenAPIJSONResponse -func (c *ClientWithResponses) GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) { - rsp, err := c.GetOpenAPIJSON(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetOpenAPIJSONResponse(rsp) -} - -// GetPlatformInfoWithResponse request returning *GetPlatformInfoResponse -func (c *ClientWithResponses) GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) { - rsp, err := c.GetPlatformInfo(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetPlatformInfoResponse(rsp) -} - -// ListPlatformVersionsWithResponse request returning *ListPlatformVersionsResponse -func (c *ClientWithResponses) ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) { - rsp, err := c.ListPlatformVersions(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPlatformVersionsResponse(rsp) -} - -// ListPluginsWithResponse request returning *ListPluginsResponse -func (c *ClientWithResponses) ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) { - rsp, err := c.ListPlugins(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPluginsResponse(rsp) -} - -// CreatePluginWithBodyWithResponse request with arbitrary body returning *CreatePluginResponse -func (c *ClientWithResponses) CreatePluginWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginResponse, error) { - rsp, err := c.CreatePluginWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginResponse(rsp) -} - -func (c *ClientWithResponses) CreatePluginWithResponse(ctx context.Context, body CreatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginResponse, error) { - rsp, err := c.CreatePlugin(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginResponse(rsp) -} - -// DeletePluginByTeamAndPluginNameWithResponse request returning *DeletePluginByTeamAndPluginNameResponse -func (c *ClientWithResponses) DeletePluginByTeamAndPluginNameWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*DeletePluginByTeamAndPluginNameResponse, error) { - rsp, err := c.DeletePluginByTeamAndPluginName(ctx, teamName, pluginKind, pluginName, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePluginByTeamAndPluginNameResponse(rsp) -} - -// GetPluginWithResponse request returning *GetPluginResponse -func (c *ClientWithResponses) GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) { - rsp, err := c.GetPlugin(ctx, teamName, pluginKind, pluginName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetPluginResponse(rsp) -} - -// UpdatePluginWithBodyWithResponse request with arbitrary body returning *UpdatePluginResponse -func (c *ClientWithResponses) UpdatePluginWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePluginResponse, error) { - rsp, err := c.UpdatePluginWithBody(ctx, teamName, pluginKind, pluginName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdatePluginResponse(rsp) -} - -func (c *ClientWithResponses) UpdatePluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, body UpdatePluginJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePluginResponse, error) { - rsp, err := c.UpdatePlugin(ctx, teamName, pluginKind, pluginName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdatePluginResponse(rsp) -} - -// ListPluginVersionsWithResponse request returning *ListPluginVersionsResponse -func (c *ClientWithResponses) ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) { - rsp, err := c.ListPluginVersions(ctx, teamName, pluginKind, pluginName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPluginVersionsResponse(rsp) -} - -// GetPluginVersionWithResponse request returning *GetPluginVersionResponse -func (c *ClientWithResponses) GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) { - rsp, err := c.GetPluginVersion(ctx, teamName, pluginKind, pluginName, versionName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetPluginVersionResponse(rsp) -} - -// UpdatePluginVersionWithBodyWithResponse request with arbitrary body returning *UpdatePluginVersionResponse -func (c *ClientWithResponses) UpdatePluginVersionWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePluginVersionResponse, error) { - rsp, err := c.UpdatePluginVersionWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdatePluginVersionResponse(rsp) -} - -func (c *ClientWithResponses) UpdatePluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UpdatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePluginVersionResponse, error) { - rsp, err := c.UpdatePluginVersion(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdatePluginVersionResponse(rsp) -} - -// CreatePluginVersionWithBodyWithResponse request with arbitrary body returning *CreatePluginVersionResponse -func (c *ClientWithResponses) CreatePluginVersionWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionResponse, error) { - rsp, err := c.CreatePluginVersionWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionResponse(rsp) -} - -func (c *ClientWithResponses) CreatePluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionResponse, error) { - rsp, err := c.CreatePluginVersion(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionResponse(rsp) -} - -// DownloadPluginAssetWithResponse request returning *DownloadPluginAssetResponse -func (c *ClientWithResponses) DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) { - rsp, err := c.DownloadPluginAsset(ctx, teamName, pluginKind, pluginName, versionName, targetName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseDownloadPluginAssetResponse(rsp) -} - -// UploadPluginAssetWithResponse request returning *UploadPluginAssetResponse -func (c *ClientWithResponses) UploadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, reqEditors ...RequestEditorFn) (*UploadPluginAssetResponse, error) { - rsp, err := c.UploadPluginAsset(ctx, teamName, pluginKind, pluginName, versionName, targetName, reqEditors...) - if err != nil { - return nil, err - } - return ParseUploadPluginAssetResponse(rsp) -} - -// DeletePluginVersionDocsWithBodyWithResponse request with arbitrary body returning *DeletePluginVersionDocsResponse -func (c *ClientWithResponses) DeletePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeletePluginVersionDocsResponse, error) { - rsp, err := c.DeletePluginVersionDocsWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePluginVersionDocsResponse(rsp) -} - -func (c *ClientWithResponses) DeletePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*DeletePluginVersionDocsResponse, error) { - rsp, err := c.DeletePluginVersionDocs(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePluginVersionDocsResponse(rsp) -} - -// ListPluginVersionDocsWithResponse request returning *ListPluginVersionDocsResponse -func (c *ClientWithResponses) ListPluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionDocsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionDocsResponse, error) { - rsp, err := c.ListPluginVersionDocs(ctx, teamName, pluginKind, pluginName, versionName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPluginVersionDocsResponse(rsp) -} - -// ReplacePluginVersionDocsWithBodyWithResponse request with arbitrary body returning *ReplacePluginVersionDocsResponse -func (c *ClientWithResponses) ReplacePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ReplacePluginVersionDocsResponse, error) { - rsp, err := c.ReplacePluginVersionDocsWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseReplacePluginVersionDocsResponse(rsp) -} - -func (c *ClientWithResponses) ReplacePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body ReplacePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*ReplacePluginVersionDocsResponse, error) { - rsp, err := c.ReplacePluginVersionDocs(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseReplacePluginVersionDocsResponse(rsp) -} - -// CreatePluginVersionDocsWithBodyWithResponse request with arbitrary body returning *CreatePluginVersionDocsResponse -func (c *ClientWithResponses) CreatePluginVersionDocsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionDocsResponse, error) { - rsp, err := c.CreatePluginVersionDocsWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionDocsResponse(rsp) -} - -func (c *ClientWithResponses) CreatePluginVersionDocsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionDocsJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionDocsResponse, error) { - rsp, err := c.CreatePluginVersionDocs(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionDocsResponse(rsp) -} - -// DeletePluginVersionTablesWithBodyWithResponse request with arbitrary body returning *DeletePluginVersionTablesResponse -func (c *ClientWithResponses) DeletePluginVersionTablesWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeletePluginVersionTablesResponse, error) { - rsp, err := c.DeletePluginVersionTablesWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePluginVersionTablesResponse(rsp) -} - -func (c *ClientWithResponses) DeletePluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body DeletePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*DeletePluginVersionTablesResponse, error) { - rsp, err := c.DeletePluginVersionTables(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePluginVersionTablesResponse(rsp) -} - -// ListPluginVersionTablesWithResponse request returning *ListPluginVersionTablesResponse -func (c *ClientWithResponses) ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) { - rsp, err := c.ListPluginVersionTables(ctx, teamName, pluginKind, pluginName, versionName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPluginVersionTablesResponse(rsp) -} - -// CreatePluginVersionTablesWithBodyWithResponse request with arbitrary body returning *CreatePluginVersionTablesResponse -func (c *ClientWithResponses) CreatePluginVersionTablesWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePluginVersionTablesResponse, error) { - rsp, err := c.CreatePluginVersionTablesWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionTablesResponse(rsp) -} - -func (c *ClientWithResponses) CreatePluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body CreatePluginVersionTablesJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePluginVersionTablesResponse, error) { - rsp, err := c.CreatePluginVersionTables(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreatePluginVersionTablesResponse(rsp) -} - -// GetPluginVersionTableWithResponse request returning *GetPluginVersionTableResponse -func (c *ClientWithResponses) GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) { - rsp, err := c.GetPluginVersionTable(ctx, teamName, pluginKind, pluginName, versionName, tableName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetPluginVersionTableResponse(rsp) -} - -// RemovePluginUIAssetsWithResponse request returning *RemovePluginUIAssetsResponse -func (c *ClientWithResponses) RemovePluginUIAssetsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*RemovePluginUIAssetsResponse, error) { - rsp, err := c.RemovePluginUIAssets(ctx, teamName, pluginKind, pluginName, versionName, reqEditors...) - if err != nil { - return nil, err - } - return ParseRemovePluginUIAssetsResponse(rsp) -} - -// UploadPluginUIAssetsWithBodyWithResponse request with arbitrary body returning *UploadPluginUIAssetsResponse -func (c *ClientWithResponses) UploadPluginUIAssetsWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadPluginUIAssetsResponse, error) { - rsp, err := c.UploadPluginUIAssetsWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUploadPluginUIAssetsResponse(rsp) -} - -func (c *ClientWithResponses) UploadPluginUIAssetsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body UploadPluginUIAssetsJSONRequestBody, reqEditors ...RequestEditorFn) (*UploadPluginUIAssetsResponse, error) { - rsp, err := c.UploadPluginUIAssets(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUploadPluginUIAssetsResponse(rsp) -} - -// FinalizePluginUIAssetUploadWithBodyWithResponse request with arbitrary body returning *FinalizePluginUIAssetUploadResponse -func (c *ClientWithResponses) FinalizePluginUIAssetUploadWithBodyWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*FinalizePluginUIAssetUploadResponse, error) { - rsp, err := c.FinalizePluginUIAssetUploadWithBody(ctx, teamName, pluginKind, pluginName, versionName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseFinalizePluginUIAssetUploadResponse(rsp) -} - -func (c *ClientWithResponses) FinalizePluginUIAssetUploadWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, body FinalizePluginUIAssetUploadJSONRequestBody, reqEditors ...RequestEditorFn) (*FinalizePluginUIAssetUploadResponse, error) { - rsp, err := c.FinalizePluginUIAssetUpload(ctx, teamName, pluginKind, pluginName, versionName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseFinalizePluginUIAssetUploadResponse(rsp) -} - -// AuthRegistryRequestWithResponse request returning *AuthRegistryRequestResponse -func (c *ClientWithResponses) AuthRegistryRequestWithResponse(ctx context.Context, params *AuthRegistryRequestParams, reqEditors ...RequestEditorFn) (*AuthRegistryRequestResponse, error) { - rsp, err := c.AuthRegistryRequest(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthRegistryRequestResponse(rsp) -} - -// ListTeamsWithResponse request returning *ListTeamsResponse -func (c *ClientWithResponses) ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) { - rsp, err := c.ListTeams(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListTeamsResponse(rsp) -} - -// CreateTeamWithBodyWithResponse request with arbitrary body returning *CreateTeamResponse -func (c *ClientWithResponses) CreateTeamWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamResponse, error) { - rsp, err := c.CreateTeamWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamResponse(rsp) -} - -func (c *ClientWithResponses) CreateTeamWithResponse(ctx context.Context, body CreateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamResponse, error) { - rsp, err := c.CreateTeam(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamResponse(rsp) -} - -// DeleteTeamWithResponse request returning *DeleteTeamResponse -func (c *ClientWithResponses) DeleteTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*DeleteTeamResponse, error) { - rsp, err := c.DeleteTeam(ctx, teamName, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteTeamResponse(rsp) -} - -// GetTeamByNameWithResponse request returning *GetTeamByNameResponse -func (c *ClientWithResponses) GetTeamByNameWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*GetTeamByNameResponse, error) { - rsp, err := c.GetTeamByName(ctx, teamName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetTeamByNameResponse(rsp) -} - -// UpdateTeamWithBodyWithResponse request with arbitrary body returning *UpdateTeamResponse -func (c *ClientWithResponses) UpdateTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateTeamResponse, error) { - rsp, err := c.UpdateTeamWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateTeamResponse(rsp) -} - -func (c *ClientWithResponses) UpdateTeamWithResponse(ctx context.Context, teamName TeamName, body UpdateTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateTeamResponse, error) { - rsp, err := c.UpdateTeam(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateTeamResponse(rsp) -} - -// ListAllAlertsWithResponse request returning *ListAllAlertsResponse -func (c *ClientWithResponses) ListAllAlertsWithResponse(ctx context.Context, teamName TeamName, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) { - rsp, err := c.ListAllAlerts(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListAllAlertsResponse(rsp) -} - -// TestUnsavedAlertWithBodyWithResponse request with arbitrary body returning *TestUnsavedAlertResponse -func (c *ClientWithResponses) TestUnsavedAlertWithBodyWithResponse(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) { - rsp, err := c.TestUnsavedAlertWithBody(ctx, teamName, params, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseTestUnsavedAlertResponse(rsp) -} - -func (c *ClientWithResponses) TestUnsavedAlertWithResponse(ctx context.Context, teamName TeamName, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) { - rsp, err := c.TestUnsavedAlert(ctx, teamName, params, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseTestUnsavedAlertResponse(rsp) -} - -// ListTeamAPIKeysWithResponse request returning *ListTeamAPIKeysResponse -func (c *ClientWithResponses) ListTeamAPIKeysWithResponse(ctx context.Context, teamName TeamName, params *ListTeamAPIKeysParams, reqEditors ...RequestEditorFn) (*ListTeamAPIKeysResponse, error) { - rsp, err := c.ListTeamAPIKeys(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListTeamAPIKeysResponse(rsp) -} - -// CreateTeamAPIKeyWithBodyWithResponse request with arbitrary body returning *CreateTeamAPIKeyResponse -func (c *ClientWithResponses) CreateTeamAPIKeyWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamAPIKeyResponse, error) { - rsp, err := c.CreateTeamAPIKeyWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamAPIKeyResponse(rsp) -} - -func (c *ClientWithResponses) CreateTeamAPIKeyWithResponse(ctx context.Context, teamName TeamName, body CreateTeamAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamAPIKeyResponse, error) { - rsp, err := c.CreateTeamAPIKey(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamAPIKeyResponse(rsp) -} - -// DeleteTeamAPIKeyWithResponse request returning *DeleteTeamAPIKeyResponse -func (c *ClientWithResponses) DeleteTeamAPIKeyWithResponse(ctx context.Context, teamName TeamName, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteTeamAPIKeyResponse, error) { - rsp, err := c.DeleteTeamAPIKey(ctx, teamName, apiKeyID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteTeamAPIKeyResponse(rsp) -} - -// ListConnectorsWithResponse request returning *ListConnectorsResponse -func (c *ClientWithResponses) ListConnectorsWithResponse(ctx context.Context, teamName TeamName, params *ListConnectorsParams, reqEditors ...RequestEditorFn) (*ListConnectorsResponse, error) { - rsp, err := c.ListConnectors(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListConnectorsResponse(rsp) -} - -// CreateConnectorWithBodyWithResponse request with arbitrary body returning *CreateConnectorResponse -func (c *ClientWithResponses) CreateConnectorWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConnectorResponse, error) { - rsp, err := c.CreateConnectorWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateConnectorResponse(rsp) -} - -func (c *ClientWithResponses) CreateConnectorWithResponse(ctx context.Context, teamName TeamName, body CreateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConnectorResponse, error) { - rsp, err := c.CreateConnector(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateConnectorResponse(rsp) -} - -// GetConnectorWithResponse request returning *GetConnectorResponse -func (c *ClientWithResponses) GetConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorResponse, error) { - rsp, err := c.GetConnector(ctx, teamName, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetConnectorResponse(rsp) -} - -// UpdateConnectorWithBodyWithResponse request with arbitrary body returning *UpdateConnectorResponse -func (c *ClientWithResponses) UpdateConnectorWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateConnectorResponse, error) { - rsp, err := c.UpdateConnectorWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateConnectorResponse(rsp) -} - -func (c *ClientWithResponses) UpdateConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body UpdateConnectorJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateConnectorResponse, error) { - rsp, err := c.UpdateConnector(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateConnectorResponse(rsp) -} - -// RevokeConnectorWithResponse request returning *RevokeConnectorResponse -func (c *ClientWithResponses) RevokeConnectorWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*RevokeConnectorResponse, error) { - rsp, err := c.RevokeConnector(ctx, teamName, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseRevokeConnectorResponse(rsp) -} - -// GetConnectorAuthStatusAWSWithResponse request returning *GetConnectorAuthStatusAWSResponse -func (c *ClientWithResponses) GetConnectorAuthStatusAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorAuthStatusAWSResponse, error) { - rsp, err := c.GetConnectorAuthStatusAWS(ctx, teamName, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetConnectorAuthStatusAWSResponse(rsp) -} - -// AuthenticateConnectorFinishAWSWithBodyWithResponse request with arbitrary body returning *AuthenticateConnectorFinishAWSResponse -func (c *ClientWithResponses) AuthenticateConnectorFinishAWSWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishAWSResponse, error) { - rsp, err := c.AuthenticateConnectorFinishAWSWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorFinishAWSResponse(rsp) -} - -func (c *ClientWithResponses) AuthenticateConnectorFinishAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishAWSResponse, error) { - rsp, err := c.AuthenticateConnectorFinishAWS(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorFinishAWSResponse(rsp) -} - -// AuthenticateConnectorAWSWithBodyWithResponse request with arbitrary body returning *AuthenticateConnectorAWSResponse -func (c *ClientWithResponses) AuthenticateConnectorAWSWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorAWSResponse, error) { - rsp, err := c.AuthenticateConnectorAWSWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorAWSResponse(rsp) -} - -func (c *ClientWithResponses) AuthenticateConnectorAWSWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorAWSJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorAWSResponse, error) { - rsp, err := c.AuthenticateConnectorAWS(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorAWSResponse(rsp) -} - -// GetConnectorAuthStatusGCPWithResponse request returning *GetConnectorAuthStatusGCPResponse -func (c *ClientWithResponses) GetConnectorAuthStatusGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetConnectorAuthStatusGCPResponse, error) { - rsp, err := c.GetConnectorAuthStatusGCP(ctx, teamName, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetConnectorAuthStatusGCPResponse(rsp) -} - -// AuthenticateConnectorGCPWithBodyWithResponse request with arbitrary body returning *AuthenticateConnectorGCPResponse -func (c *ClientWithResponses) AuthenticateConnectorGCPWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorGCPResponse, error) { - rsp, err := c.AuthenticateConnectorGCPWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorGCPResponse(rsp) -} - -func (c *ClientWithResponses) AuthenticateConnectorGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorGCPJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorGCPResponse, error) { - rsp, err := c.AuthenticateConnectorGCP(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorGCPResponse(rsp) -} - -// AuthenticateConnectorFinishGCPWithResponse request returning *AuthenticateConnectorFinishGCPResponse -func (c *ClientWithResponses) AuthenticateConnectorFinishGCPWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishGCPResponse, error) { - rsp, err := c.AuthenticateConnectorFinishGCP(ctx, teamName, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorFinishGCPResponse(rsp) -} - -// AuthenticateConnectorFinishOAuthWithBodyWithResponse request with arbitrary body returning *AuthenticateConnectorFinishOAuthResponse -func (c *ClientWithResponses) AuthenticateConnectorFinishOAuthWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishOAuthResponse, error) { - rsp, err := c.AuthenticateConnectorFinishOAuthWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorFinishOAuthResponse(rsp) -} - -func (c *ClientWithResponses) AuthenticateConnectorFinishOAuthWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorFinishOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorFinishOAuthResponse, error) { - rsp, err := c.AuthenticateConnectorFinishOAuth(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorFinishOAuthResponse(rsp) -} - -// AuthenticateConnectorOAuthWithBodyWithResponse request with arbitrary body returning *AuthenticateConnectorOAuthResponse -func (c *ClientWithResponses) AuthenticateConnectorOAuthWithBodyWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateConnectorOAuthResponse, error) { - rsp, err := c.AuthenticateConnectorOAuthWithBody(ctx, teamName, connectorID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorOAuthResponse(rsp) -} - -func (c *ClientWithResponses) AuthenticateConnectorOAuthWithResponse(ctx context.Context, teamName TeamName, connectorID ConnectorID, body AuthenticateConnectorOAuthJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateConnectorOAuthResponse, error) { - rsp, err := c.AuthenticateConnectorOAuth(ctx, teamName, connectorID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateConnectorOAuthResponse(rsp) -} - -// CreateConversationWithBodyWithResponse request with arbitrary body returning *CreateConversationResponse -func (c *ClientWithResponses) CreateConversationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) { - rsp, err := c.CreateConversationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateConversationResponse(rsp) -} - -func (c *ClientWithResponses) CreateConversationWithResponse(ctx context.Context, teamName TeamName, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) { - rsp, err := c.CreateConversation(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateConversationResponse(rsp) -} - -// GetConversationWithResponse request returning *GetConversationResponse -func (c *ClientWithResponses) GetConversationWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) { - rsp, err := c.GetConversation(ctx, teamName, conversationID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetConversationResponse(rsp) -} - -// SendMessageWithBodyWithResponse request with arbitrary body returning *SendMessageResponse -func (c *ClientWithResponses) SendMessageWithBodyWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) { - rsp, err := c.SendMessageWithBody(ctx, teamName, conversationID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSendMessageResponse(rsp) -} - -func (c *ClientWithResponses) SendMessageWithResponse(ctx context.Context, teamName TeamName, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) { - rsp, err := c.SendMessage(ctx, teamName, conversationID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSendMessageResponse(rsp) -} - -// ListAllCustomColumnsWithResponse request returning *ListAllCustomColumnsResponse -func (c *ClientWithResponses) ListAllCustomColumnsWithResponse(ctx context.Context, teamName TeamName, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) { - rsp, err := c.ListAllCustomColumns(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListAllCustomColumnsResponse(rsp) -} - -// SaveCustomColumnWithBodyWithResponse request with arbitrary body returning *SaveCustomColumnResponse -func (c *ClientWithResponses) SaveCustomColumnWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) { - rsp, err := c.SaveCustomColumnWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSaveCustomColumnResponse(rsp) -} - -func (c *ClientWithResponses) SaveCustomColumnWithResponse(ctx context.Context, teamName TeamName, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) { - rsp, err := c.SaveCustomColumn(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSaveCustomColumnResponse(rsp) -} - -// DeleteCustomColumnWithResponse request returning *DeleteCustomColumnResponse -func (c *ClientWithResponses) DeleteCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) { - rsp, err := c.DeleteCustomColumn(ctx, teamName, customColumnID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteCustomColumnResponse(rsp) -} - -// GetCustomColumnWithResponse request returning *GetCustomColumnResponse -func (c *ClientWithResponses) GetCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) { - rsp, err := c.GetCustomColumn(ctx, teamName, customColumnID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetCustomColumnResponse(rsp) -} - -// UpdateCustomColumnWithBodyWithResponse request with arbitrary body returning *UpdateCustomColumnResponse -func (c *ClientWithResponses) UpdateCustomColumnWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) { - rsp, err := c.UpdateCustomColumnWithBody(ctx, teamName, customColumnID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateCustomColumnResponse(rsp) -} - -func (c *ClientWithResponses) UpdateCustomColumnWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) { - rsp, err := c.UpdateCustomColumn(ctx, teamName, customColumnID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateCustomColumnResponse(rsp) -} - -// PutCustomColumnDataWithBodyWithResponse request with arbitrary body returning *PutCustomColumnDataResponse -func (c *ClientWithResponses) PutCustomColumnDataWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutCustomColumnDataResponse, error) { - rsp, err := c.PutCustomColumnDataWithBody(ctx, teamName, customColumnID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePutCustomColumnDataResponse(rsp) -} - -func (c *ClientWithResponses) PutCustomColumnDataWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnDataJSONRequestBody, reqEditors ...RequestEditorFn) (*PutCustomColumnDataResponse, error) { - rsp, err := c.PutCustomColumnData(ctx, teamName, customColumnID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePutCustomColumnDataResponse(rsp) -} - -// PutCustomColumnValuesWithBodyWithResponse request with arbitrary body returning *PutCustomColumnValuesResponse -func (c *ClientWithResponses) PutCustomColumnValuesWithBodyWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutCustomColumnValuesResponse, error) { - rsp, err := c.PutCustomColumnValuesWithBody(ctx, teamName, customColumnID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePutCustomColumnValuesResponse(rsp) -} - -func (c *ClientWithResponses) PutCustomColumnValuesWithResponse(ctx context.Context, teamName TeamName, customColumnID CustomColumnID, body PutCustomColumnValuesJSONRequestBody, reqEditors ...RequestEditorFn) (*PutCustomColumnValuesResponse, error) { - rsp, err := c.PutCustomColumnValues(ctx, teamName, customColumnID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePutCustomColumnValuesResponse(rsp) -} - -// ListFiltersTeamWithResponse request returning *ListFiltersTeamResponse -func (c *ClientWithResponses) ListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, params *ListFiltersTeamParams, reqEditors ...RequestEditorFn) (*ListFiltersTeamResponse, error) { - rsp, err := c.ListFiltersTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListFiltersTeamResponse(rsp) -} - -// ListFilterTagsTeamWithResponse request returning *ListFilterTagsTeamResponse -func (c *ClientWithResponses) ListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, params *ListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*ListFilterTagsTeamResponse, error) { - rsp, err := c.ListFilterTagsTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListFilterTagsTeamResponse(rsp) -} - -// DeleteFilterTeamWithResponse request returning *DeleteFilterTeamResponse -func (c *ClientWithResponses) DeleteFilterTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterTeamResponse, error) { - rsp, err := c.DeleteFilterTeam(ctx, teamName, filterID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteFilterTeamResponse(rsp) -} - -// GetFilterByIDTeamWithResponse request returning *GetFilterByIDTeamResponse -func (c *ClientWithResponses) GetFilterByIDTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDTeamResponse, error) { - rsp, err := c.GetFilterByIDTeam(ctx, teamName, filterID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetFilterByIDTeamResponse(rsp) -} - -// UpdateFilterTeamWithBodyWithResponse request with arbitrary body returning *UpdateFilterTeamResponse -func (c *ClientWithResponses) UpdateFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterTeamResponse, error) { - rsp, err := c.UpdateFilterTeamWithBody(ctx, teamName, filterID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateFilterTeamResponse(rsp) -} - -func (c *ClientWithResponses) UpdateFilterTeamWithResponse(ctx context.Context, teamName TeamName, filterID FilterID, body UpdateFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterTeamResponse, error) { - rsp, err := c.UpdateFilterTeam(ctx, teamName, filterID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateFilterTeamResponse(rsp) -} - -// CreateTeamImagesWithBodyWithResponse request with arbitrary body returning *CreateTeamImagesResponse -func (c *ClientWithResponses) CreateTeamImagesWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateTeamImagesResponse, error) { - rsp, err := c.CreateTeamImagesWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamImagesResponse(rsp) -} - -func (c *ClientWithResponses) CreateTeamImagesWithResponse(ctx context.Context, teamName TeamName, body CreateTeamImagesJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateTeamImagesResponse, error) { - rsp, err := c.CreateTeamImages(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateTeamImagesResponse(rsp) -} - -// DeleteTeamInvitationWithBodyWithResponse request with arbitrary body returning *DeleteTeamInvitationResponse -func (c *ClientWithResponses) DeleteTeamInvitationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTeamInvitationResponse, error) { - rsp, err := c.DeleteTeamInvitationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteTeamInvitationResponse(rsp) -} - -func (c *ClientWithResponses) DeleteTeamInvitationWithResponse(ctx context.Context, teamName TeamName, body DeleteTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTeamInvitationResponse, error) { - rsp, err := c.DeleteTeamInvitation(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteTeamInvitationResponse(rsp) -} - -// ListTeamInvitationsWithResponse request returning *ListTeamInvitationsResponse -func (c *ClientWithResponses) ListTeamInvitationsWithResponse(ctx context.Context, teamName TeamName, params *ListTeamInvitationsParams, reqEditors ...RequestEditorFn) (*ListTeamInvitationsResponse, error) { - rsp, err := c.ListTeamInvitations(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListTeamInvitationsResponse(rsp) -} - -// AcceptTeamInvitationWithBodyWithResponse request with arbitrary body returning *AcceptTeamInvitationResponse -func (c *ClientWithResponses) AcceptTeamInvitationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AcceptTeamInvitationResponse, error) { - rsp, err := c.AcceptTeamInvitationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAcceptTeamInvitationResponse(rsp) -} - -func (c *ClientWithResponses) AcceptTeamInvitationWithResponse(ctx context.Context, teamName TeamName, body AcceptTeamInvitationJSONRequestBody, reqEditors ...RequestEditorFn) (*AcceptTeamInvitationResponse, error) { - rsp, err := c.AcceptTeamInvitation(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAcceptTeamInvitationResponse(rsp) -} - -// RemoveTeamMembershipWithBodyWithResponse request with arbitrary body returning *RemoveTeamMembershipResponse -func (c *ClientWithResponses) RemoveTeamMembershipWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*RemoveTeamMembershipResponse, error) { - rsp, err := c.RemoveTeamMembershipWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseRemoveTeamMembershipResponse(rsp) -} - -func (c *ClientWithResponses) RemoveTeamMembershipWithResponse(ctx context.Context, teamName TeamName, body RemoveTeamMembershipJSONRequestBody, reqEditors ...RequestEditorFn) (*RemoveTeamMembershipResponse, error) { - rsp, err := c.RemoveTeamMembership(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseRemoveTeamMembershipResponse(rsp) -} - -// GetTeamMembershipsWithResponse request returning *GetTeamMembershipsResponse -func (c *ClientWithResponses) GetTeamMembershipsWithResponse(ctx context.Context, teamName TeamName, params *GetTeamMembershipsParams, reqEditors ...RequestEditorFn) (*GetTeamMembershipsResponse, error) { - rsp, err := c.GetTeamMemberships(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetTeamMembershipsResponse(rsp) -} - -// DeleteTeamMembershipWithResponse request returning *DeleteTeamMembershipResponse -func (c *ClientWithResponses) DeleteTeamMembershipWithResponse(ctx context.Context, teamName TeamName, email EmailBasic, reqEditors ...RequestEditorFn) (*DeleteTeamMembershipResponse, error) { - rsp, err := c.DeleteTeamMembership(ctx, teamName, email, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeletePolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteTeamMembershipResponse(rsp) + return 0 } -// DeleteNotificationDestinationWithResponse request returning *DeleteNotificationDestinationResponse -func (c *ClientWithResponses) DeleteNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) { - rsp, err := c.DeleteNotificationDestination(ctx, teamName, notificationDestinationID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteNotificationDestinationResponse(rsp) +type GetPolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Policy + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -// GetNotificationDestinationWithResponse request returning *GetNotificationDestinationResponse -func (c *ClientWithResponses) GetNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) { - rsp, err := c.GetNotificationDestination(ctx, teamName, notificationDestinationID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetPolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetNotificationDestinationResponse(rsp) + return http.StatusText(0) } -// UpdateNotificationDestinationWithBodyWithResponse request with arbitrary body returning *UpdateNotificationDestinationResponse -func (c *ClientWithResponses) UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) { - rsp, err := c.UpdateNotificationDestinationWithBody(ctx, teamName, notificationDestinationID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateNotificationDestinationResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdateNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) { - rsp, err := c.UpdateNotificationDestination(ctx, teamName, notificationDestinationID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateNotificationDestinationResponse(rsp) +type UpdatePolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Policy + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetNotificationDestinationAlertsWithResponse request returning *GetNotificationDestinationAlertsResponse -func (c *ClientWithResponses) GetNotificationDestinationAlertsWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) { - rsp, err := c.GetNotificationDestinationAlerts(ctx, teamName, notificationDestinationID, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdatePolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetNotificationDestinationAlertsResponse(rsp) + return http.StatusText(0) } -// TestNotificationDestinationWithResponse request returning *TestNotificationDestinationResponse -func (c *ClientWithResponses) TestNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, notificationDestinationID NotificationDestinationID, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) { - rsp, err := c.TestNotificationDestination(ctx, teamName, notificationDestinationID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdatePolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseTestNotificationDestinationResponse(rsp) + return 0 } -// ListAllNotificationDestinationsWithResponse request returning *ListAllNotificationDestinationsResponse -func (c *ClientWithResponses) ListAllNotificationDestinationsWithResponse(ctx context.Context, teamName TeamName, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) { - rsp, err := c.ListAllNotificationDestinations(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListAllNotificationDestinationsResponse(rsp) +type TogglePolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Policy + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// CreateNotificationDestinationWithBodyWithResponse request with arbitrary body returning *CreateNotificationDestinationResponse -func (c *ClientWithResponses) CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) { - rsp, err := c.CreateNotificationDestinationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r TogglePolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateNotificationDestinationResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) CreateNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) { - rsp, err := c.CreateNotificationDestination(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r TogglePolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateNotificationDestinationResponse(rsp) + return 0 } -// TestUnsavedNotificationDestinationWithBodyWithResponse request with arbitrary body returning *TestUnsavedNotificationDestinationResponse -func (c *ClientWithResponses) TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) { - rsp, err := c.TestUnsavedNotificationDestinationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type GetPolicyViolationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PolicyViolation `json:"items"` + Metadata *ListMetadata `json:"metadata,omitempty"` } - return ParseTestUnsavedNotificationDestinationResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -func (c *ClientWithResponses) TestUnsavedNotificationDestinationWithResponse(ctx context.Context, teamName TeamName, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) { - rsp, err := c.TestUnsavedNotificationDestination(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetPolicyViolationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseTestUnsavedNotificationDestinationResponse(rsp) + return http.StatusText(0) } -// CreateAWSOnboardingWithBodyWithResponse request with arbitrary body returning *CreateAWSOnboardingResponse -func (c *ClientWithResponses) CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) { - rsp, err := c.CreateAWSOnboardingWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPolicyViolationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateAWSOnboardingResponse(rsp) + return 0 } -func (c *ClientWithResponses) CreateAWSOnboardingWithResponse(ctx context.Context, teamName TeamName, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) { - rsp, err := c.CreateAWSOnboarding(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +type GetPolicyViolationsHistoryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PolicyEvaluationLog `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseCreateAWSOnboardingResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -// GetAWSOnboardingWithResponse request returning *GetAWSOnboardingResponse -func (c *ClientWithResponses) GetAWSOnboardingWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) { - rsp, err := c.GetAWSOnboarding(ctx, teamName, onboardingID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetPolicyViolationsHistoryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetAWSOnboardingResponse(rsp) + return http.StatusText(0) } -// GetAWSAccountsInRootWithResponse request returning *GetAWSAccountsInRootResponse -func (c *ClientWithResponses) GetAWSAccountsInRootWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) { - rsp, err := c.GetAWSAccountsInRoot(ctx, teamName, onboardingID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetPolicyViolationsHistoryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetAWSAccountsInRootResponse(rsp) + return 0 } -// ProvisionOnboardingConfigurationWithBodyWithResponse request with arbitrary body returning *ProvisionOnboardingConfigurationResponse -func (c *ClientWithResponses) ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) { - rsp, err := c.ProvisionOnboardingConfigurationWithBody(ctx, teamName, onboardingID, contentType, body, reqEditors...) - if err != nil { - return nil, err +type ListPolicyGroupsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PolicyGroupWithCounts `json:"items"` } - return ParseProvisionOnboardingConfigurationResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError } -func (c *ClientWithResponses) ProvisionOnboardingConfigurationWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) { - rsp, err := c.ProvisionOnboardingConfiguration(ctx, teamName, onboardingID, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListPolicyGroupsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseProvisionOnboardingConfigurationResponse(rsp) + return http.StatusText(0) } -// GetAWSAccountsInParentWithResponse request returning *GetAWSAccountsInParentResponse -func (c *ClientWithResponses) GetAWSAccountsInParentWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) { - rsp, err := c.GetAWSAccountsInParent(ctx, teamName, onboardingID, organizationalUnitID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListPolicyGroupsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetAWSAccountsInParentResponse(rsp) + return 0 } -// NotifyOnboardingWithBodyWithResponse request with arbitrary body returning *NotifyOnboardingResponse -func (c *ClientWithResponses) NotifyOnboardingWithBodyWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) { - rsp, err := c.NotifyOnboardingWithBody(ctx, teamName, onboardingID, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseNotifyOnboardingResponse(rsp) +type CreatePolicyGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *PolicyGroup + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) NotifyOnboardingWithResponse(ctx context.Context, teamName TeamName, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) { - rsp, err := c.NotifyOnboarding(ctx, teamName, onboardingID, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreatePolicyGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseNotifyOnboardingResponse(rsp) + return http.StatusText(0) } -// DeletePluginsByTeamWithResponse request returning *DeletePluginsByTeamResponse -func (c *ClientWithResponses) DeletePluginsByTeamWithResponse(ctx context.Context, teamName TeamName, reqEditors ...RequestEditorFn) (*DeletePluginsByTeamResponse, error) { - rsp, err := c.DeletePluginsByTeam(ctx, teamName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreatePolicyGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeletePluginsByTeamResponse(rsp) + return 0 } -// ListPluginsByTeamWithResponse request returning *ListPluginsByTeamResponse -func (c *ClientWithResponses) ListPluginsByTeamWithResponse(ctx context.Context, teamName TeamName, params *ListPluginsByTeamParams, reqEditors ...RequestEditorFn) (*ListPluginsByTeamResponse, error) { - rsp, err := c.ListPluginsByTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListPluginsByTeamResponse(rsp) +type DeletePolicyGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -// DownloadPluginAssetByTeamWithResponse request returning *DownloadPluginAssetByTeamResponse -func (c *ClientWithResponses) DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) { - rsp, err := c.DownloadPluginAssetByTeam(ctx, teamName, pluginTeam, pluginKind, pluginName, versionName, targetName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeletePolicyGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDownloadPluginAssetByTeamResponse(rsp) + return http.StatusText(0) } -// ListPoliciesWithResponse request returning *ListPoliciesResponse -func (c *ClientWithResponses) ListPoliciesWithResponse(ctx context.Context, teamName TeamName, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) { - rsp, err := c.ListPolicies(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeletePolicyGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListPoliciesResponse(rsp) + return 0 } -// CreatePolicyWithBodyWithResponse request with arbitrary body returning *CreatePolicyResponse -func (c *ClientWithResponses) CreatePolicyWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) { - rsp, err := c.CreatePolicyWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type ListPoliciesInGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Policy `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseCreatePolicyResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -func (c *ClientWithResponses) CreatePolicyWithResponse(ctx context.Context, teamName TeamName, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) { - rsp, err := c.CreatePolicy(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListPoliciesInGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreatePolicyResponse(rsp) + return http.StatusText(0) } -// ListAllFrameworksWithResponse request returning *ListAllFrameworksResponse -func (c *ClientWithResponses) ListAllFrameworksWithResponse(ctx context.Context, teamName TeamName, params *ListAllFrameworksParams, reqEditors ...RequestEditorFn) (*ListAllFrameworksResponse, error) { - rsp, err := c.ListAllFrameworks(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListPoliciesInGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListAllFrameworksResponse(rsp) + return 0 } -// DeletePolicyWithResponse request returning *DeletePolicyResponse -func (c *ClientWithResponses) DeletePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) { - rsp, err := c.DeletePolicy(ctx, teamName, policyId, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeletePolicyResponse(rsp) +type UpdatePolicyGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PolicyGroup + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetPolicyWithResponse request returning *GetPolicyResponse -func (c *ClientWithResponses) GetPolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) { - rsp, err := c.GetPolicy(ctx, teamName, policyId, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdatePolicyGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetPolicyResponse(rsp) + return http.StatusText(0) } -// UpdatePolicyWithBodyWithResponse request with arbitrary body returning *UpdatePolicyResponse -func (c *ClientWithResponses) UpdatePolicyWithBodyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) { - rsp, err := c.UpdatePolicyWithBody(ctx, teamName, policyId, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdatePolicyGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdatePolicyResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdatePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) { - rsp, err := c.UpdatePolicy(ctx, teamName, policyId, body, reqEditors...) - if err != nil { - return nil, err +type ListAllQueriesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Query `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseUpdatePolicyResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ListPolicyFrameworksWithResponse request returning *ListPolicyFrameworksResponse -func (c *ClientWithResponses) ListPolicyFrameworksWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyFrameworksParams, reqEditors ...RequestEditorFn) (*ListPolicyFrameworksResponse, error) { - rsp, err := c.ListPolicyFrameworks(ctx, teamName, policyId, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListAllQueriesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListPolicyFrameworksResponse(rsp) + return http.StatusText(0) } -// ListPolicyRulesWithResponse request returning *ListPolicyRulesResponse -func (c *ClientWithResponses) ListPolicyRulesWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *ListPolicyRulesParams, reqEditors ...RequestEditorFn) (*ListPolicyRulesResponse, error) { - rsp, err := c.ListPolicyRules(ctx, teamName, policyId, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllQueriesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListPolicyRulesResponse(rsp) + return 0 } -// ListPolicyRuleDetailsWithResponse request returning *ListPolicyRuleDetailsResponse -func (c *ClientWithResponses) ListPolicyRuleDetailsWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, ruleId openapi_types.UUID, params *ListPolicyRuleDetailsParams, reqEditors ...RequestEditorFn) (*ListPolicyRuleDetailsResponse, error) { - rsp, err := c.ListPolicyRuleDetails(ctx, teamName, policyId, ruleId, params, reqEditors...) - if err != nil { - return nil, err +type ExecuteAdHocQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } - return ParseListPolicyRuleDetailsResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// TogglePolicyWithResponse request returning *TogglePolicyResponse -func (c *ClientWithResponses) TogglePolicyWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *TogglePolicyParams, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) { - rsp, err := c.TogglePolicy(ctx, teamName, policyId, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ExecuteAdHocQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseTogglePolicyResponse(rsp) + return http.StatusText(0) } -// GetPolicyViolationsHistoryWithResponse request returning *GetPolicyViolationsHistoryResponse -func (c *ClientWithResponses) GetPolicyViolationsHistoryWithResponse(ctx context.Context, teamName TeamName, policyId openapi_types.UUID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) { - rsp, err := c.GetPolicyViolationsHistory(ctx, teamName, policyId, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ExecuteAdHocQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetPolicyViolationsHistoryResponse(rsp) + return 0 } -// ListAllQueriesTeamWithResponse request returning *ListAllQueriesTeamResponse -func (c *ClientWithResponses) ListAllQueriesTeamWithResponse(ctx context.Context, teamName TeamName, params *ListAllQueriesTeamParams, reqEditors ...RequestEditorFn) (*ListAllQueriesTeamResponse, error) { - rsp, err := c.ListAllQueriesTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListAllQueriesTeamResponse(rsp) +type SaveQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *QueryDetail + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ExecuteAdHocQueryTeamWithBodyWithResponse request with arbitrary body returning *ExecuteAdHocQueryTeamResponse -func (c *ClientWithResponses) ExecuteAdHocQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryTeamResponse, error) { - rsp, err := c.ExecuteAdHocQueryTeamWithBody(ctx, teamName, params, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r SaveQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseExecuteAdHocQueryTeamResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) ExecuteAdHocQueryTeamWithResponse(ctx context.Context, teamName TeamName, params *ExecuteAdHocQueryTeamParams, body ExecuteAdHocQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryTeamResponse, error) { - rsp, err := c.ExecuteAdHocQueryTeam(ctx, teamName, params, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r SaveQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseExecuteAdHocQueryTeamResponse(rsp) + return 0 } -// SaveQueryTeamWithBodyWithResponse request with arbitrary body returning *SaveQueryTeamResponse -func (c *ClientWithResponses) SaveQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryTeamResponse, error) { - rsp, err := c.SaveQueryTeamWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type ListQueryTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []QueryTag `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseSaveQueryTeamResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) SaveQueryTeamWithResponse(ctx context.Context, teamName TeamName, body SaveQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryTeamResponse, error) { - rsp, err := c.SaveQueryTeam(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListQueryTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseSaveQueryTeamResponse(rsp) + return http.StatusText(0) } -// ListQueryTagsTeamWithResponse request returning *ListQueryTagsTeamResponse -func (c *ClientWithResponses) ListQueryTagsTeamWithResponse(ctx context.Context, teamName TeamName, params *ListQueryTagsTeamParams, reqEditors ...RequestEditorFn) (*ListQueryTagsTeamResponse, error) { - rsp, err := c.ListQueryTagsTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListQueryTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListQueryTagsTeamResponse(rsp) + return 0 } -// DeleteSavedQueryTeamWithResponse request returning *DeleteSavedQueryTeamResponse -func (c *ClientWithResponses) DeleteSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryTeamResponse, error) { - rsp, err := c.DeleteSavedQueryTeam(ctx, teamName, queryID, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteSavedQueryTeamResponse(rsp) +type DeleteSavedQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSavedQueryTeamWithResponse request returning *GetSavedQueryTeamResponse -func (c *ClientWithResponses) GetSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryTeamResponse, error) { - rsp, err := c.GetSavedQueryTeam(ctx, teamName, queryID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteSavedQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSavedQueryTeamResponse(rsp) + return http.StatusText(0) } -// UpdateQueryTeamWithBodyWithResponse request with arbitrary body returning *UpdateQueryTeamResponse -func (c *ClientWithResponses) UpdateQueryTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryTeamResponse, error) { - rsp, err := c.UpdateQueryTeamWithBody(ctx, teamName, queryID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSavedQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateQueryTeamResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdateQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, body UpdateQueryTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryTeamResponse, error) { - rsp, err := c.UpdateQueryTeam(ctx, teamName, queryID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateQueryTeamResponse(rsp) +type GetSavedQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *QueryDetail + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// DeleteAlertWithResponse request returning *DeleteAlertResponse -func (c *ClientWithResponses) DeleteAlertWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) { - rsp, err := c.DeleteAlert(ctx, teamName, queryID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSavedQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDeleteAlertResponse(rsp) + return http.StatusText(0) } -// ExecuteSavedQueryTeamWithResponse request returning *ExecuteSavedQueryTeamResponse -func (c *ClientWithResponses) ExecuteSavedQueryTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *ExecuteSavedQueryTeamParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryTeamResponse, error) { - rsp, err := c.ExecuteSavedQueryTeam(ctx, teamName, queryID, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSavedQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseExecuteSavedQueryTeamResponse(rsp) + return 0 } -// QueryListFiltersTeamWithResponse request returning *QueryListFiltersTeamResponse -func (c *ClientWithResponses) QueryListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFiltersTeamParams, reqEditors ...RequestEditorFn) (*QueryListFiltersTeamResponse, error) { - rsp, err := c.QueryListFiltersTeam(ctx, teamName, queryID, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseQueryListFiltersTeamResponse(rsp) +type UpdateQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *QueryDetail + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// QuerySaveFilterTeamWithBodyWithResponse request with arbitrary body returning *QuerySaveFilterTeamResponse -func (c *ClientWithResponses) QuerySaveFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterTeamResponse, error) { - rsp, err := c.QuerySaveFilterTeamWithBody(ctx, teamName, queryID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseQuerySaveFilterTeamResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) QuerySaveFilterTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, body QuerySaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterTeamResponse, error) { - rsp, err := c.QuerySaveFilterTeam(ctx, teamName, queryID, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseQuerySaveFilterTeamResponse(rsp) + return 0 } -// QueryListFilterTagsTeamWithResponse request returning *QueryListFilterTagsTeamResponse -func (c *ClientWithResponses) QueryListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, queryID QueryID, params *QueryListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsTeamResponse, error) { - rsp, err := c.QueryListFilterTagsTeam(ctx, teamName, queryID, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseQueryListFilterTagsTeamResponse(rsp) +type DeleteAlertResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ListAllRBACPermissionsWithResponse request returning *ListAllRBACPermissionsResponse -func (c *ClientWithResponses) ListAllRBACPermissionsWithResponse(ctx context.Context, teamName TeamName, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) { - rsp, err := c.ListAllRBACPermissions(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteAlertResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListAllRBACPermissionsResponse(rsp) + return http.StatusText(0) } -// CreateRBACPermissionWithBodyWithResponse request with arbitrary body returning *CreateRBACPermissionResponse -func (c *ClientWithResponses) CreateRBACPermissionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) { - rsp, err := c.CreateRBACPermissionWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteAlertResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateRBACPermissionResponse(rsp) + return 0 } -func (c *ClientWithResponses) CreateRBACPermissionWithResponse(ctx context.Context, teamName TeamName, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) { - rsp, err := c.CreateRBACPermission(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +type ExecuteSavedQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } - return ParseCreateRBACPermissionResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// DeleteRBACPermissionWithResponse request returning *DeleteRBACPermissionResponse -func (c *ClientWithResponses) DeleteRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) { - rsp, err := c.DeleteRBACPermission(ctx, teamName, rbacPermissionID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ExecuteSavedQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDeleteRBACPermissionResponse(rsp) + return http.StatusText(0) } -// GetRBACPermissionWithResponse request returning *GetRBACPermissionResponse -func (c *ClientWithResponses) GetRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) { - rsp, err := c.GetRBACPermission(ctx, teamName, rbacPermissionID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ExecuteSavedQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetRBACPermissionResponse(rsp) + return 0 } -// UpdateRBACPermissionWithBodyWithResponse request with arbitrary body returning *UpdateRBACPermissionResponse -func (c *ClientWithResponses) UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) { - rsp, err := c.UpdateRBACPermissionWithBody(ctx, teamName, rbacPermissionID, contentType, body, reqEditors...) - if err != nil { - return nil, err +type QueryListFiltersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseUpdateRBACPermissionResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) UpdateRBACPermissionWithResponse(ctx context.Context, teamName TeamName, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) { - rsp, err := c.UpdateRBACPermission(ctx, teamName, rbacPermissionID, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r QueryListFiltersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateRBACPermissionResponse(rsp) + return http.StatusText(0) } -// ListAllRBACRolesWithResponse request returning *ListAllRBACRolesResponse -func (c *ClientWithResponses) ListAllRBACRolesWithResponse(ctx context.Context, teamName TeamName, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) { - rsp, err := c.ListAllRBACRoles(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r QueryListFiltersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListAllRBACRolesResponse(rsp) + return 0 } -// CreateRBACRoleWithBodyWithResponse request with arbitrary body returning *CreateRBACRoleResponse -func (c *ClientWithResponses) CreateRBACRoleWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) { - rsp, err := c.CreateRBACRoleWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateRBACRoleResponse(rsp) +type QuerySaveFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Filter + JSON201 *Filter + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) CreateRBACRoleWithResponse(ctx context.Context, teamName TeamName, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) { - rsp, err := c.CreateRBACRole(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r QuerySaveFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateRBACRoleResponse(rsp) + return http.StatusText(0) } -// DeleteRBACRoleWithResponse request returning *DeleteRBACRoleResponse -func (c *ClientWithResponses) DeleteRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) { - rsp, err := c.DeleteRBACRole(ctx, teamName, rbacCustomRoleID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r QuerySaveFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteRBACRoleResponse(rsp) + return 0 } -// GetRBACRoleWithResponse request returning *GetRBACRoleResponse -func (c *ClientWithResponses) GetRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) { - rsp, err := c.GetRBACRole(ctx, teamName, rbacCustomRoleID, reqEditors...) - if err != nil { - return nil, err +type QueryListFilterTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseGetRBACRoleResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// UpdateRBACRoleWithBodyWithResponse request with arbitrary body returning *UpdateRBACRoleResponse -func (c *ClientWithResponses) UpdateRBACRoleWithBodyWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) { - rsp, err := c.UpdateRBACRoleWithBody(ctx, teamName, rbacCustomRoleID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r QueryListFilterTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateRBACRoleResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UpdateRBACRoleWithResponse(ctx context.Context, teamName TeamName, rbacCustomRoleID RBACCustomRoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) { - rsp, err := c.UpdateRBACRole(ctx, teamName, rbacCustomRoleID, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r QueryListFilterTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateRBACRoleResponse(rsp) + return 0 } -// ListReportsWithResponse request returning *ListReportsResponse -func (c *ClientWithResponses) ListReportsWithResponse(ctx context.Context, teamName TeamName, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) { - rsp, err := c.ListReports(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +type ListAllRBACPermissionsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []RBACPermission `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseListReportsResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// CreateReportWithBodyWithResponse request with arbitrary body returning *CreateReportResponse -func (c *ClientWithResponses) CreateReportWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) { - rsp, err := c.CreateReportWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListAllRBACPermissionsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateReportResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) CreateReportWithResponse(ctx context.Context, teamName TeamName, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) { - rsp, err := c.CreateReport(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllRBACPermissionsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateReportResponse(rsp) + return 0 } -// ListReportTemplatesWithResponse request returning *ListReportTemplatesResponse -func (c *ClientWithResponses) ListReportTemplatesWithResponse(ctx context.Context, teamName TeamName, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) { - rsp, err := c.ListReportTemplates(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListReportTemplatesResponse(rsp) +type CreateRBACPermissionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *RBACPermission + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// CreateReportTemplateWithBodyWithResponse request with arbitrary body returning *CreateReportTemplateResponse -func (c *ClientWithResponses) CreateReportTemplateWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) { - rsp, err := c.CreateReportTemplateWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateRBACPermissionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateReportTemplateResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) CreateReportTemplateWithResponse(ctx context.Context, teamName TeamName, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) { - rsp, err := c.CreateReportTemplate(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateRBACPermissionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateReportTemplateResponse(rsp) + return 0 } -// DeleteReportTemplateWithResponse request returning *DeleteReportTemplateResponse -func (c *ClientWithResponses) DeleteReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) { - rsp, err := c.DeleteReportTemplate(ctx, teamName, templateId, reqEditors...) - if err != nil { - return nil, err - } - return ParseDeleteReportTemplateResponse(rsp) +type DeleteRBACPermissionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetReportTemplateWithResponse request returning *GetReportTemplateResponse -func (c *ClientWithResponses) GetReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) { - rsp, err := c.GetReportTemplate(ctx, teamName, templateId, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteRBACPermissionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetReportTemplateResponse(rsp) + return http.StatusText(0) } -// UpdateReportTemplateWithBodyWithResponse request with arbitrary body returning *UpdateReportTemplateResponse -func (c *ClientWithResponses) UpdateReportTemplateWithBodyWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) { - rsp, err := c.UpdateReportTemplateWithBody(ctx, teamName, templateId, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteRBACPermissionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateReportTemplateResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdateReportTemplateWithResponse(ctx context.Context, teamName TeamName, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) { - rsp, err := c.UpdateReportTemplate(ctx, teamName, templateId, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateReportTemplateResponse(rsp) +type GetRBACPermissionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *RBACPermission + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// DeleteReportWithResponse request returning *DeleteReportResponse -func (c *ClientWithResponses) DeleteReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) { - rsp, err := c.DeleteReport(ctx, teamName, reportId, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetRBACPermissionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDeleteReportResponse(rsp) + return http.StatusText(0) } -// GetReportWithResponse request returning *GetReportResponse -func (c *ClientWithResponses) GetReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) { - rsp, err := c.GetReport(ctx, teamName, reportId, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetRBACPermissionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetReportResponse(rsp) + return 0 } -// UpdateReportWithBodyWithResponse request with arbitrary body returning *UpdateReportResponse -func (c *ClientWithResponses) UpdateReportWithBodyWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) { - rsp, err := c.UpdateReportWithBody(ctx, teamName, reportId, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateReportResponse(rsp) +type UpdateRBACPermissionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *RBACPermission + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) UpdateReportWithResponse(ctx context.Context, teamName TeamName, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) { - rsp, err := c.UpdateReport(ctx, teamName, reportId, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateRBACPermissionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateReportResponse(rsp) + return http.StatusText(0) } -// CreateSyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateSyncDestinationTestConnectionResponse -func (c *ClientWithResponses) CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateSyncDestinationTestConnectionWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateRBACPermissionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseCreateSyncDestinationTestConnectionResponse(rsp) + return 0 } -func (c *ClientWithResponses) CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateSyncDestinationTestConnection(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +type ListAllRBACRolesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Role `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseCreateSyncDestinationTestConnectionResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSyncDestinationTestConnectionWithResponse request returning *GetSyncDestinationTestConnectionResponse -func (c *ClientWithResponses) GetSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) { - rsp, err := c.GetSyncDestinationTestConnection(ctx, teamName, syncDestinationTestConnectionID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListAllRBACRolesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncDestinationTestConnectionResponse(rsp) + return http.StatusText(0) } -// UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncDestinationResponse -func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { - rsp, err := c.UpdateSyncTestConnectionForSyncDestinationWithBody(ctx, teamName, syncDestinationTestConnectionID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllRBACRolesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { - rsp, err := c.UpdateSyncTestConnectionForSyncDestination(ctx, teamName, syncDestinationTestConnectionID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp) +type CreateRBACRoleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *Role + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSyncDestinationTestConnectionLogsWithResponse request returning *GetSyncDestinationTestConnectionLogsResponse -func (c *ClientWithResponses) GetSyncDestinationTestConnectionLogsWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsResponse, error) { - rsp, err := c.GetSyncDestinationTestConnectionLogs(ctx, teamName, syncDestinationTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateRBACRoleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncDestinationTestConnectionLogsResponse(rsp) + return http.StatusText(0) } -// GetSyncDestinationTestConnectionLogsLiveWithResponse request returning *GetSyncDestinationTestConnectionLogsLiveResponse -func (c *ClientWithResponses) GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) { - rsp, err := c.GetSyncDestinationTestConnectionLogsLive(ctx, teamName, syncDestinationTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateRBACRoleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp) + return 0 } -// GetSyncDestinationTestConnectionLogsQueryWithResponse request returning *GetSyncDestinationTestConnectionLogsQueryResponse -func (c *ClientWithResponses) GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) { - rsp, err := c.GetSyncDestinationTestConnectionLogsQuery(ctx, teamName, syncDestinationTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp) +type DeleteRBACRoleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// PromoteSyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *PromoteSyncDestinationTestConnectionResponse -func (c *ClientWithResponses) PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) { - rsp, err := c.PromoteSyncDestinationTestConnectionWithBody(ctx, teamName, syncDestinationTestConnectionID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteRBACRoleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParsePromoteSyncDestinationTestConnectionResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) { - rsp, err := c.PromoteSyncDestinationTestConnection(ctx, teamName, syncDestinationTestConnectionID, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteRBACRoleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParsePromoteSyncDestinationTestConnectionResponse(rsp) + return 0 } -// ListSyncDestinationsWithResponse request returning *ListSyncDestinationsResponse -func (c *ClientWithResponses) ListSyncDestinationsWithResponse(ctx context.Context, teamName TeamName, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) { - rsp, err := c.ListSyncDestinations(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +type GetRBACRoleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Role + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetRBACRoleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListSyncDestinationsResponse(rsp) + return http.StatusText(0) } -// DeleteSyncDestinationWithResponse request returning *DeleteSyncDestinationResponse -func (c *ClientWithResponses) DeleteSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) { - rsp, err := c.DeleteSyncDestination(ctx, teamName, syncDestinationName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetRBACRoleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteSyncDestinationResponse(rsp) + return 0 } -// GetSyncDestinationWithResponse request returning *GetSyncDestinationResponse -func (c *ClientWithResponses) GetSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) { - rsp, err := c.GetSyncDestination(ctx, teamName, syncDestinationName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetSyncDestinationResponse(rsp) +type UpdateRBACRoleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Role + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// UpdateSyncDestinationWithBodyWithResponse request with arbitrary body returning *UpdateSyncDestinationResponse -func (c *ClientWithResponses) UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) { - rsp, err := c.UpdateSyncDestinationWithBody(ctx, teamName, syncDestinationName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateRBACRoleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateSyncDestinationResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UpdateSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) { - rsp, err := c.UpdateSyncDestination(ctx, teamName, syncDestinationName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateRBACRoleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateSyncDestinationResponse(rsp) + return 0 } -// MigrateSyncDestinationWithResponse request returning *MigrateSyncDestinationResponse -func (c *ClientWithResponses) MigrateSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*MigrateSyncDestinationResponse, error) { - rsp, err := c.MigrateSyncDestination(ctx, teamName, syncDestinationName, reqEditors...) - if err != nil { - return nil, err +type ListReportsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Metadata ListMetadata `json:"metadata"` + Reports []Report `json:"reports"` } - return ParseMigrateSyncDestinationResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound } -// ListSyncDestinationSyncsWithResponse request returning *ListSyncDestinationSyncsResponse -func (c *ClientWithResponses) ListSyncDestinationSyncsWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) { - rsp, err := c.ListSyncDestinationSyncs(ctx, teamName, syncDestinationName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListReportsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListSyncDestinationSyncsResponse(rsp) + return http.StatusText(0) } -// GetTestConnectionForSyncDestinationWithResponse request returning *GetTestConnectionForSyncDestinationResponse -func (c *ClientWithResponses) GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) { - rsp, err := c.GetTestConnectionForSyncDestination(ctx, teamName, syncDestinationName, syncTestConnectionId, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListReportsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetTestConnectionForSyncDestinationResponse(rsp) + return 0 } -// CreateSyncSourceTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateSyncSourceTestConnectionResponse -func (c *ClientWithResponses) CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) { - rsp, err := c.CreateSyncSourceTestConnectionWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type CreateReportResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + Data Report `json:"data"` } - return ParseCreateSyncSourceTestConnectionResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden } -func (c *ClientWithResponses) CreateSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) { - rsp, err := c.CreateSyncSourceTestConnection(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateReportResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateSyncSourceTestConnectionResponse(rsp) + return http.StatusText(0) } -// GetSyncSourceTestConnectionWithResponse request returning *GetSyncSourceTestConnectionResponse -func (c *ClientWithResponses) GetSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) { - rsp, err := c.GetSyncSourceTestConnection(ctx, teamName, syncSourceTestConnectionID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateReportResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncSourceTestConnectionResponse(rsp) + return 0 } -// UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncSourceResponse -func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { - rsp, err := c.UpdateSyncTestConnectionForSyncSourceWithBody(ctx, teamName, syncSourceTestConnectionID, contentType, body, reqEditors...) - if err != nil { - return nil, err +type ListReportTemplatesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Metadata ListMetadata `json:"metadata"` + Templates []ReportTemplate `json:"templates"` } - return ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound } -func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { - rsp, err := c.UpdateSyncTestConnectionForSyncSource(ctx, teamName, syncSourceTestConnectionID, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListReportTemplatesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp) + return http.StatusText(0) } -// GetSyncSourceTestConnectionLogsWithResponse request returning *GetSyncSourceTestConnectionLogsResponse -func (c *ClientWithResponses) GetSyncSourceTestConnectionLogsWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsResponse, error) { - rsp, err := c.GetSyncSourceTestConnectionLogs(ctx, teamName, syncSourceTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListReportTemplatesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncSourceTestConnectionLogsResponse(rsp) + return 0 } -// GetSyncSourceTestConnectionLogsLiveWithResponse request returning *GetSyncSourceTestConnectionLogsLiveResponse -func (c *ClientWithResponses) GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) { - rsp, err := c.GetSyncSourceTestConnectionLogsLive(ctx, teamName, syncSourceTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err +type CreateReportTemplateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + Data ReportTemplate `json:"data"` } - return ParseGetSyncSourceTestConnectionLogsLiveResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden } -// GetSyncSourceTestConnectionLogsQueryWithResponse request returning *GetSyncSourceTestConnectionLogsQueryResponse -func (c *ClientWithResponses) GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) { - rsp, err := c.GetSyncSourceTestConnectionLogsQuery(ctx, teamName, syncSourceTestConnectionID, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateReportTemplateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncSourceTestConnectionLogsQueryResponse(rsp) + return http.StatusText(0) } -// PromoteSyncSourceTestConnectionWithBodyWithResponse request with arbitrary body returning *PromoteSyncSourceTestConnectionResponse -func (c *ClientWithResponses) PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) { - rsp, err := c.PromoteSyncSourceTestConnectionWithBody(ctx, teamName, syncSourceTestConnectionID, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateReportTemplateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParsePromoteSyncSourceTestConnectionResponse(rsp) + return 0 } -func (c *ClientWithResponses) PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) { - rsp, err := c.PromoteSyncSourceTestConnection(ctx, teamName, syncSourceTestConnectionID, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePromoteSyncSourceTestConnectionResponse(rsp) +type DeleteReportTemplateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON403 *Forbidden + JSON404 *NotFound } -// ListSyncSourcesWithResponse request returning *ListSyncSourcesResponse -func (c *ClientWithResponses) ListSyncSourcesWithResponse(ctx context.Context, teamName TeamName, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) { - rsp, err := c.ListSyncSources(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteReportTemplateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListSyncSourcesResponse(rsp) + return http.StatusText(0) } -// DeleteSyncSourceWithResponse request returning *DeleteSyncSourceResponse -func (c *ClientWithResponses) DeleteSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) { - rsp, err := c.DeleteSyncSource(ctx, teamName, syncSourceName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteReportTemplateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteSyncSourceResponse(rsp) + return 0 } -// GetSyncSourceWithResponse request returning *GetSyncSourceResponse -func (c *ClientWithResponses) GetSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) { - rsp, err := c.GetSyncSource(ctx, teamName, syncSourceName, reqEditors...) - if err != nil { - return nil, err +type GetReportTemplateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data ReportTemplate `json:"data"` } - return ParseGetSyncSourceResponse(rsp) + JSON403 *Forbidden + JSON404 *NotFound } -// UpdateSyncSourceWithBodyWithResponse request with arbitrary body returning *UpdateSyncSourceResponse -func (c *ClientWithResponses) UpdateSyncSourceWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) { - rsp, err := c.UpdateSyncSourceWithBody(ctx, teamName, syncSourceName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetReportTemplateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateSyncSourceResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UpdateSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) { - rsp, err := c.UpdateSyncSource(ctx, teamName, syncSourceName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetReportTemplateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateSyncSourceResponse(rsp) + return 0 } -// MigrateSyncSourceWithResponse request returning *MigrateSyncSourceResponse -func (c *ClientWithResponses) MigrateSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*MigrateSyncSourceResponse, error) { - rsp, err := c.MigrateSyncSource(ctx, teamName, syncSourceName, reqEditors...) - if err != nil { - return nil, err +type UpdateReportTemplateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data ReportTemplate `json:"data"` } - return ParseMigrateSyncSourceResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound } -// ListSyncSourceSyncsWithResponse request returning *ListSyncSourceSyncsResponse -func (c *ClientWithResponses) ListSyncSourceSyncsWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) { - rsp, err := c.ListSyncSourceSyncs(ctx, teamName, syncSourceName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateReportTemplateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListSyncSourceSyncsResponse(rsp) + return http.StatusText(0) } -// GetTestConnectionForSyncSourceWithResponse request returning *GetTestConnectionForSyncSourceResponse -func (c *ClientWithResponses) GetTestConnectionForSyncSourceWithResponse(ctx context.Context, teamName TeamName, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) { - rsp, err := c.GetTestConnectionForSyncSource(ctx, teamName, syncSourceName, syncTestConnectionId, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateReportTemplateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetTestConnectionForSyncSourceResponse(rsp) + return 0 } -// ListSyncTransformersWithResponse request returning *ListSyncTransformersResponse -func (c *ClientWithResponses) ListSyncTransformersWithResponse(ctx context.Context, teamName TeamName, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) { - rsp, err := c.ListSyncTransformers(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseListSyncTransformersResponse(rsp) +type DeleteReportResponse struct { + Body []byte + HTTPResponse *http.Response + JSON403 *Forbidden + JSON404 *NotFound } -// DeleteSyncTransformerWithResponse request returning *DeleteSyncTransformerResponse -func (c *ClientWithResponses) DeleteSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) { - rsp, err := c.DeleteSyncTransformer(ctx, teamName, syncTransformerName, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteReportResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDeleteSyncTransformerResponse(rsp) + return http.StatusText(0) } -// GetSyncTransformerWithResponse request returning *GetSyncTransformerResponse -func (c *ClientWithResponses) GetSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) { - rsp, err := c.GetSyncTransformer(ctx, teamName, syncTransformerName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteReportResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncTransformerResponse(rsp) + return 0 } -// UpdateSyncTransformerWithBodyWithResponse request with arbitrary body returning *UpdateSyncTransformerResponse -func (c *ClientWithResponses) UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) { - rsp, err := c.UpdateSyncTransformerWithBody(ctx, teamName, syncTransformerName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type GetReportResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data Report `json:"data"` } - return ParseUpdateSyncTransformerResponse(rsp) + JSON403 *Forbidden + JSON404 *NotFound } -func (c *ClientWithResponses) UpdateSyncTransformerWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) { - rsp, err := c.UpdateSyncTransformer(ctx, teamName, syncTransformerName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetReportResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateSyncTransformerResponse(rsp) + return http.StatusText(0) } -// ListSyncTransformerSyncDestinationsWithResponse request returning *ListSyncTransformerSyncDestinationsResponse -func (c *ClientWithResponses) ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) { - rsp, err := c.ListSyncTransformerSyncDestinations(ctx, teamName, syncTransformerName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetReportResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListSyncTransformerSyncDestinationsResponse(rsp) + return 0 } -// ListSyncTransformerSyncsWithResponse request returning *ListSyncTransformerSyncsResponse -func (c *ClientWithResponses) ListSyncTransformerSyncsWithResponse(ctx context.Context, teamName TeamName, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) { - rsp, err := c.ListSyncTransformerSyncs(ctx, teamName, syncTransformerName, params, reqEditors...) - if err != nil { - return nil, err +type UpdateReportResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data Report `json:"data"` } - return ParseListSyncTransformerSyncsResponse(rsp) + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound } -// ListSyncUpgradesWithResponse request returning *ListSyncUpgradesResponse -func (c *ClientWithResponses) ListSyncUpgradesWithResponse(ctx context.Context, teamName TeamName, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) { - rsp, err := c.ListSyncUpgrades(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateReportResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListSyncUpgradesResponse(rsp) + return http.StatusText(0) } -// ListSyncsWithResponse request returning *ListSyncsResponse -func (c *ClientWithResponses) ListSyncsWithResponse(ctx context.Context, teamName TeamName, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) { - rsp, err := c.ListSyncs(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateReportResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListSyncsResponse(rsp) + return 0 } -// CreateSyncWithBodyWithResponse request with arbitrary body returning *CreateSyncResponse -func (c *ClientWithResponses) CreateSyncWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) { - rsp, err := c.CreateSyncWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateSyncResponse(rsp) +type GetSettingsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformSettings + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) CreateSyncWithResponse(ctx context.Context, teamName TeamName, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) { - rsp, err := c.CreateSync(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSettingsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateSyncResponse(rsp) + return http.StatusText(0) } -// GetTestConnectionConnectorCredentialsWithResponse request returning *GetTestConnectionConnectorCredentialsResponse -func (c *ClientWithResponses) GetTestConnectionConnectorCredentialsWithResponse(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetTestConnectionConnectorCredentialsResponse, error) { - rsp, err := c.GetTestConnectionConnectorCredentials(ctx, teamName, syncTestConnectionId, connectorID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSettingsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetTestConnectionConnectorCredentialsResponse(rsp) + return 0 } -// GetTestConnectionConnectorIdentityWithResponse request returning *GetTestConnectionConnectorIdentityResponse -func (c *ClientWithResponses) GetTestConnectionConnectorIdentityWithResponse(ctx context.Context, teamName TeamName, syncTestConnectionId SyncTestConnectionId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetTestConnectionConnectorIdentityResponse, error) { - rsp, err := c.GetTestConnectionConnectorIdentity(ctx, teamName, syncTestConnectionId, connectorID, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetTestConnectionConnectorIdentityResponse(rsp) +type UpdateSettingsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformSettings + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// DeleteSyncWithResponse request returning *DeleteSyncResponse -func (c *ClientWithResponses) DeleteSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) { - rsp, err := c.DeleteSync(ctx, teamName, syncName, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSettingsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseDeleteSyncResponse(rsp) + return http.StatusText(0) } -// GetSyncWithResponse request returning *GetSyncResponse -func (c *ClientWithResponses) GetSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) { - rsp, err := c.GetSync(ctx, teamName, syncName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSettingsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncResponse(rsp) + return 0 } -// UpdateSyncWithBodyWithResponse request with arbitrary body returning *UpdateSyncResponse -func (c *ClientWithResponses) UpdateSyncWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) { - rsp, err := c.UpdateSyncWithBody(ctx, teamName, syncName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateSyncResponse(rsp) +type GetDataSettingsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformDataSettings + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) UpdateSyncWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) { - rsp, err := c.UpdateSync(ctx, teamName, syncName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetDataSettingsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateSyncResponse(rsp) + return http.StatusText(0) } -// ListSyncRunsWithResponse request returning *ListSyncRunsResponse -func (c *ClientWithResponses) ListSyncRunsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) { - rsp, err := c.ListSyncRuns(ctx, teamName, syncName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetDataSettingsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListSyncRunsResponse(rsp) + return 0 } -// CreateSyncRunWithResponse request returning *CreateSyncRunResponse -func (c *ClientWithResponses) CreateSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) { - rsp, err := c.CreateSyncRun(ctx, teamName, syncName, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateSyncRunResponse(rsp) +type UpdateDataSettingsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformDataSettings + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSyncRunWithResponse request returning *GetSyncRunResponse -func (c *ClientWithResponses) GetSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) { - rsp, err := c.GetSyncRun(ctx, teamName, syncName, syncRunId, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateDataSettingsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncRunResponse(rsp) + return http.StatusText(0) } -// UpdateSyncRunWithBodyWithResponse request with arbitrary body returning *UpdateSyncRunResponse -func (c *ClientWithResponses) UpdateSyncRunWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) { - rsp, err := c.UpdateSyncRunWithBody(ctx, teamName, syncName, syncRunId, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateDataSettingsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateSyncRunResponse(rsp) + return 0 } -func (c *ClientWithResponses) UpdateSyncRunWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) { - rsp, err := c.UpdateSyncRun(ctx, teamName, syncName, syncRunId, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUpdateSyncRunResponse(rsp) +type CreateSlackConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SlackConnection + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSyncRunConnectorCredentialsWithResponse request returning *GetSyncRunConnectorCredentialsResponse -func (c *ClientWithResponses) GetSyncRunConnectorCredentialsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetSyncRunConnectorCredentialsResponse, error) { - rsp, err := c.GetSyncRunConnectorCredentials(ctx, teamName, syncName, syncRunId, connectorID, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateSlackConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncRunConnectorCredentialsResponse(rsp) + return http.StatusText(0) } -// GetSyncRunConnectorIdentityWithResponse request returning *GetSyncRunConnectorIdentityResponse -func (c *ClientWithResponses) GetSyncRunConnectorIdentityWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, connectorID ConnectorID, reqEditors ...RequestEditorFn) (*GetSyncRunConnectorIdentityResponse, error) { - rsp, err := c.GetSyncRunConnectorIdentity(ctx, teamName, syncName, syncRunId, connectorID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSlackConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncRunConnectorIdentityResponse(rsp) + return 0 } -// GetSyncRunLogsWithResponse request returning *GetSyncRunLogsResponse -func (c *ClientWithResponses) GetSyncRunLogsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsResponse, error) { - rsp, err := c.GetSyncRunLogs(ctx, teamName, syncName, syncRunId, params, reqEditors...) - if err != nil { - return nil, err +type ListSlackChannelsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SlackChannel `json:"items"` } - return ParseGetSyncRunLogsResponse(rsp) + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetSyncRunLogsLiveWithResponse request returning *GetSyncRunLogsLiveResponse -func (c *ClientWithResponses) GetSyncRunLogsLiveWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) { - rsp, err := c.GetSyncRunLogsLive(ctx, teamName, syncName, syncRunId, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSlackChannelsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetSyncRunLogsLiveResponse(rsp) + return http.StatusText(0) } -// GetSyncRunLogsQueryWithResponse request returning *GetSyncRunLogsQueryResponse -func (c *ClientWithResponses) GetSyncRunLogsQueryWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) { - rsp, err := c.GetSyncRunLogsQuery(ctx, teamName, syncName, syncRunId, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSlackChannelsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncRunLogsQueryResponse(rsp) + return 0 } -// CreateSyncRunProgressWithBodyWithResponse request with arbitrary body returning *CreateSyncRunProgressResponse -func (c *ClientWithResponses) CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) { - rsp, err := c.CreateSyncRunProgressWithBody(ctx, teamName, syncName, syncRunId, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateSyncRunProgressResponse(rsp) +type CreateSyncDestinationTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncDestinationTestConnection + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError } -func (c *ClientWithResponses) CreateSyncRunProgressWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) { - rsp, err := c.CreateSyncRunProgress(ctx, teamName, syncName, syncRunId, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateSyncDestinationTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateSyncRunProgressResponse(rsp) + return http.StatusText(0) } -// GetSyncRunStatsWithResponse request returning *GetSyncRunStatsResponse -func (c *ClientWithResponses) GetSyncRunStatsWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) { - rsp, err := c.GetSyncRunStats(ctx, teamName, syncName, syncRunId, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncDestinationTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetSyncRunStatsResponse(rsp) + return 0 } -// GetSyncRunTablesWithResponse request returning *GetSyncRunTablesResponse -func (c *ClientWithResponses) GetSyncRunTablesWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) { - rsp, err := c.GetSyncRunTables(ctx, teamName, syncName, syncRunId, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetSyncRunTablesResponse(rsp) +type GetSyncDestinationTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestinationTestConnection + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -// ListTablesTeamWithResponse request returning *ListTablesTeamResponse -func (c *ClientWithResponses) ListTablesTeamWithResponse(ctx context.Context, teamName TeamName, params *ListTablesTeamParams, reqEditors ...RequestEditorFn) (*ListTablesTeamResponse, error) { - rsp, err := c.ListTablesTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncDestinationTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListTablesTeamResponse(rsp) + return http.StatusText(0) } -// BatchTableSchemasTeamWithResponse request returning *BatchTableSchemasTeamResponse -func (c *ClientWithResponses) BatchTableSchemasTeamWithResponse(ctx context.Context, teamName TeamName, params *BatchTableSchemasTeamParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasTeamResponse, error) { - rsp, err := c.BatchTableSchemasTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncDestinationTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseBatchTableSchemasTeamResponse(rsp) + return 0 } -// TableListColumnsTeamWithResponse request returning *TableListColumnsTeamResponse -func (c *ClientWithResponses) TableListColumnsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListColumnsTeamParams, reqEditors ...RequestEditorFn) (*TableListColumnsTeamResponse, error) { - rsp, err := c.TableListColumnsTeam(ctx, teamName, tableName, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseTableListColumnsTeamResponse(rsp) +type UpdateSyncTestConnectionForSyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestinationTestConnection + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// TableColumnListValuesTeamWithResponse request returning *TableColumnListValuesTeamResponse -func (c *ClientWithResponses) TableColumnListValuesTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, columnName ColumnName, params *TableColumnListValuesTeamParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesTeamResponse, error) { - rsp, err := c.TableColumnListValuesTeam(ctx, teamName, tableName, columnName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncTestConnectionForSyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseTableColumnListValuesTeamResponse(rsp) + return http.StatusText(0) } -// TableListRowsTeamWithResponse request returning *TableListRowsTeamResponse -func (c *ClientWithResponses) TableListRowsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRowsTeamParams, reqEditors ...RequestEditorFn) (*TableListRowsTeamResponse, error) { - rsp, err := c.TableListRowsTeam(ctx, teamName, tableName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncTestConnectionForSyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseTableListRowsTeamResponse(rsp) + return 0 } -// TableRowByIdTeamWithResponse request returning *TableRowByIdTeamResponse -func (c *ClientWithResponses) TableRowByIdTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, tableRowId TableRowId, params *TableRowByIdTeamParams, reqEditors ...RequestEditorFn) (*TableRowByIdTeamResponse, error) { - rsp, err := c.TableRowByIdTeam(ctx, teamName, tableName, tableRowId, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseTableRowByIdTeamResponse(rsp) +type GetSyncDestinationTestConnectionLogsLiveResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// TableListFiltersTeamWithResponse request returning *TableListFiltersTeamResponse -func (c *ClientWithResponses) TableListFiltersTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFiltersTeamParams, reqEditors ...RequestEditorFn) (*TableListFiltersTeamResponse, error) { - rsp, err := c.TableListFiltersTeam(ctx, teamName, tableName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncDestinationTestConnectionLogsLiveResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseTableListFiltersTeamResponse(rsp) + return http.StatusText(0) } -// TableSaveFilterTeamWithBodyWithResponse request with arbitrary body returning *TableSaveFilterTeamResponse -func (c *ClientWithResponses) TableSaveFilterTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterTeamResponse, error) { - rsp, err := c.TableSaveFilterTeamWithBody(ctx, teamName, tableName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncDestinationTestConnectionLogsLiveResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseTableSaveFilterTeamResponse(rsp) + return 0 } -func (c *ClientWithResponses) TableSaveFilterTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, body TableSaveFilterTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterTeamResponse, error) { - rsp, err := c.TableSaveFilterTeam(ctx, teamName, tableName, body, reqEditors...) - if err != nil { - return nil, err +type GetSyncDestinationTestConnectionLogsQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } - return ParseTableSaveFilterTeamResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// TableListFilterTagsTeamWithResponse request returning *TableListFilterTagsTeamResponse -func (c *ClientWithResponses) TableListFilterTagsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListFilterTagsTeamParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsTeamResponse, error) { - rsp, err := c.TableListFilterTagsTeam(ctx, teamName, tableName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncDestinationTestConnectionLogsQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseTableListFilterTagsTeamResponse(rsp) + return http.StatusText(0) } -// TableListRelationsTeamWithResponse request returning *TableListRelationsTeamResponse -func (c *ClientWithResponses) TableListRelationsTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, params *TableListRelationsTeamParams, reqEditors ...RequestEditorFn) (*TableListRelationsTeamResponse, error) { - rsp, err := c.TableListRelationsTeam(ctx, teamName, tableName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncDestinationTestConnectionLogsQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseTableListRelationsTeamResponse(rsp) + return 0 } -// TableSchemaTeamWithResponse request returning *TableSchemaTeamResponse -func (c *ClientWithResponses) TableSchemaTeamWithResponse(ctx context.Context, teamName TeamName, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaTeamResponse, error) { - rsp, err := c.TableSchemaTeam(ctx, teamName, tableName, reqEditors...) - if err != nil { - return nil, err - } - return ParseTableSchemaTeamResponse(rsp) +type PromoteSyncDestinationTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestination + JSON201 *SyncDestination + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// GetTeamUsageSummaryWithResponse request returning *GetTeamUsageSummaryResponse -func (c *ClientWithResponses) GetTeamUsageSummaryWithResponse(ctx context.Context, teamName TeamName, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) { - rsp, err := c.GetTeamUsageSummary(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r PromoteSyncDestinationTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseGetTeamUsageSummaryResponse(rsp) + return http.StatusText(0) } -// GetGroupedTeamUsageSummaryWithResponse request returning *GetGroupedTeamUsageSummaryResponse -func (c *ClientWithResponses) GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, teamName TeamName, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) { - rsp, err := c.GetGroupedTeamUsageSummary(ctx, teamName, groupBy, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r PromoteSyncDestinationTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetGroupedTeamUsageSummaryResponse(rsp) + return 0 } -// ListUsersByTeamWithResponse request returning *ListUsersByTeamResponse -func (c *ClientWithResponses) ListUsersByTeamWithResponse(ctx context.Context, teamName TeamName, params *ListUsersByTeamParams, reqEditors ...RequestEditorFn) (*ListUsersByTeamResponse, error) { - rsp, err := c.ListUsersByTeam(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +type ListSyncDestinationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncDestination `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseListUsersByTeamResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// UploadImageWithBodyWithResponse request with arbitrary body returning *UploadImageResponse -func (c *ClientWithResponses) UploadImageWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UploadImageResponse, error) { - rsp, err := c.UploadImageWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSyncDestinationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUploadImageResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UploadImageWithResponse(ctx context.Context, body UploadImageJSONRequestBody, reqEditors ...RequestEditorFn) (*UploadImageResponse, error) { - rsp, err := c.UploadImage(ctx, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncDestinationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUploadImageResponse(rsp) + return 0 } -// GetCurrentUserWithResponse request returning *GetCurrentUserResponse -func (c *ClientWithResponses) GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) { - rsp, err := c.GetCurrentUser(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetCurrentUserResponse(rsp) +type DeleteSyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// UpdateCurrentUserWithBodyWithResponse request with arbitrary body returning *UpdateCurrentUserResponse -func (c *ClientWithResponses) UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) { - rsp, err := c.UpdateCurrentUserWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteSyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateCurrentUserResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) { - rsp, err := c.UpdateCurrentUser(ctx, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateCurrentUserResponse(rsp) + return 0 } -// SendAnonymousEventWithBodyWithResponse request with arbitrary body returning *SendAnonymousEventResponse -func (c *ClientWithResponses) SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) { - rsp, err := c.SendAnonymousEventWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSendAnonymousEventResponse(rsp) +type GetSyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestination + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -func (c *ClientWithResponses) SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) { - rsp, err := c.SendAnonymousEvent(ctx, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseSendAnonymousEventResponse(rsp) + return http.StatusText(0) } -// AuthenticateLocalUserWithBodyWithResponse request with arbitrary body returning *AuthenticateLocalUserResponse -func (c *ClientWithResponses) AuthenticateLocalUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateLocalUserResponse, error) { - rsp, err := c.AuthenticateLocalUserWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseAuthenticateLocalUserResponse(rsp) + return 0 } -func (c *ClientWithResponses) AuthenticateLocalUserWithResponse(ctx context.Context, body AuthenticateLocalUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateLocalUserResponse, error) { - rsp, err := c.AuthenticateLocalUser(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseAuthenticateLocalUserResponse(rsp) +type UpdateSyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestination + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ChangeLocalUserPasswordWithBodyWithResponse request with arbitrary body returning *ChangeLocalUserPasswordResponse -func (c *ClientWithResponses) ChangeLocalUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeLocalUserPasswordResponse, error) { - rsp, err := c.ChangeLocalUserPasswordWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseChangeLocalUserPasswordResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) ChangeLocalUserPasswordWithResponse(ctx context.Context, body ChangeLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeLocalUserPasswordResponse, error) { - rsp, err := c.ChangeLocalUserPassword(ctx, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseChangeLocalUserPasswordResponse(rsp) + return 0 } -// UpdateCustomerWithBodyWithResponse request with arbitrary body returning *UpdateCustomerResponse -func (c *ClientWithResponses) UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) { - rsp, err := c.UpdateCustomerWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +type ListSyncDestinationSyncsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []ListSync `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseUpdateCustomerResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -func (c *ClientWithResponses) UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) { - rsp, err := c.UpdateCustomer(ctx, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSyncDestinationSyncsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateCustomerResponse(rsp) + return http.StatusText(0) } -// SendUserEventWithBodyWithResponse request with arbitrary body returning *SendUserEventResponse -func (c *ClientWithResponses) SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) { - rsp, err := c.SendUserEventWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncDestinationSyncsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseSendUserEventResponse(rsp) + return 0 } -func (c *ClientWithResponses) SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) { - rsp, err := c.SendUserEvent(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseSendUserEventResponse(rsp) +type GetTestConnectionForSyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncTestConnection + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ListCurrentUserInvitationsWithResponse request returning *ListCurrentUserInvitationsResponse -func (c *ClientWithResponses) ListCurrentUserInvitationsWithResponse(ctx context.Context, params *ListCurrentUserInvitationsParams, reqEditors ...RequestEditorFn) (*ListCurrentUserInvitationsResponse, error) { - rsp, err := c.ListCurrentUserInvitations(ctx, params, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetTestConnectionForSyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseListCurrentUserInvitationsResponse(rsp) + return http.StatusText(0) } -// GetCurrentLocalUserWithResponse request returning *GetCurrentLocalUserResponse -func (c *ClientWithResponses) GetCurrentLocalUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentLocalUserResponse, error) { - rsp, err := c.GetCurrentLocalUser(ctx, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetTestConnectionForSyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetCurrentLocalUserResponse(rsp) + return 0 } -// LogoutUserWithResponse request returning *LogoutUserResponse -func (c *ClientWithResponses) LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) { - rsp, err := c.LogoutUser(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseLogoutUserResponse(rsp) +type CreateSyncSourceTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncSourceTestConnection + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError } -// LoginUserWithBodyWithResponse request with arbitrary body returning *LoginUserResponse -func (c *ClientWithResponses) LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { - rsp, err := c.LoginUserWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateSyncSourceTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseLoginUserResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { - rsp, err := c.LoginUser(ctx, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncSourceTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseLoginUserResponse(rsp) + return 0 } -// GetCurrentUserMembershipsWithResponse request returning *GetCurrentUserMembershipsResponse -func (c *ClientWithResponses) GetCurrentUserMembershipsWithResponse(ctx context.Context, params *GetCurrentUserMembershipsParams, reqEditors ...RequestEditorFn) (*GetCurrentUserMembershipsResponse, error) { - rsp, err := c.GetCurrentUserMemberships(ctx, params, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetCurrentUserMembershipsResponse(rsp) +type GetSyncSourceTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSourceTestConnection + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError } -// ResetLocalUserPasswordWithBodyWithResponse request with arbitrary body returning *ResetLocalUserPasswordResponse -func (c *ClientWithResponses) ResetLocalUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ResetLocalUserPasswordResponse, error) { - rsp, err := c.ResetLocalUserPasswordWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncSourceTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseResetLocalUserPasswordResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) ResetLocalUserPasswordWithResponse(ctx context.Context, body ResetLocalUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ResetLocalUserPasswordResponse, error) { - rsp, err := c.ResetLocalUserPassword(ctx, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncSourceTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseResetLocalUserPasswordResponse(rsp) + return 0 } -// CreateUserTokenWithResponse request returning *CreateUserTokenResponse -func (c *ClientWithResponses) CreateUserTokenWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateUserTokenResponse, error) { - rsp, err := c.CreateUserToken(ctx, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateUserTokenResponse(rsp) +type UpdateSyncTestConnectionForSyncSourceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSourceTestConnection + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// UserTOTPDeleteWithResponse request returning *UserTOTPDeleteResponse -func (c *ClientWithResponses) UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) { - rsp, err := c.UserTOTPDelete(ctx, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncTestConnectionForSyncSourceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUserTOTPDeleteResponse(rsp) + return http.StatusText(0) } -// UserTOTPSetupWithResponse request returning *UserTOTPSetupResponse -func (c *ClientWithResponses) UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) { - rsp, err := c.UserTOTPSetup(ctx, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncTestConnectionForSyncSourceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUserTOTPSetupResponse(rsp) + return 0 } -// UserTOTPVerifyWithBodyWithResponse request with arbitrary body returning *UserTOTPVerifyResponse -func (c *ClientWithResponses) UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { - rsp, err := c.UserTOTPVerifyWithBody(ctx, params, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseUserTOTPVerifyResponse(rsp) +type GetSyncSourceTestConnectionLogsLiveResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { - rsp, err := c.UserTOTPVerify(ctx, params, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncSourceTestConnectionLogsLiveResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUserTOTPVerifyResponse(rsp) + return http.StatusText(0) } -// DeleteUserWithResponse request returning *DeleteUserResponse -func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) { - rsp, err := c.DeleteUser(ctx, userID, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncSourceTestConnectionLogsLiveResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteUserResponse(rsp) + return 0 } -// CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationTestConnectionResponse -func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncDestinationTestConnectionWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err +type GetSyncSourceTestConnectionLogsQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } - return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncDestinationTestConnection(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncSourceTestConnectionLogsQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) + return http.StatusText(0) } -// GetV2SyncDestinationsWithResponse request returning *GetV2SyncDestinationsResponse -func (c *ClientWithResponses) GetV2SyncDestinationsWithResponse(ctx context.Context, teamName TeamName, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) { - rsp, err := c.GetV2SyncDestinations(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncSourceTestConnectionLogsQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseGetV2SyncDestinationsResponse(rsp) + return 0 } -// CreateV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationResponse -func (c *ClientWithResponses) CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { - rsp, err := c.CreateV2SyncDestinationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateV2SyncDestinationResponse(rsp) +type PromoteSyncSourceTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSource + JSON201 *SyncSource + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) CreateV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { - rsp, err := c.CreateV2SyncDestination(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r PromoteSyncSourceTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateV2SyncDestinationResponse(rsp) + return http.StatusText(0) } -// DeleteV2SyncDestinationWithResponse request returning *DeleteV2SyncDestinationResponse -func (c *ClientWithResponses) DeleteV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) { - rsp, err := c.DeleteV2SyncDestination(ctx, teamName, syncDestinationName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r PromoteSyncSourceTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteV2SyncDestinationResponse(rsp) + return 0 } -// GetV2SyncDestinationWithResponse request returning *GetV2SyncDestinationResponse -func (c *ClientWithResponses) GetV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) { - rsp, err := c.GetV2SyncDestination(ctx, teamName, syncDestinationName, reqEditors...) - if err != nil { - return nil, err +type ListSyncSourcesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncSource `json:"items"` + Metadata ListMetadata `json:"metadata"` } - return ParseGetV2SyncDestinationResponse(rsp) + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// PatchV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *PatchV2SyncDestinationResponse -func (c *ClientWithResponses) PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { - rsp, err := c.PatchV2SyncDestinationWithBody(ctx, teamName, syncDestinationName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSyncSourcesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParsePatchV2SyncDestinationResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) PatchV2SyncDestinationWithResponse(ctx context.Context, teamName TeamName, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { - rsp, err := c.PatchV2SyncDestination(ctx, teamName, syncDestinationName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncSourcesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParsePatchV2SyncDestinationResponse(rsp) + return 0 } -// CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationTestConnectionResponse -func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncIntegrationTestConnectionWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) +type DeleteSyncSourceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncIntegrationTestConnection(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteSyncSourceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) + return http.StatusText(0) } -// ListV2SyncIntegrationsWithResponse request returning *ListV2SyncIntegrationsResponse -func (c *ClientWithResponses) ListV2SyncIntegrationsWithResponse(ctx context.Context, teamName TeamName, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) { - rsp, err := c.ListV2SyncIntegrations(ctx, teamName, params, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSyncSourceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseListV2SyncIntegrationsResponse(rsp) + return 0 } -// CreateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationResponse -func (c *ClientWithResponses) CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, teamName TeamName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { - rsp, err := c.CreateV2SyncIntegrationWithBody(ctx, teamName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateV2SyncIntegrationResponse(rsp) +type GetSyncSourceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSource + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -func (c *ClientWithResponses) CreateV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { - rsp, err := c.CreateV2SyncIntegration(ctx, teamName, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncSourceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseCreateV2SyncIntegrationResponse(rsp) + return http.StatusText(0) } -// DeleteV2SyncIntegrationWithResponse request returning *DeleteV2SyncIntegrationResponse -func (c *ClientWithResponses) DeleteV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) { - rsp, err := c.DeleteV2SyncIntegration(ctx, teamName, syncName, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncSourceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseDeleteV2SyncIntegrationResponse(rsp) + return 0 } -// GetV2SyncIntegrationWithResponse request returning *GetV2SyncIntegrationResponse -func (c *ClientWithResponses) GetV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) { - rsp, err := c.GetV2SyncIntegration(ctx, teamName, syncName, reqEditors...) - if err != nil { - return nil, err - } - return ParseGetV2SyncIntegrationResponse(rsp) +type UpdateSyncSourceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSource + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// UpdateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *UpdateV2SyncIntegrationResponse -func (c *ClientWithResponses) UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { - rsp, err := c.UpdateV2SyncIntegrationWithBody(ctx, teamName, syncName, contentType, body, reqEditors...) - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncSourceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - return ParseUpdateV2SyncIntegrationResponse(rsp) + return http.StatusText(0) } -func (c *ClientWithResponses) UpdateV2SyncIntegrationWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { - rsp, err := c.UpdateV2SyncIntegration(ctx, teamName, syncName, body, reqEditors...) - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncSourceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } - return ParseUpdateV2SyncIntegrationResponse(rsp) + return 0 } -// ParseIndexResponse parses an HTTP response from a IndexWithResponse call -func ParseIndexResponse(rsp *http.Response) (*IndexResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +type ListSyncSourceSyncsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []ListSync `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - response := &IndexResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// Status returns HTTPResponse.Status +func (r ListSyncSourceSyncsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest struct { - Errors *[]string `json:"errors,omitempty"` - FieldErrors *map[string]string `json:"field_errors,omitempty"` - Message string `json:"message"` - Status int `json:"status"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncSourceSyncsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type GetTestConnectionForSyncSourceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncTestConnection + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ParseListAuditLogsResponse parses an HTTP response from a ListAuditLogsWithResponse call -func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetTestConnectionForSyncSourceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ListAuditLogsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r GetTestConnectionForSyncSourceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []AuditLogEvent `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - +type ListSyncTransformersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncTransformer `json:"items"` + Metadata ListMetadata `json:"metadata"` } - - return response, nil + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ParseGetAuditLogResponse parses an HTTP response from a GetAuditLogWithResponse call -func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSyncTransformersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &GetAuditLogResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncTransformersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest AuditLogEvent - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +type DeleteSyncTransformerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r DeleteSyncTransformerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSyncTransformerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type GetSyncTransformerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncTransformer + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ParseHealthCheckResponse parses an HTTP response from a HealthCheckWithResponse call -func ParseHealthCheckResponse(rsp *http.Response) (*HealthCheckResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncTransformerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &HealthCheckResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncTransformerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: - var dest ServiceUnavailable - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON503 = &dest +type UpdateSyncTransformerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncTransformer + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r UpdateSyncTransformerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - - return response, nil + return http.StatusText(0) } -// ParseHealthCheckHeadResponse parses an HTTP response from a HealthCheckHeadWithResponse call -func ParseHealthCheckHeadResponse(rsp *http.Response) (*HealthCheckHeadResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncTransformerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - response := &HealthCheckHeadResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +type ListSyncTransformerSyncDestinationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncDestination `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: - var dest ServiceUnavailable - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON503 = &dest - +// Status returns HTTPResponse.Status +func (r ListSyncTransformerSyncDestinationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - - return response, nil + return http.StatusText(0) } -// ParseAssetViewGetStatusResponse parses an HTTP response from a AssetViewGetStatusWithResponse call -func ParseAssetViewGetStatusResponse(rsp *http.Response) (*AssetViewGetStatusResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncTransformerSyncDestinationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - response := &AssetViewGetStatusResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +type ListSyncTransformerSyncsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Sync `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // IsRunning Whether the assetview is currently running - IsRunning bool `json:"is_running"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - +// Status returns HTTPResponse.Status +func (r ListSyncTransformerSyncsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - - return response, nil + return http.StatusText(0) } -// ParseAssetViewTriggerResponse parses an HTTP response from a AssetViewTriggerWithResponse call -func ParseAssetViewTriggerResponse(rsp *http.Response) (*AssetViewTriggerResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncTransformerSyncsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - response := &AssetViewTriggerResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +type ListSyncUpgradesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncUpgrade `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r ListSyncUpgradesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncUpgradesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type ListSyncsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []ListSync `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r ListSyncsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type CreateSyncResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *Sync + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseAssetViewListLogsResponse parses an HTTP response from a AssetViewListLogsWithResponse call -func ParseAssetViewListLogsResponse(rsp *http.Response) (*AssetViewListLogsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateSyncResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &AssetViewListLogsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []AssetViewRun `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type DeleteSyncResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r DeleteSyncResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSyncResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type GetSyncResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Sync + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ParseManageGetSAMLResponse parses an HTTP response from a ManageGetSAMLWithResponse call -func ParseManageGetSAMLResponse(rsp *http.Response) (*ManageGetSAMLResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetSyncResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageGetSAMLResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SAMLConfig - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +type UpdateSyncResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Sync + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r UpdateSyncResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type ListSyncRunsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncRun `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError } -// ParseManageUpdateSAMLResponse parses an HTTP response from a ManageUpdateSAMLWithResponse call -func ParseManageUpdateSAMLResponse(rsp *http.Response) (*ManageUpdateSAMLResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r ListSyncRunsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageUpdateSAMLResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r ListSyncRunsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SAMLConfig - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type CreateSyncRunResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncRun + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r CreateSyncRunResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncRunResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type GetSyncRunResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncRunDetails + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r GetSyncRunResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncRunResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type UpdateSyncRunResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncRun + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseManageGetPlatformRegistryResponse parses an HTTP response from a ManageGetPlatformRegistryWithResponse call -func ParseManageGetPlatformRegistryResponse(rsp *http.Response) (*ManageGetPlatformRegistryResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncRunResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageGetPlatformRegistryResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncRunResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // ActivationID Activation ID - ActivationID *openapi_types.UUID `json:"activation_id,omitempty"` +type GetSyncRunLogsLiveResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetSyncRunLogsLiveResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - // APIKeyLastFour Last 4 characters of the API key - APIKeyLastFour *string `json:"api_key_last_four,omitempty"` +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncRunLogsLiveResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - // InstallationID Installation ID - InstallationID string `json:"installation_id"` +type GetSyncRunLogsQueryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - // LastActivatedAt Timestamp of the last activation - LastActivatedAt *time.Time `json:"last_activated_at,omitempty"` +// Status returns HTTPResponse.Status +func (r GetSyncRunLogsQueryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - // NextActivationAt Timestamp of the next activation - NextActivationAt *time.Time `json:"next_activation_at,omitempty"` +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncRunLogsQueryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - // OfflineLicenseExpiresAt Timestamp of the offline license expiration - OfflineLicenseExpiresAt *time.Time `json:"offline_license_expires_at,omitempty"` +type CreateSyncRunProgressResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - // OfflineLicenseRegisteredTo Name the offline license is registered to - OfflineLicenseRegisteredTo *string `json:"offline_license_registered_to,omitempty"` +// Status returns HTTPResponse.Status +func (r CreateSyncRunProgressResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - // TeamName Name of the team that was activated - TeamName *string `json:"team_name,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncRunProgressResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +type GetSyncRunStatsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncRunStats + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r GetSyncRunStatsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncRunStatsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type GetSyncRunTablesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncRunTableStat `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r GetSyncRunTablesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } - - return response, nil + return http.StatusText(0) } -// ParseManageRegisterPlatformResponse parses an HTTP response from a ManageRegisterPlatformWithResponse call -func ParseManageRegisterPlatformResponse(rsp *http.Response) (*ManageRegisterPlatformResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r GetSyncRunTablesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - response := &ManageRegisterPlatformResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +type ListTablesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []TableListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // TeamName Name of the team that was activated - TeamName string `json:"team_name"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// Status returns HTTPResponse.Status +func (r ListTablesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 205: - var dest struct { - // ButtonText Text for the button - ButtonText *string `json:"button_text,omitempty"` +// StatusCode returns HTTPResponse.StatusCode +func (r ListTablesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - // ButtonURL URL for the button - ButtonURL *string `json:"button_url,omitempty"` +type GetTablesDataResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Metadata ListMetadata `json:"metadata"` + Syncs []TableDataListItem `json:"syncs"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} - // Error Error message - Error string `json:"error"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON205 = &dest +// Status returns HTTPResponse.Status +func (r GetTablesDataResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r GetTablesDataResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +type TablesDataActionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// Status returns HTTPResponse.Status +func (r TablesDataActionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TablesDataActionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type BatchTableSchemasResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []BatchTableSchemaItem `json:"items"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r BatchTableSchemasResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return response, nil +// StatusCode returns HTTPResponse.StatusCode +func (r BatchTableSchemasResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// ParseManageRegisterPlatformWithOfflineLicenseResponse parses an HTTP response from a ManageRegisterPlatformWithOfflineLicenseWithResponse call -func ParseManageRegisterPlatformWithOfflineLicenseResponse(rsp *http.Response) (*ManageRegisterPlatformWithOfflineLicenseResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +type TableListColumnsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []TableColumnListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - response := &ManageRegisterPlatformWithOfflineLicenseResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// Status returns HTTPResponse.Status +func (r TableListColumnsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // ExpiresAt Timestamp of the offline license expiration - ExpiresAt time.Time `json:"expires_at"` +// StatusCode returns HTTPResponse.StatusCode +func (r TableListColumnsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - // RegisteredTo Name the offline license is registered to - RegisteredTo string `json:"registered_to"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type TableColumnListValuesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []TableColumnValueListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r TableColumnListValuesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TableColumnListValuesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type TableListRowsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest +// Status returns HTTPResponse.Status +func (r TableListRowsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TableListRowsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} +type TableRowByIdResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Data TableRow `json:"data"` + Matches []TableRowFieldMatch `json:"matches"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - return response, nil +// Status returns HTTPResponse.Status +func (r TableRowByIdResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) } -// ParseGetSettingsResponse parses an HTTP response from a GetSettingsWithResponse call -func ParseGetSettingsResponse(rsp *http.Response) (*GetSettingsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// StatusCode returns HTTPResponse.StatusCode +func (r TableRowByIdResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - response := &GetSettingsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +type TableListFiltersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PlatformSettings - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// Status returns HTTPResponse.Status +func (r TableListFiltersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TableListFiltersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type TableSaveFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Filter + JSON201 *Filter + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r TableSaveFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TableSaveFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type TableListFilterTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r TableListFilterTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return response, nil +// StatusCode returns HTTPResponse.StatusCode +func (r TableListFilterTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// ParseUpdateSettingsResponse parses an HTTP response from a UpdateSettingsWithResponse call -func ParseUpdateSettingsResponse(rsp *http.Response) (*UpdateSettingsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +type TableSchemaResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + DefaultColumns []string `json:"default_columns"` + Schema TableSchema `json:"schema"` } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - response := &UpdateSettingsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// Status returns HTTPResponse.Status +func (r TableSchemaResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PlatformSettings - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r TableSchemaResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type ListTeamsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Team `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r ListTeamsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r ListTeamsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type DownloadPluginAssetByTeamResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PluginAsset + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON429 *TooManyRequests + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r DownloadPluginAssetByTeamResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r DownloadPluginAssetByTeamResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type UpdateSyncTestConnectionForSyncDestinationTeamResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestinationTestConnection + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseManageListAllTeamsResponse parses an HTTP response from a ManageListAllTeamsWithResponse call -func ParseManageListAllTeamsResponse(rsp *http.Response) (*ManageListAllTeamsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r UpdateSyncTestConnectionForSyncDestinationTeamResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageListAllTeamsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncTestConnectionForSyncDestinationTeamResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Team `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type UpdateSyncTestConnectionForSyncSourceTeamResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncSourceTestConnection + JSON400 *BadRequest + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r UpdateSyncTestConnectionForSyncSourceTeamResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateSyncTestConnectionForSyncSourceTeamResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type CreateSyncRunProgressTeamResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseManageDeleteTeamResponse parses an HTTP response from a ManageDeleteTeamWithResponse call -func ParseManageDeleteTeamResponse(rsp *http.Response) (*ManageDeleteTeamResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateSyncRunProgressTeamResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageDeleteTeamResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSyncRunProgressTeamResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type GetTeamUsageSummaryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *UsageSummary + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r GetTeamUsageSummaryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r GetTeamUsageSummaryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type GetGroupedTeamUsageSummaryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *UsageSummary + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseManageGetTeamResponse parses an HTTP response from a ManageGetTeamWithResponse call -func ParseManageGetTeamResponse(rsp *http.Response) (*ManageGetTeamResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetGroupedTeamUsageSummaryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageGetTeamResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r GetGroupedTeamUsageSummaryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Team - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type GetCurrentUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + CreatedAt *time.Time `json:"created_at,omitempty"` + Email string `json:"email"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest + // Enabled Whether the user is enabled + Enabled bool `json:"enabled"` + EventIdentifiers *map[string]interface{} `json:"event_identifiers,omitempty"` + GroupIdentifier *string `json:"group_identifier,omitempty"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest + // ID ID of the User + ID openapi_types.UUID `json:"id"` + LastLoginAt *time.Time `json:"last_login_at,omitempty"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest + // MFAConfigured Whether the user has MFA configured + MFAConfigured bool `json:"mfa_configured"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest + // Name The unique name for the user. + Name *UserName `json:"name,omitempty"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest + // ProfileImageURL Profile image URL of user + ProfileImageURL *string `json:"profile_image_url,omitempty"` + Provider UserProvider `json:"provider"` - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest + // RegisteredTeamInternal Whether the team is internal or not + RegisteredTeamInternal *bool `json:"registered_team_internal,omitempty"` + // RegisteredTeamName The name of the team that the platform is registered with + RegisteredTeamName *string `json:"registered_team_name,omitempty"` + Roles []Role `json:"roles"` + + // TrackingOptedIn Whether anonymous user tracking was opted into + TrackingOptedIn *bool `json:"tracking_opted_in,omitempty"` + UpdatedAt *time.Time `json:"updated_at,omitempty"` } + JSON401 *struct { + Message string `json:"message"` - return response, nil + // PasswordResetRequired Whether the user needs to reset their password + PasswordResetRequired *bool `json:"password_reset_required,omitempty"` + Status int `json:"status"` + } + JSON403 *Forbidden + JSON500 *InternalError } -// ParseManageRemoveTeamMemberResponse parses an HTTP response from a ManageRemoveTeamMemberWithResponse call -func ParseManageRemoveTeamMemberResponse(rsp *http.Response) (*ManageRemoveTeamMemberResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r GetCurrentUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageRemoveTeamMemberResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r GetCurrentUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type UpdateCurrentUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *User + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON405 *MethodNotAllowed + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r UpdateCurrentUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateCurrentUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type SendAnonymousEventResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON404 *NotFound + JSON429 *TooManyRequests + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r SendAnonymousEventResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r SendAnonymousEventResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type AuthenticateUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + IDToken string `json:"id_token"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError } -// ParseManageListTeamMembersResponse parses an HTTP response from a ManageListTeamMembersWithResponse call -func ParseManageListTeamMembersResponse(rsp *http.Response) (*ManageListTeamMembersResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r AuthenticateUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageListTeamMembersResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r AuthenticateUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []MembershipWithUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type ChangeUserPasswordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r ChangeUserPasswordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r ChangeUserPasswordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type UpdateCustomerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r UpdateCustomerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateCustomerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type SendUserEventResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r SendUserEventResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r SendUserEventResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type LogoutUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON500 *InternalError } -// ParseManageAddTeamMemberResponse parses an HTTP response from a ManageAddTeamMemberWithResponse call -func ParseManageAddTeamMemberResponse(rsp *http.Response) (*ManageAddTeamMemberResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r LogoutUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &ManageAddTeamMemberResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r LogoutUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type LoginUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r LoginUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r LoginUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type UserTOTPDeleteResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r UserTOTPDeleteResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return response, nil +// StatusCode returns HTTPResponse.StatusCode +func (r UserTOTPDeleteResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// ParseListLocalUsersResponse parses an HTTP response from a ListLocalUsersWithResponse call -func ParseListLocalUsersResponse(rsp *http.Response) (*ListLocalUsersResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +type UserTOTPSetupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Secret string `json:"secret"` + Url string `json:"url"` } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - response := &ListLocalUsersResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// Status returns HTTPResponse.Status +func (r UserTOTPSetupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []LocalUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r UserTOTPSetupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type UserTOTPVerifyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r UserTOTPVerifyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r UserTOTPVerifyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type ListUsersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []User `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r ListUsersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r ListUsersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type AddUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *User + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseAddLocalUserResponse parses an HTTP response from a AddLocalUserWithResponse call -func ParseAddLocalUserResponse(rsp *http.Response) (*AddLocalUserResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r AddUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &AddLocalUserResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r AddUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest LocalUser - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type DeleteUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r DeleteUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type GetUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *User + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r GetUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON405 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r GetUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type UpdateUserResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *User + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r UpdateUserResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateUserResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type DeleteUserTOTPResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON500 *InternalError } -// ParseDeleteLocalUserResponse parses an HTTP response from a DeleteLocalUserWithResponse call -func ParseDeleteLocalUserResponse(rsp *http.Response) (*DeleteLocalUserResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r DeleteUserTOTPResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &DeleteLocalUserResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteUserTOTPResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type CreateV2SyncDestinationTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncDestinationTestConnectionV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r CreateV2SyncDestinationTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r CreateV2SyncDestinationTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type GetV2SyncDestinationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncDestinationV2 `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r GetV2SyncDestinationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r GetV2SyncDestinationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type CreateV2SyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestinationV2 + JSON201 *SyncDestinationV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseGetLocalUserResponse parses an HTTP response from a GetLocalUserWithResponse call -func ParseGetLocalUserResponse(rsp *http.Response) (*GetLocalUserResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateV2SyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &GetLocalUserResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r CreateV2SyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest LocalUserWithTeams - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type DeleteV2SyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r DeleteV2SyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteV2SyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type GetV2SyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestinationV2 + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r GetV2SyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r GetV2SyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type PatchV2SyncDestinationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncDestination + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseUpdateLocalUserResponse parses an HTTP response from a UpdateLocalUserWithResponse call -func ParseUpdateLocalUserResponse(rsp *http.Response) (*UpdateLocalUserResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r PatchV2SyncDestinationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &UpdateLocalUserResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r PatchV2SyncDestinationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest LocalUser - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +type CreateV2SyncIntegrationTestConnectionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncIntegrationTestConnectionV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON429 *TooManyRequests + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// Status returns HTTPResponse.Status +func (r CreateV2SyncIntegrationTestConnectionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r CreateV2SyncIntegrationTestConnectionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +type ListV2SyncIntegrationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []SyncIntegrationExpandedV2 `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// Status returns HTTPResponse.Status +func (r ListV2SyncIntegrationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} +// StatusCode returns HTTPResponse.StatusCode +func (r ListV2SyncIntegrationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - return response, nil +type CreateV2SyncIntegrationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *SyncIntegrationV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError } -// ParseCreateLocalUserResetTokenResponse parses an HTTP response from a CreateLocalUserResetTokenWithResponse call -func ParseCreateLocalUserResetTokenResponse(rsp *http.Response) (*CreateLocalUserResetTokenResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err +// Status returns HTTPResponse.Status +func (r CreateV2SyncIntegrationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - response := &CreateLocalUserResetTokenResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// StatusCode returns HTTPResponse.StatusCode +func (r CreateV2SyncIntegrationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode } + return 0 +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - ResetToken string `json:"reset_token"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +type DeleteV2SyncIntegrationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON405 *MethodNotAllowed + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// Status returns HTTPResponse.Status +func (r DeleteV2SyncIntegrationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteV2SyncIntegrationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +type GetV2SyncIntegrationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncIntegrationExpandedV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// Status returns HTTPResponse.Status +func (r GetV2SyncIntegrationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// StatusCode returns HTTPResponse.StatusCode +func (r GetV2SyncIntegrationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +type UpdateV2SyncIntegrationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SyncIntegrationV2 + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} +// Status returns HTTPResponse.Status +func (r UpdateV2SyncIntegrationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status } + return http.StatusText(0) +} - return response, nil +// StatusCode returns HTTPResponse.StatusCode +func (r UpdateV2SyncIntegrationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 } -// ParseManageUserTOTPDeleteResponse parses an HTTP response from a ManageUserTOTPDeleteWithResponse call -func ParseManageUserTOTPDeleteResponse(rsp *http.Response) (*ManageUserTOTPDeleteResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// IndexWithResponse request returning *IndexResponse +func (c *ClientWithResponses) IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) { + rsp, err := c.Index(ctx, reqEditors...) if err != nil { return nil, err } + return ParseIndexResponse(rsp) +} - response := &ManageUserTOTPDeleteResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// ListAllAlertsWithResponse request returning *ListAllAlertsResponse +func (c *ClientWithResponses) ListAllAlertsWithResponse(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) { + rsp, err := c.ListAllAlerts(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListAllAlertsResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON405 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - +// TestUnsavedAlertWithBodyWithResponse request with arbitrary body returning *TestUnsavedAlertResponse +func (c *ClientWithResponses) TestUnsavedAlertWithBodyWithResponse(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) { + rsp, err := c.TestUnsavedAlertWithBody(ctx, params, contentType, body, reqEditors...) + if err != nil { + return nil, err } - - return response, nil + return ParseTestUnsavedAlertResponse(rsp) } -// ParseGetOpenAPIJSONResponse parses an HTTP response from a GetOpenAPIJSONWithResponse call -func ParseGetOpenAPIJSONResponse(rsp *http.Response) (*GetOpenAPIJSONResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) TestUnsavedAlertWithResponse(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) { + rsp, err := c.TestUnsavedAlert(ctx, params, body, reqEditors...) if err != nil { return nil, err } + return ParseTestUnsavedAlertResponse(rsp) +} - response := &GetOpenAPIJSONResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// ListAPIKeysWithResponse request returning *ListAPIKeysResponse +func (c *ClientWithResponses) ListAPIKeysWithResponse(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*ListAPIKeysResponse, error) { + rsp, err := c.ListAPIKeys(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListAPIKeysResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest map[string]interface{} - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - +// CreateAPIKeyWithBodyWithResponse request with arbitrary body returning *CreateAPIKeyResponse +func (c *ClientWithResponses) CreateAPIKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) { + rsp, err := c.CreateAPIKeyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } - - return response, nil + return ParseCreateAPIKeyResponse(rsp) } -// ParseGetPlatformInfoResponse parses an HTTP response from a GetPlatformInfoWithResponse call -func ParseGetPlatformInfoResponse(rsp *http.Response) (*GetPlatformInfoResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) CreateAPIKeyWithResponse(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) { + rsp, err := c.CreateAPIKey(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseCreateAPIKeyResponse(rsp) +} - response := &GetPlatformInfoResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// DeleteAPIKeyWithResponse request returning *DeleteAPIKeyResponse +func (c *ClientWithResponses) DeleteAPIKeyWithResponse(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteAPIKeyResponse, error) { + rsp, err := c.DeleteAPIKey(ctx, apiKeyID, reqEditors...) + if err != nil { + return nil, err } + return ParseDeleteAPIKeyResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - PublicIps *[]string `json:"public_ips,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ListAuditLogsWithResponse request returning *ListAuditLogsResponse +func (c *ClientWithResponses) ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) { + rsp, err := c.ListAuditLogs(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListAuditLogsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// GetAuditLogWithResponse request returning *GetAuditLogResponse +func (c *ClientWithResponses) GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) { + rsp, err := c.GetAuditLog(ctx, id, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAuditLogResponse(rsp) +} +// GetSAMLWithResponse request returning *GetSAMLResponse +func (c *ClientWithResponses) GetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSAMLResponse, error) { + rsp, err := c.GetSAML(ctx, reqEditors...) + if err != nil { + return nil, err } + return ParseGetSAMLResponse(rsp) +} - return response, nil +// UpdateSAMLWithBodyWithResponse request with arbitrary body returning *UpdateSAMLResponse +func (c *ClientWithResponses) UpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) { + rsp, err := c.UpdateSAMLWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSAMLResponse(rsp) } -// ParseListPlatformVersionsResponse parses an HTTP response from a ListPlatformVersionsWithResponse call -func ParseListPlatformVersionsResponse(rsp *http.Response) (*ListPlatformVersionsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) UpdateSAMLWithResponse(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) { + rsp, err := c.UpdateSAML(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateSAMLResponse(rsp) +} - response := &ListPlatformVersionsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// CreateConversationWithBodyWithResponse request with arbitrary body returning *CreateConversationResponse +func (c *ClientWithResponses) CreateConversationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) { + rsp, err := c.CreateConversationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateConversationResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []PlatformVersion `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) CreateConversationWithResponse(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) { + rsp, err := c.CreateConversation(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateConversationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetConversationWithResponse request returning *GetConversationResponse +func (c *ClientWithResponses) GetConversationWithResponse(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) { + rsp, err := c.GetConversation(ctx, conversationID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetConversationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// SendMessageWithBodyWithResponse request with arbitrary body returning *SendMessageResponse +func (c *ClientWithResponses) SendMessageWithBodyWithResponse(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) { + rsp, err := c.SendMessageWithBody(ctx, conversationID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseSendMessageResponse(rsp) +} +func (c *ClientWithResponses) SendMessageWithResponse(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) { + rsp, err := c.SendMessage(ctx, conversationID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseSendMessageResponse(rsp) +} - return response, nil +// ListAllCustomColumnsWithResponse request returning *ListAllCustomColumnsResponse +func (c *ClientWithResponses) ListAllCustomColumnsWithResponse(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) { + rsp, err := c.ListAllCustomColumns(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListAllCustomColumnsResponse(rsp) } -// ParseListPluginsResponse parses an HTTP response from a ListPluginsWithResponse call -func ParseListPluginsResponse(rsp *http.Response) (*ListPluginsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// SaveCustomColumnWithBodyWithResponse request with arbitrary body returning *SaveCustomColumnResponse +func (c *ClientWithResponses) SaveCustomColumnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) { + rsp, err := c.SaveCustomColumnWithBody(ctx, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseSaveCustomColumnResponse(rsp) +} - response := &ListPluginsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) SaveCustomColumnWithResponse(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) { + rsp, err := c.SaveCustomColumn(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseSaveCustomColumnResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items ListPlugins `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// DeleteCustomColumnWithResponse request returning *DeleteCustomColumnResponse +func (c *ClientWithResponses) DeleteCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) { + rsp, err := c.DeleteCustomColumn(ctx, customColumnID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteCustomColumnResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetCustomColumnWithResponse request returning *GetCustomColumnResponse +func (c *ClientWithResponses) GetCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) { + rsp, err := c.GetCustomColumn(ctx, customColumnID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCustomColumnResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// UpdateCustomColumnWithBodyWithResponse request with arbitrary body returning *UpdateCustomColumnResponse +func (c *ClientWithResponses) UpdateCustomColumnWithBodyWithResponse(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) { + rsp, err := c.UpdateCustomColumnWithBody(ctx, customColumnID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateCustomColumnResponse(rsp) +} +func (c *ClientWithResponses) UpdateCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) { + rsp, err := c.UpdateCustomColumn(ctx, customColumnID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateCustomColumnResponse(rsp) +} - return response, nil +// ListFiltersWithResponse request returning *ListFiltersResponse +func (c *ClientWithResponses) ListFiltersWithResponse(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*ListFiltersResponse, error) { + rsp, err := c.ListFilters(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListFiltersResponse(rsp) } -// ParseCreatePluginResponse parses an HTTP response from a CreatePluginWithResponse call -func ParseCreatePluginResponse(rsp *http.Response) (*CreatePluginResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// ListFilterTagsWithResponse request returning *ListFilterTagsResponse +func (c *ClientWithResponses) ListFilterTagsWithResponse(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*ListFilterTagsResponse, error) { + rsp, err := c.ListFilterTags(ctx, params, reqEditors...) if err != nil { return nil, err } + return ParseListFilterTagsResponse(rsp) +} - response := &CreatePluginResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// DeleteFilterWithResponse request returning *DeleteFilterResponse +func (c *ClientWithResponses) DeleteFilterWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterResponse, error) { + rsp, err := c.DeleteFilter(ctx, filterID, reqEditors...) + if err != nil { + return nil, err } + return ParseDeleteFilterResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Plugin - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +// GetFilterByIDWithResponse request returning *GetFilterByIDResponse +func (c *ClientWithResponses) GetFilterByIDWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDResponse, error) { + rsp, err := c.GetFilterByID(ctx, filterID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetFilterByIDResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// UpdateFilterWithBodyWithResponse request with arbitrary body returning *UpdateFilterResponse +func (c *ClientWithResponses) UpdateFilterWithBodyWithResponse(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) { + rsp, err := c.UpdateFilterWithBody(ctx, filterID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateFilterResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +func (c *ClientWithResponses) UpdateFilterWithResponse(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) { + rsp, err := c.UpdateFilter(ctx, filterID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateFilterResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// HealthCheckWithResponse request returning *HealthCheckResponse +func (c *ClientWithResponses) HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) { + rsp, err := c.HealthCheck(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseHealthCheckResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// HealthCheckHeadWithResponse request returning *HealthCheckHeadResponse +func (c *ClientWithResponses) HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) { + rsp, err := c.HealthCheckHead(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseHealthCheckHeadResponse(rsp) +} +// ListNotificationsWithResponse request returning *ListNotificationsResponse +func (c *ClientWithResponses) ListNotificationsWithResponse(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*ListNotificationsResponse, error) { + rsp, err := c.ListNotifications(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListNotificationsResponse(rsp) +} - return response, nil +// DeleteNotificationDestinationWithResponse request returning *DeleteNotificationDestinationResponse +func (c *ClientWithResponses) DeleteNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) { + rsp, err := c.DeleteNotificationDestination(ctx, notificationDestinationId, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteNotificationDestinationResponse(rsp) } -// ParseDeletePluginByTeamAndPluginNameResponse parses an HTTP response from a DeletePluginByTeamAndPluginNameWithResponse call -func ParseDeletePluginByTeamAndPluginNameResponse(rsp *http.Response) (*DeletePluginByTeamAndPluginNameResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// GetNotificationDestinationWithResponse request returning *GetNotificationDestinationResponse +func (c *ClientWithResponses) GetNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) { + rsp, err := c.GetNotificationDestination(ctx, notificationDestinationId, reqEditors...) if err != nil { return nil, err } + return ParseGetNotificationDestinationResponse(rsp) +} - response := &DeletePluginByTeamAndPluginNameResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// UpdateNotificationDestinationWithBodyWithResponse request with arbitrary body returning *UpdateNotificationDestinationResponse +func (c *ClientWithResponses) UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) { + rsp, err := c.UpdateNotificationDestinationWithBody(ctx, notificationDestinationId, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateNotificationDestinationResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +func (c *ClientWithResponses) UpdateNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) { + rsp, err := c.UpdateNotificationDestination(ctx, notificationDestinationId, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateNotificationDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetNotificationDestinationAlertsWithResponse request returning *GetNotificationDestinationAlertsResponse +func (c *ClientWithResponses) GetNotificationDestinationAlertsWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) { + rsp, err := c.GetNotificationDestinationAlerts(ctx, notificationDestinationId, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetNotificationDestinationAlertsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// TestNotificationDestinationWithResponse request returning *TestNotificationDestinationResponse +func (c *ClientWithResponses) TestNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) { + rsp, err := c.TestNotificationDestination(ctx, notificationDestinationId, reqEditors...) + if err != nil { + return nil, err + } + return ParseTestNotificationDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// ListAllNotificationDestinationsWithResponse request returning *ListAllNotificationDestinationsResponse +func (c *ClientWithResponses) ListAllNotificationDestinationsWithResponse(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) { + rsp, err := c.ListAllNotificationDestinations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListAllNotificationDestinationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// CreateNotificationDestinationWithBodyWithResponse request with arbitrary body returning *CreateNotificationDestinationResponse +func (c *ClientWithResponses) CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) { + rsp, err := c.CreateNotificationDestinationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateNotificationDestinationResponse(rsp) +} +func (c *ClientWithResponses) CreateNotificationDestinationWithResponse(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) { + rsp, err := c.CreateNotificationDestination(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateNotificationDestinationResponse(rsp) +} - return response, nil +// TestUnsavedNotificationDestinationWithBodyWithResponse request with arbitrary body returning *TestUnsavedNotificationDestinationResponse +func (c *ClientWithResponses) TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) { + rsp, err := c.TestUnsavedNotificationDestinationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseTestUnsavedNotificationDestinationResponse(rsp) } -// ParseGetPluginResponse parses an HTTP response from a GetPluginWithResponse call -func ParseGetPluginResponse(rsp *http.Response) (*GetPluginResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) TestUnsavedNotificationDestinationWithResponse(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) { + rsp, err := c.TestUnsavedNotificationDestination(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseTestUnsavedNotificationDestinationResponse(rsp) +} - response := &GetPluginResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// CreateAWSOnboardingWithBodyWithResponse request with arbitrary body returning *CreateAWSOnboardingResponse +func (c *ClientWithResponses) CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) { + rsp, err := c.CreateAWSOnboardingWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateAWSOnboardingResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ListPlugin - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) CreateAWSOnboardingWithResponse(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) { + rsp, err := c.CreateAWSOnboarding(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateAWSOnboardingResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetAWSOnboardingWithResponse request returning *GetAWSOnboardingResponse +func (c *ClientWithResponses) GetAWSOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) { + rsp, err := c.GetAWSOnboarding(ctx, onboardingID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAWSOnboardingResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetAWSAccountsInRootWithResponse request returning *GetAWSAccountsInRootResponse +func (c *ClientWithResponses) GetAWSAccountsInRootWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) { + rsp, err := c.GetAWSAccountsInRoot(ctx, onboardingID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAWSAccountsInRootResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ProvisionOnboardingConfigurationWithBodyWithResponse request with arbitrary body returning *ProvisionOnboardingConfigurationResponse +func (c *ClientWithResponses) ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) { + rsp, err := c.ProvisionOnboardingConfigurationWithBody(ctx, onboardingID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseProvisionOnboardingConfigurationResponse(rsp) +} +func (c *ClientWithResponses) ProvisionOnboardingConfigurationWithResponse(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) { + rsp, err := c.ProvisionOnboardingConfiguration(ctx, onboardingID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseProvisionOnboardingConfigurationResponse(rsp) +} - return response, nil +// GetAWSAccountsInParentWithResponse request returning *GetAWSAccountsInParentResponse +func (c *ClientWithResponses) GetAWSAccountsInParentWithResponse(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) { + rsp, err := c.GetAWSAccountsInParent(ctx, onboardingID, organizationalUnitID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAWSAccountsInParentResponse(rsp) } -// ParseUpdatePluginResponse parses an HTTP response from a UpdatePluginWithResponse call -func ParseUpdatePluginResponse(rsp *http.Response) (*UpdatePluginResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// NotifyOnboardingWithBodyWithResponse request with arbitrary body returning *NotifyOnboardingResponse +func (c *ClientWithResponses) NotifyOnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) { + rsp, err := c.NotifyOnboardingWithBody(ctx, onboardingID, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseNotifyOnboardingResponse(rsp) +} - response := &UpdatePluginResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) NotifyOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) { + rsp, err := c.NotifyOnboarding(ctx, onboardingID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseNotifyOnboardingResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Plugin - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// GetOpenAPIJSONWithResponse request returning *GetOpenAPIJSONResponse +func (c *ClientWithResponses) GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) { + rsp, err := c.GetOpenAPIJSON(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOpenAPIJSONResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// GetPlatformInfoWithResponse request returning *GetPlatformInfoResponse +func (c *ClientWithResponses) GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) { + rsp, err := c.GetPlatformInfo(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPlatformInfoResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// ListPlatformVersionsWithResponse request returning *ListPlatformVersionsResponse +func (c *ClientWithResponses) ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) { + rsp, err := c.ListPlatformVersions(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPlatformVersionsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// ListPluginsWithResponse request returning *ListPluginsResponse +func (c *ClientWithResponses) ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) { + rsp, err := c.ListPlugins(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPluginsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// GetPluginWithResponse request returning *GetPluginResponse +func (c *ClientWithResponses) GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) { + rsp, err := c.GetPlugin(ctx, teamName, pluginKind, pluginName, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPluginResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ListPluginVersionsWithResponse request returning *ListPluginVersionsResponse +func (c *ClientWithResponses) ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) { + rsp, err := c.ListPluginVersions(ctx, teamName, pluginKind, pluginName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPluginVersionsResponse(rsp) +} +// GetPluginVersionWithResponse request returning *GetPluginVersionResponse +func (c *ClientWithResponses) GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) { + rsp, err := c.GetPluginVersion(ctx, teamName, pluginKind, pluginName, versionName, reqEditors...) + if err != nil { + return nil, err } + return ParseGetPluginVersionResponse(rsp) +} - return response, nil +// DownloadPluginAssetWithResponse request returning *DownloadPluginAssetResponse +func (c *ClientWithResponses) DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) { + rsp, err := c.DownloadPluginAsset(ctx, teamName, pluginKind, pluginName, versionName, targetName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseDownloadPluginAssetResponse(rsp) } -// ParseListPluginVersionsResponse parses an HTTP response from a ListPluginVersionsWithResponse call -func ParseListPluginVersionsResponse(rsp *http.Response) (*ListPluginVersionsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// ListPluginVersionTablesWithResponse request returning *ListPluginVersionTablesResponse +func (c *ClientWithResponses) ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) { + rsp, err := c.ListPluginVersionTables(ctx, teamName, pluginKind, pluginName, versionName, params, reqEditors...) if err != nil { return nil, err } + return ParseListPluginVersionTablesResponse(rsp) +} - response := &ListPluginVersionsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// GetPluginVersionTableWithResponse request returning *GetPluginVersionTableResponse +func (c *ClientWithResponses) GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) { + rsp, err := c.GetPluginVersionTable(ctx, teamName, pluginKind, pluginName, versionName, tableName, reqEditors...) + if err != nil { + return nil, err } + return ParseGetPluginVersionTableResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []PluginVersionList `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// ListPoliciesWithResponse request returning *ListPoliciesResponse +func (c *ClientWithResponses) ListPoliciesWithResponse(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) { + rsp, err := c.ListPolicies(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPoliciesResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// CreatePolicyWithBodyWithResponse request with arbitrary body returning *CreatePolicyResponse +func (c *ClientWithResponses) CreatePolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) { + rsp, err := c.CreatePolicyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreatePolicyResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +func (c *ClientWithResponses) CreatePolicyWithResponse(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) { + rsp, err := c.CreatePolicy(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreatePolicyResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetPolicyMetricsWithResponse request returning *GetPolicyMetricsResponse +func (c *ClientWithResponses) GetPolicyMetricsWithResponse(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*GetPolicyMetricsResponse, error) { + rsp, err := c.GetPolicyMetrics(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPolicyMetricsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetViolationsByDomainWithResponse request returning *GetViolationsByDomainResponse +func (c *ClientWithResponses) GetViolationsByDomainWithResponse(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*GetViolationsByDomainResponse, error) { + rsp, err := c.GetViolationsByDomain(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetViolationsByDomainResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// GetViolationsHistoryWithResponse request returning *GetViolationsHistoryResponse +func (c *ClientWithResponses) GetViolationsHistoryWithResponse(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetViolationsHistoryResponse, error) { + rsp, err := c.GetViolationsHistory(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetViolationsHistoryResponse(rsp) +} +// DeletePolicyWithResponse request returning *DeletePolicyResponse +func (c *ClientWithResponses) DeletePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) { + rsp, err := c.DeletePolicy(ctx, policyID, reqEditors...) + if err != nil { + return nil, err } + return ParseDeletePolicyResponse(rsp) +} - return response, nil +// GetPolicyWithResponse request returning *GetPolicyResponse +func (c *ClientWithResponses) GetPolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) { + rsp, err := c.GetPolicy(ctx, policyID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPolicyResponse(rsp) } -// ParseGetPluginVersionResponse parses an HTTP response from a GetPluginVersionWithResponse call -func ParseGetPluginVersionResponse(rsp *http.Response) (*GetPluginVersionResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// UpdatePolicyWithBodyWithResponse request with arbitrary body returning *UpdatePolicyResponse +func (c *ClientWithResponses) UpdatePolicyWithBodyWithResponse(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) { + rsp, err := c.UpdatePolicyWithBody(ctx, policyID, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdatePolicyResponse(rsp) +} - response := &GetPluginVersionResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) UpdatePolicyWithResponse(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) { + rsp, err := c.UpdatePolicy(ctx, policyID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdatePolicyResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginVersionDetails - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// TogglePolicyWithResponse request returning *TogglePolicyResponse +func (c *ClientWithResponses) TogglePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) { + rsp, err := c.TogglePolicy(ctx, policyID, reqEditors...) + if err != nil { + return nil, err + } + return ParseTogglePolicyResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetPolicyViolationsWithResponse request returning *GetPolicyViolationsResponse +func (c *ClientWithResponses) GetPolicyViolationsWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsResponse, error) { + rsp, err := c.GetPolicyViolations(ctx, policyID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPolicyViolationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetPolicyViolationsHistoryWithResponse request returning *GetPolicyViolationsHistoryResponse +func (c *ClientWithResponses) GetPolicyViolationsHistoryWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) { + rsp, err := c.GetPolicyViolationsHistory(ctx, policyID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPolicyViolationsHistoryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// ListPolicyGroupsWithResponse request returning *ListPolicyGroupsResponse +func (c *ClientWithResponses) ListPolicyGroupsWithResponse(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*ListPolicyGroupsResponse, error) { + rsp, err := c.ListPolicyGroups(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPolicyGroupsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// CreatePolicyGroupWithBodyWithResponse request with arbitrary body returning *CreatePolicyGroupResponse +func (c *ClientWithResponses) CreatePolicyGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) { + rsp, err := c.CreatePolicyGroupWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreatePolicyGroupResponse(rsp) +} +func (c *ClientWithResponses) CreatePolicyGroupWithResponse(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) { + rsp, err := c.CreatePolicyGroup(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreatePolicyGroupResponse(rsp) +} - return response, nil +// DeletePolicyGroupWithResponse request returning *DeletePolicyGroupResponse +func (c *ClientWithResponses) DeletePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*DeletePolicyGroupResponse, error) { + rsp, err := c.DeletePolicyGroup(ctx, policyGroupID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeletePolicyGroupResponse(rsp) } -// ParseUpdatePluginVersionResponse parses an HTTP response from a UpdatePluginVersionWithResponse call -func ParseUpdatePluginVersionResponse(rsp *http.Response) (*UpdatePluginVersionResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// ListPoliciesInGroupWithResponse request returning *ListPoliciesInGroupResponse +func (c *ClientWithResponses) ListPoliciesInGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*ListPoliciesInGroupResponse, error) { + rsp, err := c.ListPoliciesInGroup(ctx, policyGroupID, params, reqEditors...) if err != nil { return nil, err } + return ParseListPoliciesInGroupResponse(rsp) +} - response := &UpdatePluginVersionResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// UpdatePolicyGroupWithBodyWithResponse request with arbitrary body returning *UpdatePolicyGroupResponse +func (c *ClientWithResponses) UpdatePolicyGroupWithBodyWithResponse(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) { + rsp, err := c.UpdatePolicyGroupWithBody(ctx, policyGroupID, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdatePolicyGroupResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginVersion - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) UpdatePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) { + rsp, err := c.UpdatePolicyGroup(ctx, policyGroupID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdatePolicyGroupResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// ListAllQueriesWithResponse request returning *ListAllQueriesResponse +func (c *ClientWithResponses) ListAllQueriesWithResponse(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*ListAllQueriesResponse, error) { + rsp, err := c.ListAllQueries(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListAllQueriesResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ExecuteAdHocQueryWithBodyWithResponse request with arbitrary body returning *ExecuteAdHocQueryResponse +func (c *ClientWithResponses) ExecuteAdHocQueryWithBodyWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) { + rsp, err := c.ExecuteAdHocQueryWithBody(ctx, params, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseExecuteAdHocQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +func (c *ClientWithResponses) ExecuteAdHocQueryWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) { + rsp, err := c.ExecuteAdHocQuery(ctx, params, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseExecuteAdHocQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// SaveQueryWithBodyWithResponse request with arbitrary body returning *SaveQueryResponse +func (c *ClientWithResponses) SaveQueryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) { + rsp, err := c.SaveQueryWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseSaveQueryResponse(rsp) +} +func (c *ClientWithResponses) SaveQueryWithResponse(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) { + rsp, err := c.SaveQuery(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseSaveQueryResponse(rsp) +} - return response, nil +// ListQueryTagsWithResponse request returning *ListQueryTagsResponse +func (c *ClientWithResponses) ListQueryTagsWithResponse(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*ListQueryTagsResponse, error) { + rsp, err := c.ListQueryTags(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListQueryTagsResponse(rsp) } -// ParseCreatePluginVersionResponse parses an HTTP response from a CreatePluginVersionWithResponse call -func ParseCreatePluginVersionResponse(rsp *http.Response) (*CreatePluginVersionResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// DeleteSavedQueryWithResponse request returning *DeleteSavedQueryResponse +func (c *ClientWithResponses) DeleteSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryResponse, error) { + rsp, err := c.DeleteSavedQuery(ctx, queryID, reqEditors...) if err != nil { return nil, err } + return ParseDeleteSavedQueryResponse(rsp) +} - response := &CreatePluginVersionResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// GetSavedQueryWithResponse request returning *GetSavedQueryResponse +func (c *ClientWithResponses) GetSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryResponse, error) { + rsp, err := c.GetSavedQuery(ctx, queryID, reqEditors...) + if err != nil { + return nil, err } + return ParseGetSavedQueryResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginVersion - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// UpdateQueryWithBodyWithResponse request with arbitrary body returning *UpdateQueryResponse +func (c *ClientWithResponses) UpdateQueryWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) { + rsp, err := c.UpdateQueryWithBody(ctx, queryID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest PluginVersion - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +func (c *ClientWithResponses) UpdateQueryWithResponse(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) { + rsp, err := c.UpdateQuery(ctx, queryID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// DeleteAlertWithResponse request returning *DeleteAlertResponse +func (c *ClientWithResponses) DeleteAlertWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) { + rsp, err := c.DeleteAlert(ctx, queryID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteAlertResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ExecuteSavedQueryWithResponse request returning *ExecuteSavedQueryResponse +func (c *ClientWithResponses) ExecuteSavedQueryWithResponse(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryResponse, error) { + rsp, err := c.ExecuteSavedQuery(ctx, queryID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseExecuteSavedQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// QueryListFiltersWithResponse request returning *QueryListFiltersResponse +func (c *ClientWithResponses) QueryListFiltersWithResponse(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*QueryListFiltersResponse, error) { + rsp, err := c.QueryListFilters(ctx, queryID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseQueryListFiltersResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// QuerySaveFilterWithBodyWithResponse request with arbitrary body returning *QuerySaveFilterResponse +func (c *ClientWithResponses) QuerySaveFilterWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) { + rsp, err := c.QuerySaveFilterWithBody(ctx, queryID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseQuerySaveFilterResponse(rsp) +} +func (c *ClientWithResponses) QuerySaveFilterWithResponse(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) { + rsp, err := c.QuerySaveFilter(ctx, queryID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseQuerySaveFilterResponse(rsp) +} - return response, nil +// QueryListFilterTagsWithResponse request returning *QueryListFilterTagsResponse +func (c *ClientWithResponses) QueryListFilterTagsWithResponse(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsResponse, error) { + rsp, err := c.QueryListFilterTags(ctx, queryID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseQueryListFilterTagsResponse(rsp) } -// ParseDownloadPluginAssetResponse parses an HTTP response from a DownloadPluginAssetWithResponse call -func ParseDownloadPluginAssetResponse(rsp *http.Response) (*DownloadPluginAssetResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// ListAllRBACPermissionsWithResponse request returning *ListAllRBACPermissionsResponse +func (c *ClientWithResponses) ListAllRBACPermissionsWithResponse(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) { + rsp, err := c.ListAllRBACPermissions(ctx, params, reqEditors...) if err != nil { return nil, err } + return ParseListAllRBACPermissionsResponse(rsp) +} - response := &DownloadPluginAssetResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// CreateRBACPermissionWithBodyWithResponse request with arbitrary body returning *CreateRBACPermissionResponse +func (c *ClientWithResponses) CreateRBACPermissionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) { + rsp, err := c.CreateRBACPermissionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateRBACPermissionResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginAsset - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) CreateRBACPermissionWithResponse(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) { + rsp, err := c.CreateRBACPermission(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateRBACPermissionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// DeleteRBACPermissionWithResponse request returning *DeleteRBACPermissionResponse +func (c *ClientWithResponses) DeleteRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) { + rsp, err := c.DeleteRBACPermission(ctx, rbacPermissionID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteRBACPermissionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetRBACPermissionWithResponse request returning *GetRBACPermissionResponse +func (c *ClientWithResponses) GetRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) { + rsp, err := c.GetRBACPermission(ctx, rbacPermissionID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetRBACPermissionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest +// UpdateRBACPermissionWithBodyWithResponse request with arbitrary body returning *UpdateRBACPermissionResponse +func (c *ClientWithResponses) UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) { + rsp, err := c.UpdateRBACPermissionWithBody(ctx, rbacPermissionID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateRBACPermissionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +func (c *ClientWithResponses) UpdateRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) { + rsp, err := c.UpdateRBACPermission(ctx, rbacPermissionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateRBACPermissionResponse(rsp) +} +// ListAllRBACRolesWithResponse request returning *ListAllRBACRolesResponse +func (c *ClientWithResponses) ListAllRBACRolesWithResponse(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) { + rsp, err := c.ListAllRBACRoles(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListAllRBACRolesResponse(rsp) +} - return response, nil +// CreateRBACRoleWithBodyWithResponse request with arbitrary body returning *CreateRBACRoleResponse +func (c *ClientWithResponses) CreateRBACRoleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) { + rsp, err := c.CreateRBACRoleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateRBACRoleResponse(rsp) } -// ParseUploadPluginAssetResponse parses an HTTP response from a UploadPluginAssetWithResponse call -func ParseUploadPluginAssetResponse(rsp *http.Response) (*UploadPluginAssetResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) CreateRBACRoleWithResponse(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) { + rsp, err := c.CreateRBACRole(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseCreateRBACRoleResponse(rsp) +} - response := &UploadPluginAssetResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// DeleteRBACRoleWithResponse request returning *DeleteRBACRoleResponse +func (c *ClientWithResponses) DeleteRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) { + rsp, err := c.DeleteRBACRole(ctx, roleID, reqEditors...) + if err != nil { + return nil, err } + return ParseDeleteRBACRoleResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest ReleaseURL - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +// GetRBACRoleWithResponse request returning *GetRBACRoleResponse +func (c *ClientWithResponses) GetRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) { + rsp, err := c.GetRBACRole(ctx, roleID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetRBACRoleResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// UpdateRBACRoleWithBodyWithResponse request with arbitrary body returning *UpdateRBACRoleResponse +func (c *ClientWithResponses) UpdateRBACRoleWithBodyWithResponse(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) { + rsp, err := c.UpdateRBACRoleWithBody(ctx, roleID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateRBACRoleResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +func (c *ClientWithResponses) UpdateRBACRoleWithResponse(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) { + rsp, err := c.UpdateRBACRole(ctx, roleID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateRBACRoleResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ListReportsWithResponse request returning *ListReportsResponse +func (c *ClientWithResponses) ListReportsWithResponse(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) { + rsp, err := c.ListReports(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListReportsResponse(rsp) +} +// CreateReportWithBodyWithResponse request with arbitrary body returning *CreateReportResponse +func (c *ClientWithResponses) CreateReportWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) { + rsp, err := c.CreateReportWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateReportResponse(rsp) +} - return response, nil +func (c *ClientWithResponses) CreateReportWithResponse(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) { + rsp, err := c.CreateReport(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateReportResponse(rsp) } -// ParseDeletePluginVersionDocsResponse parses an HTTP response from a DeletePluginVersionDocsWithResponse call -func ParseDeletePluginVersionDocsResponse(rsp *http.Response) (*DeletePluginVersionDocsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// ListReportTemplatesWithResponse request returning *ListReportTemplatesResponse +func (c *ClientWithResponses) ListReportTemplatesWithResponse(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) { + rsp, err := c.ListReportTemplates(ctx, params, reqEditors...) if err != nil { return nil, err } + return ParseListReportTemplatesResponse(rsp) +} - response := &DeletePluginVersionDocsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// CreateReportTemplateWithBodyWithResponse request with arbitrary body returning *CreateReportTemplateResponse +func (c *ClientWithResponses) CreateReportTemplateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) { + rsp, err := c.CreateReportTemplateWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateReportTemplateResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +func (c *ClientWithResponses) CreateReportTemplateWithResponse(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) { + rsp, err := c.CreateReportTemplate(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateReportTemplateResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// DeleteReportTemplateWithResponse request returning *DeleteReportTemplateResponse +func (c *ClientWithResponses) DeleteReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) { + rsp, err := c.DeleteReportTemplate(ctx, templateId, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteReportTemplateResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetReportTemplateWithResponse request returning *GetReportTemplateResponse +func (c *ClientWithResponses) GetReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) { + rsp, err := c.GetReportTemplate(ctx, templateId, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetReportTemplateResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// UpdateReportTemplateWithBodyWithResponse request with arbitrary body returning *UpdateReportTemplateResponse +func (c *ClientWithResponses) UpdateReportTemplateWithBodyWithResponse(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) { + rsp, err := c.UpdateReportTemplateWithBody(ctx, templateId, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateReportTemplateResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) UpdateReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) { + rsp, err := c.UpdateReportTemplate(ctx, templateId, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateReportTemplateResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// DeleteReportWithResponse request returning *DeleteReportResponse +func (c *ClientWithResponses) DeleteReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) { + rsp, err := c.DeleteReport(ctx, reportId, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteReportResponse(rsp) +} +// GetReportWithResponse request returning *GetReportResponse +func (c *ClientWithResponses) GetReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) { + rsp, err := c.GetReport(ctx, reportId, reqEditors...) + if err != nil { + return nil, err } - - return response, nil + return ParseGetReportResponse(rsp) } -// ParseListPluginVersionDocsResponse parses an HTTP response from a ListPluginVersionDocsWithResponse call -func ParseListPluginVersionDocsResponse(rsp *http.Response) (*ListPluginVersionDocsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// UpdateReportWithBodyWithResponse request with arbitrary body returning *UpdateReportResponse +func (c *ClientWithResponses) UpdateReportWithBodyWithResponse(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) { + rsp, err := c.UpdateReportWithBody(ctx, reportId, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateReportResponse(rsp) +} - response := &ListPluginVersionDocsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) UpdateReportWithResponse(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) { + rsp, err := c.UpdateReport(ctx, reportId, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateReportResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []PluginDocsPage `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetSettingsWithResponse request returning *GetSettingsResponse +func (c *ClientWithResponses) GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) { + rsp, err := c.GetSettings(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSettingsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// UpdateSettingsWithBodyWithResponse request with arbitrary body returning *UpdateSettingsResponse +func (c *ClientWithResponses) UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) { + rsp, err := c.UpdateSettingsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSettingsResponse(rsp) +} +func (c *ClientWithResponses) UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) { + rsp, err := c.UpdateSettings(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateSettingsResponse(rsp) +} - return response, nil +// GetDataSettingsWithResponse request returning *GetDataSettingsResponse +func (c *ClientWithResponses) GetDataSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataSettingsResponse, error) { + rsp, err := c.GetDataSettings(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDataSettingsResponse(rsp) } -// ParseReplacePluginVersionDocsResponse parses an HTTP response from a ReplacePluginVersionDocsWithResponse call -func ParseReplacePluginVersionDocsResponse(rsp *http.Response) (*ReplacePluginVersionDocsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// UpdateDataSettingsWithBodyWithResponse request with arbitrary body returning *UpdateDataSettingsResponse +func (c *ClientWithResponses) UpdateDataSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) { + rsp, err := c.UpdateDataSettingsWithBody(ctx, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateDataSettingsResponse(rsp) +} - response := &ReplacePluginVersionDocsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) UpdateDataSettingsWithResponse(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) { + rsp, err := c.UpdateDataSettings(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateDataSettingsResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Names *[]PluginDocsPageName `json:"names,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +// CreateSlackConnectionWithBodyWithResponse request with arbitrary body returning *CreateSlackConnectionResponse +func (c *ClientWithResponses) CreateSlackConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) { + rsp, err := c.CreateSlackConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSlackConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +func (c *ClientWithResponses) CreateSlackConnectionWithResponse(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) { + rsp, err := c.CreateSlackConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSlackConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ListSlackChannelsWithResponse request returning *ListSlackChannelsResponse +func (c *ClientWithResponses) ListSlackChannelsWithResponse(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*ListSlackChannelsResponse, error) { + rsp, err := c.ListSlackChannels(ctx, id, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSlackChannelsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// CreateSyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateSyncDestinationTestConnectionResponse +func (c *ClientWithResponses) CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateSyncDestinationTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +func (c *ClientWithResponses) CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateSyncDestinationTestConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// GetSyncDestinationTestConnectionWithResponse request returning *GetSyncDestinationTestConnectionResponse +func (c *ClientWithResponses) GetSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) { + rsp, err := c.GetSyncDestinationTestConnection(ctx, syncDestinationTestConnectionID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncDestinationResponse +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncDestinationWithBody(ctx, syncDestinationTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp) +} +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncDestination(ctx, syncDestinationTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp) +} - return response, nil +// GetSyncDestinationTestConnectionLogsLiveWithResponse request returning *GetSyncDestinationTestConnectionLogsLiveResponse +func (c *ClientWithResponses) GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) { + rsp, err := c.GetSyncDestinationTestConnectionLogsLive(ctx, syncDestinationTestConnectionID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp) } -// ParseCreatePluginVersionDocsResponse parses an HTTP response from a CreatePluginVersionDocsWithResponse call -func ParseCreatePluginVersionDocsResponse(rsp *http.Response) (*CreatePluginVersionDocsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// GetSyncDestinationTestConnectionLogsQueryWithResponse request returning *GetSyncDestinationTestConnectionLogsQueryResponse +func (c *ClientWithResponses) GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) { + rsp, err := c.GetSyncDestinationTestConnectionLogsQuery(ctx, syncDestinationTestConnectionID, params, reqEditors...) if err != nil { return nil, err } + return ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp) +} - response := &CreatePluginVersionDocsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// PromoteSyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *PromoteSyncDestinationTestConnectionResponse +func (c *ClientWithResponses) PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) { + rsp, err := c.PromoteSyncDestinationTestConnectionWithBody(ctx, syncDestinationTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParsePromoteSyncDestinationTestConnectionResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Names *[]PluginDocsPageName `json:"names,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +func (c *ClientWithResponses) PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) { + rsp, err := c.PromoteSyncDestinationTestConnection(ctx, syncDestinationTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePromoteSyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// ListSyncDestinationsWithResponse request returning *ListSyncDestinationsResponse +func (c *ClientWithResponses) ListSyncDestinationsWithResponse(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) { + rsp, err := c.ListSyncDestinations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncDestinationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// DeleteSyncDestinationWithResponse request returning *DeleteSyncDestinationResponse +func (c *ClientWithResponses) DeleteSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) { + rsp, err := c.DeleteSyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetSyncDestinationWithResponse request returning *GetSyncDestinationResponse +func (c *ClientWithResponses) GetSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) { + rsp, err := c.GetSyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// UpdateSyncDestinationWithBodyWithResponse request with arbitrary body returning *UpdateSyncDestinationResponse +func (c *ClientWithResponses) UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) { + rsp, err := c.UpdateSyncDestinationWithBody(ctx, syncDestinationName, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) UpdateSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) { + rsp, err := c.UpdateSyncDestination(ctx, syncDestinationName, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ListSyncDestinationSyncsWithResponse request returning *ListSyncDestinationSyncsResponse +func (c *ClientWithResponses) ListSyncDestinationSyncsWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) { + rsp, err := c.ListSyncDestinationSyncs(ctx, syncDestinationName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncDestinationSyncsResponse(rsp) +} +// GetTestConnectionForSyncDestinationWithResponse request returning *GetTestConnectionForSyncDestinationResponse +func (c *ClientWithResponses) GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) { + rsp, err := c.GetTestConnectionForSyncDestination(ctx, syncDestinationName, syncTestConnectionId, reqEditors...) + if err != nil { + return nil, err } + return ParseGetTestConnectionForSyncDestinationResponse(rsp) +} - return response, nil +// CreateSyncSourceTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateSyncSourceTestConnectionResponse +func (c *ClientWithResponses) CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) { + rsp, err := c.CreateSyncSourceTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncSourceTestConnectionResponse(rsp) } -// ParseDeletePluginVersionTablesResponse parses an HTTP response from a DeletePluginVersionTablesWithResponse call -func ParseDeletePluginVersionTablesResponse(rsp *http.Response) (*DeletePluginVersionTablesResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) CreateSyncSourceTestConnectionWithResponse(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) { + rsp, err := c.CreateSyncSourceTestConnection(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseCreateSyncSourceTestConnectionResponse(rsp) +} - response := &DeletePluginVersionTablesResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// GetSyncSourceTestConnectionWithResponse request returning *GetSyncSourceTestConnectionResponse +func (c *ClientWithResponses) GetSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) { + rsp, err := c.GetSyncSourceTestConnection(ctx, syncSourceTestConnectionID, reqEditors...) + if err != nil { + return nil, err } + return ParseGetSyncSourceTestConnectionResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncSourceResponse +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncSourceWithBody(ctx, syncSourceTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncSource(ctx, syncSourceTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetSyncSourceTestConnectionLogsLiveWithResponse request returning *GetSyncSourceTestConnectionLogsLiveResponse +func (c *ClientWithResponses) GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) { + rsp, err := c.GetSyncSourceTestConnectionLogsLive(ctx, syncSourceTestConnectionID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncSourceTestConnectionLogsLiveResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetSyncSourceTestConnectionLogsQueryWithResponse request returning *GetSyncSourceTestConnectionLogsQueryResponse +func (c *ClientWithResponses) GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) { + rsp, err := c.GetSyncSourceTestConnectionLogsQuery(ctx, syncSourceTestConnectionID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncSourceTestConnectionLogsQueryResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// PromoteSyncSourceTestConnectionWithBodyWithResponse request with arbitrary body returning *PromoteSyncSourceTestConnectionResponse +func (c *ClientWithResponses) PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) { + rsp, err := c.PromoteSyncSourceTestConnectionWithBody(ctx, syncSourceTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePromoteSyncSourceTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +func (c *ClientWithResponses) PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) { + rsp, err := c.PromoteSyncSourceTestConnection(ctx, syncSourceTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePromoteSyncSourceTestConnectionResponse(rsp) +} +// ListSyncSourcesWithResponse request returning *ListSyncSourcesResponse +func (c *ClientWithResponses) ListSyncSourcesWithResponse(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) { + rsp, err := c.ListSyncSources(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListSyncSourcesResponse(rsp) +} - return response, nil +// DeleteSyncSourceWithResponse request returning *DeleteSyncSourceResponse +func (c *ClientWithResponses) DeleteSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) { + rsp, err := c.DeleteSyncSource(ctx, syncSourceName, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSyncSourceResponse(rsp) } -// ParseListPluginVersionTablesResponse parses an HTTP response from a ListPluginVersionTablesWithResponse call -func ParseListPluginVersionTablesResponse(rsp *http.Response) (*ListPluginVersionTablesResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// GetSyncSourceWithResponse request returning *GetSyncSourceResponse +func (c *ClientWithResponses) GetSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) { + rsp, err := c.GetSyncSource(ctx, syncSourceName, reqEditors...) if err != nil { return nil, err } + return ParseGetSyncSourceResponse(rsp) +} - response := &ListPluginVersionTablesResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// UpdateSyncSourceWithBodyWithResponse request with arbitrary body returning *UpdateSyncSourceResponse +func (c *ClientWithResponses) UpdateSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) { + rsp, err := c.UpdateSyncSourceWithBody(ctx, syncSourceName, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateSyncSourceResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []PluginTable `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) UpdateSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) { + rsp, err := c.UpdateSyncSource(ctx, syncSourceName, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncSourceResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ListSyncSourceSyncsWithResponse request returning *ListSyncSourceSyncsResponse +func (c *ClientWithResponses) ListSyncSourceSyncsWithResponse(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) { + rsp, err := c.ListSyncSourceSyncs(ctx, syncSourceName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncSourceSyncsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// GetTestConnectionForSyncSourceWithResponse request returning *GetTestConnectionForSyncSourceResponse +func (c *ClientWithResponses) GetTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) { + rsp, err := c.GetTestConnectionForSyncSource(ctx, syncSourceName, syncTestConnectionId, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTestConnectionForSyncSourceResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ListSyncTransformersWithResponse request returning *ListSyncTransformersResponse +func (c *ClientWithResponses) ListSyncTransformersWithResponse(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) { + rsp, err := c.ListSyncTransformers(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncTransformersResponse(rsp) +} +// DeleteSyncTransformerWithResponse request returning *DeleteSyncTransformerResponse +func (c *ClientWithResponses) DeleteSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) { + rsp, err := c.DeleteSyncTransformer(ctx, syncTransformerName, reqEditors...) + if err != nil { + return nil, err } + return ParseDeleteSyncTransformerResponse(rsp) +} - return response, nil +// GetSyncTransformerWithResponse request returning *GetSyncTransformerResponse +func (c *ClientWithResponses) GetSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) { + rsp, err := c.GetSyncTransformer(ctx, syncTransformerName, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncTransformerResponse(rsp) } -// ParseCreatePluginVersionTablesResponse parses an HTTP response from a CreatePluginVersionTablesWithResponse call -func ParseCreatePluginVersionTablesResponse(rsp *http.Response) (*CreatePluginVersionTablesResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// UpdateSyncTransformerWithBodyWithResponse request with arbitrary body returning *UpdateSyncTransformerResponse +func (c *ClientWithResponses) UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) { + rsp, err := c.UpdateSyncTransformerWithBody(ctx, syncTransformerName, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateSyncTransformerResponse(rsp) +} - response := &CreatePluginVersionTablesResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) UpdateSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) { + rsp, err := c.UpdateSyncTransformer(ctx, syncTransformerName, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateSyncTransformerResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Names *[]PluginTableName `json:"names,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +// ListSyncTransformerSyncDestinationsWithResponse request returning *ListSyncTransformerSyncDestinationsResponse +func (c *ClientWithResponses) ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) { + rsp, err := c.ListSyncTransformerSyncDestinations(ctx, syncTransformerName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncTransformerSyncDestinationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// ListSyncTransformerSyncsWithResponse request returning *ListSyncTransformerSyncsResponse +func (c *ClientWithResponses) ListSyncTransformerSyncsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) { + rsp, err := c.ListSyncTransformerSyncs(ctx, syncTransformerName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncTransformerSyncsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ListSyncUpgradesWithResponse request returning *ListSyncUpgradesResponse +func (c *ClientWithResponses) ListSyncUpgradesWithResponse(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) { + rsp, err := c.ListSyncUpgrades(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncUpgradesResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// ListSyncsWithResponse request returning *ListSyncsResponse +func (c *ClientWithResponses) ListSyncsWithResponse(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) { + rsp, err := c.ListSyncs(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListSyncsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// CreateSyncWithBodyWithResponse request with arbitrary body returning *CreateSyncResponse +func (c *ClientWithResponses) CreateSyncWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) { + rsp, err := c.CreateSyncWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) CreateSyncWithResponse(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) { + rsp, err := c.CreateSync(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// DeleteSyncWithResponse request returning *DeleteSyncResponse +func (c *ClientWithResponses) DeleteSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) { + rsp, err := c.DeleteSync(ctx, syncName, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSyncResponse(rsp) +} +// GetSyncWithResponse request returning *GetSyncResponse +func (c *ClientWithResponses) GetSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) { + rsp, err := c.GetSync(ctx, syncName, reqEditors...) + if err != nil { + return nil, err } + return ParseGetSyncResponse(rsp) +} - return response, nil +// UpdateSyncWithBodyWithResponse request with arbitrary body returning *UpdateSyncResponse +func (c *ClientWithResponses) UpdateSyncWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) { + rsp, err := c.UpdateSyncWithBody(ctx, syncName, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncResponse(rsp) } -// ParseGetPluginVersionTableResponse parses an HTTP response from a GetPluginVersionTableWithResponse call -func ParseGetPluginVersionTableResponse(rsp *http.Response) (*GetPluginVersionTableResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) UpdateSyncWithResponse(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) { + rsp, err := c.UpdateSync(ctx, syncName, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateSyncResponse(rsp) +} - response := &GetPluginVersionTableResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// ListSyncRunsWithResponse request returning *ListSyncRunsResponse +func (c *ClientWithResponses) ListSyncRunsWithResponse(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) { + rsp, err := c.ListSyncRuns(ctx, syncName, params, reqEditors...) + if err != nil { + return nil, err } + return ParseListSyncRunsResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginTableDetails - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +// CreateSyncRunWithResponse request returning *CreateSyncRunResponse +func (c *ClientWithResponses) CreateSyncRunWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) { + rsp, err := c.CreateSyncRun(ctx, syncName, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncRunResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetSyncRunWithResponse request returning *GetSyncRunResponse +func (c *ClientWithResponses) GetSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) { + rsp, err := c.GetSyncRun(ctx, syncName, syncRunId, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncRunResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// UpdateSyncRunWithBodyWithResponse request with arbitrary body returning *UpdateSyncRunResponse +func (c *ClientWithResponses) UpdateSyncRunWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) { + rsp, err := c.UpdateSyncRunWithBody(ctx, syncName, syncRunId, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncRunResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +func (c *ClientWithResponses) UpdateSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) { + rsp, err := c.UpdateSyncRun(ctx, syncName, syncRunId, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncRunResponse(rsp) +} +// GetSyncRunLogsLiveWithResponse request returning *GetSyncRunLogsLiveResponse +func (c *ClientWithResponses) GetSyncRunLogsLiveWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) { + rsp, err := c.GetSyncRunLogsLive(ctx, syncName, syncRunId, params, reqEditors...) + if err != nil { + return nil, err } + return ParseGetSyncRunLogsLiveResponse(rsp) +} - return response, nil +// GetSyncRunLogsQueryWithResponse request returning *GetSyncRunLogsQueryResponse +func (c *ClientWithResponses) GetSyncRunLogsQueryWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) { + rsp, err := c.GetSyncRunLogsQuery(ctx, syncName, syncRunId, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncRunLogsQueryResponse(rsp) } -// ParseRemovePluginUIAssetsResponse parses an HTTP response from a RemovePluginUIAssetsWithResponse call -func ParseRemovePluginUIAssetsResponse(rsp *http.Response) (*RemovePluginUIAssetsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// CreateSyncRunProgressWithBodyWithResponse request with arbitrary body returning *CreateSyncRunProgressResponse +func (c *ClientWithResponses) CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) { + rsp, err := c.CreateSyncRunProgressWithBody(ctx, syncName, syncRunId, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseCreateSyncRunProgressResponse(rsp) +} - response := &RemovePluginUIAssetsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) CreateSyncRunProgressWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) { + rsp, err := c.CreateSyncRunProgress(ctx, syncName, syncRunId, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateSyncRunProgressResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// GetSyncRunStatsWithResponse request returning *GetSyncRunStatsResponse +func (c *ClientWithResponses) GetSyncRunStatsWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) { + rsp, err := c.GetSyncRunStats(ctx, syncName, syncRunId, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncRunStatsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// GetSyncRunTablesWithResponse request returning *GetSyncRunTablesResponse +func (c *ClientWithResponses) GetSyncRunTablesWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) { + rsp, err := c.GetSyncRunTables(ctx, syncName, syncRunId, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSyncRunTablesResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// ListTablesWithResponse request returning *ListTablesResponse +func (c *ClientWithResponses) ListTablesWithResponse(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*ListTablesResponse, error) { + rsp, err := c.ListTables(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListTablesResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// GetTablesDataWithResponse request returning *GetTablesDataResponse +func (c *ClientWithResponses) GetTablesDataWithResponse(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*GetTablesDataResponse, error) { + rsp, err := c.GetTablesData(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTablesDataResponse(rsp) +} +// TablesDataActionWithBodyWithResponse request with arbitrary body returning *TablesDataActionResponse +func (c *ClientWithResponses) TablesDataActionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) { + rsp, err := c.TablesDataActionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseTablesDataActionResponse(rsp) +} - return response, nil +func (c *ClientWithResponses) TablesDataActionWithResponse(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) { + rsp, err := c.TablesDataAction(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseTablesDataActionResponse(rsp) } -// ParseUploadPluginUIAssetsResponse parses an HTTP response from a UploadPluginUIAssetsWithResponse call -func ParseUploadPluginUIAssetsResponse(rsp *http.Response) (*UploadPluginUIAssetsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// BatchTableSchemasWithResponse request returning *BatchTableSchemasResponse +func (c *ClientWithResponses) BatchTableSchemasWithResponse(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasResponse, error) { + rsp, err := c.BatchTableSchemas(ctx, params, reqEditors...) if err != nil { return nil, err } + return ParseBatchTableSchemasResponse(rsp) +} - response := &UploadPluginUIAssetsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// TableListColumnsWithResponse request returning *TableListColumnsResponse +func (c *ClientWithResponses) TableListColumnsWithResponse(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*TableListColumnsResponse, error) { + rsp, err := c.TableListColumns(ctx, tableName, params, reqEditors...) + if err != nil { + return nil, err } + return ParseTableListColumnsResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Assets []PluginUIAsset `json:"assets"` +// TableColumnListValuesWithResponse request returning *TableColumnListValuesResponse +func (c *ClientWithResponses) TableColumnListValuesWithResponse(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesResponse, error) { + rsp, err := c.TableColumnListValues(ctx, tableName, columnName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableColumnListValuesResponse(rsp) +} - // UIID ID representing this upload - UIID string `json:"ui_id"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest +// TableListRowsWithResponse request returning *TableListRowsResponse +func (c *ClientWithResponses) TableListRowsWithResponse(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*TableListRowsResponse, error) { + rsp, err := c.TableListRows(ctx, tableName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableListRowsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// TableRowByIdWithResponse request returning *TableRowByIdResponse +func (c *ClientWithResponses) TableRowByIdWithResponse(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*TableRowByIdResponse, error) { + rsp, err := c.TableRowById(ctx, tableName, tableRowId, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableRowByIdResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// TableListFiltersWithResponse request returning *TableListFiltersResponse +func (c *ClientWithResponses) TableListFiltersWithResponse(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*TableListFiltersResponse, error) { + rsp, err := c.TableListFilters(ctx, tableName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableListFiltersResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// TableSaveFilterWithBodyWithResponse request with arbitrary body returning *TableSaveFilterResponse +func (c *ClientWithResponses) TableSaveFilterWithBodyWithResponse(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) { + rsp, err := c.TableSaveFilterWithBody(ctx, tableName, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableSaveFilterResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: - var dest Conflict - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON409 = &dest +func (c *ClientWithResponses) TableSaveFilterWithResponse(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) { + rsp, err := c.TableSaveFilter(ctx, tableName, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableSaveFilterResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// TableListFilterTagsWithResponse request returning *TableListFilterTagsResponse +func (c *ClientWithResponses) TableListFilterTagsWithResponse(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsResponse, error) { + rsp, err := c.TableListFilterTags(ctx, tableName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseTableListFilterTagsResponse(rsp) +} +// TableSchemaWithResponse request returning *TableSchemaResponse +func (c *ClientWithResponses) TableSchemaWithResponse(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaResponse, error) { + rsp, err := c.TableSchema(ctx, tableName, reqEditors...) + if err != nil { + return nil, err } + return ParseTableSchemaResponse(rsp) +} - return response, nil +// ListTeamsWithResponse request returning *ListTeamsResponse +func (c *ClientWithResponses) ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) { + rsp, err := c.ListTeams(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListTeamsResponse(rsp) } -// ParseFinalizePluginUIAssetUploadResponse parses an HTTP response from a FinalizePluginUIAssetUploadWithResponse call -func ParseFinalizePluginUIAssetUploadResponse(rsp *http.Response) (*FinalizePluginUIAssetUploadResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// DownloadPluginAssetByTeamWithResponse request returning *DownloadPluginAssetByTeamResponse +func (c *ClientWithResponses) DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) { + rsp, err := c.DownloadPluginAssetByTeam(ctx, teamName, pluginTeam, pluginKind, pluginName, versionName, targetName, params, reqEditors...) if err != nil { return nil, err } + return ParseDownloadPluginAssetByTeamResponse(rsp) +} - response := &FinalizePluginUIAssetUploadResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncDestinationTeamResponse +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncDestinationTeamWithBody(ctx, teamName, syncDestinationTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateSyncTestConnectionForSyncDestinationTeamResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncDestinationTeamWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncDestinationTeam(ctx, teamName, syncDestinationTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncDestinationTeamResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse request with arbitrary body returning *UpdateSyncTestConnectionForSyncSourceTeamResponse +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncSourceTeamWithBody(ctx, teamName, syncSourceTestConnectionID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncSourceTeamResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +func (c *ClientWithResponses) UpdateSyncTestConnectionForSyncSourceTeamWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) { + rsp, err := c.UpdateSyncTestConnectionForSyncSourceTeam(ctx, teamName, syncSourceTestConnectionID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateSyncTestConnectionForSyncSourceTeamResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +// CreateSyncRunProgressTeamWithBodyWithResponse request with arbitrary body returning *CreateSyncRunProgressTeamResponse +func (c *ClientWithResponses) CreateSyncRunProgressTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) { + rsp, err := c.CreateSyncRunProgressTeamWithBody(ctx, teamName, syncName, syncRunId, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncRunProgressTeamResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +func (c *ClientWithResponses) CreateSyncRunProgressTeamWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) { + rsp, err := c.CreateSyncRunProgressTeam(ctx, teamName, syncName, syncRunId, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSyncRunProgressTeamResponse(rsp) +} +// GetTeamUsageSummaryWithResponse request returning *GetTeamUsageSummaryResponse +func (c *ClientWithResponses) GetTeamUsageSummaryWithResponse(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) { + rsp, err := c.GetTeamUsageSummary(ctx, params, reqEditors...) + if err != nil { + return nil, err } + return ParseGetTeamUsageSummaryResponse(rsp) +} - return response, nil +// GetGroupedTeamUsageSummaryWithResponse request returning *GetGroupedTeamUsageSummaryResponse +func (c *ClientWithResponses) GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) { + rsp, err := c.GetGroupedTeamUsageSummary(ctx, groupBy, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetGroupedTeamUsageSummaryResponse(rsp) } -// ParseAuthRegistryRequestResponse parses an HTTP response from a AuthRegistryRequestWithResponse call -func ParseAuthRegistryRequestResponse(rsp *http.Response) (*AuthRegistryRequestResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// GetCurrentUserWithResponse request returning *GetCurrentUserResponse +func (c *ClientWithResponses) GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) { + rsp, err := c.GetCurrentUser(ctx, reqEditors...) if err != nil { return nil, err } + return ParseGetCurrentUserResponse(rsp) +} - response := &AuthRegistryRequestResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// UpdateCurrentUserWithBodyWithResponse request with arbitrary body returning *UpdateCurrentUserResponse +func (c *ClientWithResponses) UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) { + rsp, err := c.UpdateCurrentUserWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateCurrentUserResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest RegistryAuthToken - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) { + rsp, err := c.UpdateCurrentUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateCurrentUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest DockerError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// SendAnonymousEventWithBodyWithResponse request with arbitrary body returning *SendAnonymousEventResponse +func (c *ClientWithResponses) SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) { + rsp, err := c.SendAnonymousEventWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseSendAnonymousEventResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest DockerError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +func (c *ClientWithResponses) SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) { + rsp, err := c.SendAnonymousEvent(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseSendAnonymousEventResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest DockerError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// AuthenticateUserWithBodyWithResponse request with arbitrary body returning *AuthenticateUserResponse +func (c *ClientWithResponses) AuthenticateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) { + rsp, err := c.AuthenticateUserWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAuthenticateUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest DockerError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) AuthenticateUserWithResponse(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) { + rsp, err := c.AuthenticateUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAuthenticateUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest DockerError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// ChangeUserPasswordWithBodyWithResponse request with arbitrary body returning *ChangeUserPasswordResponse +func (c *ClientWithResponses) ChangeUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) { + rsp, err := c.ChangeUserPasswordWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseChangeUserPasswordResponse(rsp) +} +func (c *ClientWithResponses) ChangeUserPasswordWithResponse(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) { + rsp, err := c.ChangeUserPassword(ctx, body, reqEditors...) + if err != nil { + return nil, err } + return ParseChangeUserPasswordResponse(rsp) +} - return response, nil +// UpdateCustomerWithBodyWithResponse request with arbitrary body returning *UpdateCustomerResponse +func (c *ClientWithResponses) UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) { + rsp, err := c.UpdateCustomerWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateCustomerResponse(rsp) } -// ParseListTeamsResponse parses an HTTP response from a ListTeamsWithResponse call -func ParseListTeamsResponse(rsp *http.Response) (*ListTeamsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) { + rsp, err := c.UpdateCustomer(ctx, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateCustomerResponse(rsp) +} - response := &ListTeamsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// SendUserEventWithBodyWithResponse request with arbitrary body returning *SendUserEventResponse +func (c *ClientWithResponses) SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) { + rsp, err := c.SendUserEventWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseSendUserEventResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Team `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) { + rsp, err := c.SendUserEvent(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseSendUserEventResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// LogoutUserWithResponse request returning *LogoutUserResponse +func (c *ClientWithResponses) LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) { + rsp, err := c.LogoutUser(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseLogoutUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// LoginUserWithBodyWithResponse request with arbitrary body returning *LoginUserResponse +func (c *ClientWithResponses) LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { + rsp, err := c.LoginUserWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseLoginUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { + rsp, err := c.LoginUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseLoginUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// UserTOTPDeleteWithResponse request returning *UserTOTPDeleteResponse +func (c *ClientWithResponses) UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) { + rsp, err := c.UserTOTPDelete(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseUserTOTPDeleteResponse(rsp) +} +// UserTOTPSetupWithResponse request returning *UserTOTPSetupResponse +func (c *ClientWithResponses) UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) { + rsp, err := c.UserTOTPSetup(ctx, reqEditors...) + if err != nil { + return nil, err } - - return response, nil + return ParseUserTOTPSetupResponse(rsp) } -// ParseCreateTeamResponse parses an HTTP response from a CreateTeamWithResponse call -func ParseCreateTeamResponse(rsp *http.Response) (*CreateTeamResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +// UserTOTPVerifyWithBodyWithResponse request with arbitrary body returning *UserTOTPVerifyResponse +func (c *ClientWithResponses) UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { + rsp, err := c.UserTOTPVerifyWithBody(ctx, params, contentType, body, reqEditors...) if err != nil { return nil, err } + return ParseUserTOTPVerifyResponse(rsp) +} - response := &CreateTeamResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +func (c *ClientWithResponses) UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { + rsp, err := c.UserTOTPVerify(ctx, params, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUserTOTPVerifyResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Team - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// ListUsersWithResponse request returning *ListUsersResponse +func (c *ClientWithResponses) ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) { + rsp, err := c.ListUsers(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListUsersResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// AddUserWithBodyWithResponse request with arbitrary body returning *AddUserResponse +func (c *ClientWithResponses) AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { + rsp, err := c.AddUserWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAddUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { + rsp, err := c.AddUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAddUserResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// DeleteUserWithResponse request returning *DeleteUserResponse +func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) { + rsp, err := c.DeleteUser(ctx, userID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteUserResponse(rsp) +} +// GetUserWithResponse request returning *GetUserResponse +func (c *ClientWithResponses) GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) { + rsp, err := c.GetUser(ctx, userID, reqEditors...) + if err != nil { + return nil, err } + return ParseGetUserResponse(rsp) +} - return response, nil +// UpdateUserWithBodyWithResponse request with arbitrary body returning *UpdateUserResponse +func (c *ClientWithResponses) UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { + rsp, err := c.UpdateUserWithBody(ctx, userID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateUserResponse(rsp) } -// ParseDeleteTeamResponse parses an HTTP response from a DeleteTeamWithResponse call -func ParseDeleteTeamResponse(rsp *http.Response) (*DeleteTeamResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { + rsp, err := c.UpdateUser(ctx, userID, body, reqEditors...) if err != nil { return nil, err } + return ParseUpdateUserResponse(rsp) +} - response := &DeleteTeamResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// DeleteUserTOTPWithResponse request returning *DeleteUserTOTPResponse +func (c *ClientWithResponses) DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) { + rsp, err := c.DeleteUserTOTP(ctx, userID, reqEditors...) + if err != nil { + return nil, err } + return ParseDeleteUserTOTPResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationTestConnectionResponse +func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncDestinationTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncDestinationTestConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +// GetV2SyncDestinationsWithResponse request returning *GetV2SyncDestinationsResponse +func (c *ClientWithResponses) GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) { + rsp, err := c.GetV2SyncDestinations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetV2SyncDestinationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// CreateV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationResponse +func (c *ClientWithResponses) CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { + rsp, err := c.CreateV2SyncDestinationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest +func (c *ClientWithResponses) CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { + rsp, err := c.CreateV2SyncDestination(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// DeleteV2SyncDestinationWithResponse request returning *DeleteV2SyncDestinationResponse +func (c *ClientWithResponses) DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) { + rsp, err := c.DeleteV2SyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteV2SyncDestinationResponse(rsp) +} +// GetV2SyncDestinationWithResponse request returning *GetV2SyncDestinationResponse +func (c *ClientWithResponses) GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) { + rsp, err := c.GetV2SyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err } + return ParseGetV2SyncDestinationResponse(rsp) +} - return response, nil +// PatchV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *PatchV2SyncDestinationResponse +func (c *ClientWithResponses) PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { + rsp, err := c.PatchV2SyncDestinationWithBody(ctx, syncDestinationName, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchV2SyncDestinationResponse(rsp) } -// ParseGetTeamByNameResponse parses an HTTP response from a GetTeamByNameWithResponse call -func ParseGetTeamByNameResponse(rsp *http.Response) (*GetTeamByNameResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() +func (c *ClientWithResponses) PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { + rsp, err := c.PatchV2SyncDestination(ctx, syncDestinationName, body, reqEditors...) if err != nil { return nil, err } + return ParsePatchV2SyncDestinationResponse(rsp) +} - response := &GetTeamByNameResponse{ - Body: bodyBytes, - HTTPResponse: rsp, +// CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationTestConnectionResponse +func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncIntegrationTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) +} - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Team - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest +func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncIntegrationTestConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest +// ListV2SyncIntegrationsWithResponse request returning *ListV2SyncIntegrationsResponse +func (c *ClientWithResponses) ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) { + rsp, err := c.ListV2SyncIntegrations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListV2SyncIntegrationsResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest +// CreateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationResponse +func (c *ClientWithResponses) CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { + rsp, err := c.CreateV2SyncIntegrationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncIntegrationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest +func (c *ClientWithResponses) CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { + rsp, err := c.CreateV2SyncIntegration(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncIntegrationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest +// DeleteV2SyncIntegrationWithResponse request returning *DeleteV2SyncIntegrationResponse +func (c *ClientWithResponses) DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) { + rsp, err := c.DeleteV2SyncIntegration(ctx, syncName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteV2SyncIntegrationResponse(rsp) +} - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest +// GetV2SyncIntegrationWithResponse request returning *GetV2SyncIntegrationResponse +func (c *ClientWithResponses) GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) { + rsp, err := c.GetV2SyncIntegration(ctx, syncName, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetV2SyncIntegrationResponse(rsp) +} +// UpdateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *UpdateV2SyncIntegrationResponse +func (c *ClientWithResponses) UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { + rsp, err := c.UpdateV2SyncIntegrationWithBody(ctx, syncName, contentType, body, reqEditors...) + if err != nil { + return nil, err } + return ParseUpdateV2SyncIntegrationResponse(rsp) +} - return response, nil +func (c *ClientWithResponses) UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { + rsp, err := c.UpdateV2SyncIntegration(ctx, syncName, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateV2SyncIntegrationResponse(rsp) } -// ParseUpdateTeamResponse parses an HTTP response from a UpdateTeamWithResponse call -func ParseUpdateTeamResponse(rsp *http.Response) (*UpdateTeamResponse, error) { +// ParseIndexResponse parses an HTTP response from a IndexWithResponse call +func ParseIndexResponse(rsp *http.Response) (*IndexResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateTeamResponse{ + response := &IndexResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Team - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err + var dest struct { + Errors *[]string `json:"errors,omitempty"` + FieldErrors *map[string]string `json:"field_errors,omitempty"` + Message string `json:"message"` + Status int `json:"status"` } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON500 = &dest + response.JSON400 = &dest } @@ -42506,15 +30298,15 @@ func ParseTestUnsavedAlertResponse(rsp *http.Response) (*TestUnsavedAlertRespons return response, nil } -// ParseListTeamAPIKeysResponse parses an HTTP response from a ListTeamAPIKeysWithResponse call -func ParseListTeamAPIKeysResponse(rsp *http.Response) (*ListTeamAPIKeysResponse, error) { +// ParseListAPIKeysResponse parses an HTTP response from a ListAPIKeysWithResponse call +func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListTeamAPIKeysResponse{ + response := &ListAPIKeysResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -42523,173 +30315,15 @@ func ParseListTeamAPIKeysResponse(rsp *http.Response) (*ListTeamAPIKeysResponse, case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { // AllowedRoles List of allowed roles when creating a new API key - AllowedRoles []APIKeyTeamRole `json:"allowed_roles"` - Items []APIKey `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseCreateTeamAPIKeyResponse parses an HTTP response from a CreateTeamAPIKeyWithResponse call -func ParseCreateTeamAPIKeyResponse(rsp *http.Response) (*CreateTeamAPIKeyResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &CreateTeamAPIKeyResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest APIKey - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseDeleteTeamAPIKeyResponse parses an HTTP response from a DeleteTeamAPIKeyWithResponse call -func ParseDeleteTeamAPIKeyResponse(rsp *http.Response) (*DeleteTeamAPIKeyResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &DeleteTeamAPIKeyResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseListConnectorsResponse parses an HTTP response from a ListConnectorsWithResponse call -func ParseListConnectorsResponse(rsp *http.Response) (*ListConnectorsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &ListConnectorsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Connector `json:"items"` - Metadata ListMetadata `json:"metadata"` + AllowedRoles []Role `json:"allowed_roles"` + Items []APIKey `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -42716,80 +30350,33 @@ func ParseListConnectorsResponse(rsp *http.Response) (*ListConnectorsResponse, e return response, nil } -// ParseCreateConnectorResponse parses an HTTP response from a CreateConnectorWithResponse call -func ParseCreateConnectorResponse(rsp *http.Response) (*CreateConnectorResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &CreateConnectorResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Connector - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseGetConnectorResponse parses an HTTP response from a GetConnectorWithResponse call -func ParseGetConnectorResponse(rsp *http.Response) (*GetConnectorResponse, error) { +// ParseCreateAPIKeyResponse parses an HTTP response from a CreateAPIKeyWithResponse call +func ParseCreateAPIKeyResponse(rsp *http.Response) (*CreateAPIKeyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetConnectorResponse{ + response := &CreateAPIKeyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Connector + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest APIKey if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -42798,12 +30385,19 @@ func ParseGetConnectorResponse(rsp *http.Response) (*GetConnectorResponse, error } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -42817,27 +30411,20 @@ func ParseGetConnectorResponse(rsp *http.Response) (*GetConnectorResponse, error return response, nil } -// ParseUpdateConnectorResponse parses an HTTP response from a UpdateConnectorWithResponse call -func ParseUpdateConnectorResponse(rsp *http.Response) (*UpdateConnectorResponse, error) { +// ParseDeleteAPIKeyResponse parses an HTTP response from a DeleteAPIKeyWithResponse call +func ParseDeleteAPIKeyResponse(rsp *http.Response) (*DeleteAPIKeyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateConnectorResponse{ + response := &DeleteAPIKeyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Connector - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -42859,6 +30446,13 @@ func ParseUpdateConnectorResponse(rsp *http.Response) (*UpdateConnectorResponse, } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -42871,40 +30465,43 @@ func ParseUpdateConnectorResponse(rsp *http.Response) (*UpdateConnectorResponse, return response, nil } -// ParseRevokeConnectorResponse parses an HTTP response from a RevokeConnectorWithResponse call -func ParseRevokeConnectorResponse(rsp *http.Response) (*RevokeConnectorResponse, error) { +// ParseListAuditLogsResponse parses an HTTP response from a ListAuditLogsWithResponse call +func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &RevokeConnectorResponse{ + response := &ListAuditLogsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []AuditLogEvent `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -42918,40 +30515,27 @@ func ParseRevokeConnectorResponse(rsp *http.Response) (*RevokeConnectorResponse, return response, nil } -// ParseGetConnectorAuthStatusAWSResponse parses an HTTP response from a GetConnectorAuthStatusAWSWithResponse call -func ParseGetConnectorAuthStatusAWSResponse(rsp *http.Response) (*GetConnectorAuthStatusAWSResponse, error) { +// ParseGetAuditLogResponse parses an HTTP response from a GetAuditLogWithResponse call +func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetConnectorAuthStatusAWSResponse{ + response := &GetAuditLogResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // ExternalID External ID used for the role - ExternalID *string `json:"external_id,omitempty"` - - // RoleARN ARN of role created by the user - RoleARN *string `json:"role_arn,omitempty"` - } + var dest AuditLogEvent if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -42959,19 +30543,19 @@ func ParseGetConnectorAuthStatusAWSResponse(rsp *http.Response) (*GetConnectorAu } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON404 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -42985,54 +30569,33 @@ func ParseGetConnectorAuthStatusAWSResponse(rsp *http.Response) (*GetConnectorAu return response, nil } -// ParseAuthenticateConnectorFinishAWSResponse parses an HTTP response from a AuthenticateConnectorFinishAWSWithResponse call -func ParseAuthenticateConnectorFinishAWSResponse(rsp *http.Response) (*AuthenticateConnectorFinishAWSResponse, error) { +// ParseGetSAMLResponse parses an HTTP response from a GetSAMLWithResponse call +func ParseGetSAMLResponse(rsp *http.Response) (*GetSAMLResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorFinishAWSResponse{ + response := &GetSAMLResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SAMLConfig if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -43046,22 +30609,22 @@ func ParseAuthenticateConnectorFinishAWSResponse(rsp *http.Response) (*Authentic return response, nil } -// ParseAuthenticateConnectorAWSResponse parses an HTTP response from a AuthenticateConnectorAWSWithResponse call -func ParseAuthenticateConnectorAWSResponse(rsp *http.Response) (*AuthenticateConnectorAWSResponse, error) { +// ParseUpdateSAMLResponse parses an HTTP response from a UpdateSAMLWithResponse call +func ParseUpdateSAMLResponse(rsp *http.Response) (*UpdateSAMLResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorAWSResponse{ + response := &UpdateSAMLResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ConnectorAuthResponseAWS + var dest SAMLConfig if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -43074,13 +30637,6 @@ func ParseAuthenticateConnectorAWSResponse(rsp *http.Response) (*AuthenticateCon } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43107,29 +30663,26 @@ func ParseAuthenticateConnectorAWSResponse(rsp *http.Response) (*AuthenticateCon return response, nil } -// ParseGetConnectorAuthStatusGCPResponse parses an HTTP response from a GetConnectorAuthStatusGCPWithResponse call -func ParseGetConnectorAuthStatusGCPResponse(rsp *http.Response) (*GetConnectorAuthStatusGCPResponse, error) { +// ParseCreateConversationResponse parses an HTTP response from a CreateConversationWithResponse call +func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetConnectorAuthStatusGCPResponse{ + response := &CreateConversationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // ServiceAccount CloudQuery GCP Service Account to grant access to - ServiceAccount *string `json:"service_account,omitempty"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest Conversation if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -43145,19 +30698,12 @@ func ParseGetConnectorAuthStatusGCPResponse(rsp *http.Response) (*GetConnectorAu } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON429 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -43171,22 +30717,22 @@ func ParseGetConnectorAuthStatusGCPResponse(rsp *http.Response) (*GetConnectorAu return response, nil } -// ParseAuthenticateConnectorGCPResponse parses an HTTP response from a AuthenticateConnectorGCPWithResponse call -func ParseAuthenticateConnectorGCPResponse(rsp *http.Response) (*AuthenticateConnectorGCPResponse, error) { +// ParseGetConversationResponse parses an HTTP response from a GetConversationWithResponse call +func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorGCPResponse{ + response := &GetConversationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ConnectorAuthResponseGCP + var dest Conversation if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -43232,20 +30778,27 @@ func ParseAuthenticateConnectorGCPResponse(rsp *http.Response) (*AuthenticateCon return response, nil } -// ParseAuthenticateConnectorFinishGCPResponse parses an HTTP response from a AuthenticateConnectorFinishGCPWithResponse call -func ParseAuthenticateConnectorFinishGCPResponse(rsp *http.Response) (*AuthenticateConnectorFinishGCPResponse, error) { +// ParseSendMessageResponse parses an HTTP response from a SendMessageWithResponse call +func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorFinishGCPResponse{ + response := &SendMessageResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest ConversationMessage + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43293,22 +30846,25 @@ func ParseAuthenticateConnectorFinishGCPResponse(rsp *http.Response) (*Authentic return response, nil } -// ParseAuthenticateConnectorFinishOAuthResponse parses an HTTP response from a AuthenticateConnectorFinishOAuthWithResponse call -func ParseAuthenticateConnectorFinishOAuthResponse(rsp *http.Response) (*AuthenticateConnectorFinishOAuthResponse, error) { +// ParseListAllCustomColumnsResponse parses an HTTP response from a ListAllCustomColumnsWithResponse call +func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumnsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorFinishOAuthResponse{ + response := &ListAllCustomColumnsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ConnectorAuthResponseOAuth + var dest struct { + Items []CustomColumn `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -43361,26 +30917,26 @@ func ParseAuthenticateConnectorFinishOAuthResponse(rsp *http.Response) (*Authent return response, nil } -// ParseAuthenticateConnectorOAuthResponse parses an HTTP response from a AuthenticateConnectorOAuthWithResponse call -func ParseAuthenticateConnectorOAuthResponse(rsp *http.Response) (*AuthenticateConnectorOAuthResponse, error) { +// ParseSaveCustomColumnResponse parses an HTTP response from a SaveCustomColumnWithResponse call +func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateConnectorOAuthResponse{ + response := &SaveCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ConnectorAuthResponseOAuth + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -43396,6 +30952,13 @@ func ParseAuthenticateConnectorOAuthResponse(rsp *http.Response) (*AuthenticateC } response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43422,47 +30985,47 @@ func ParseAuthenticateConnectorOAuthResponse(rsp *http.Response) (*AuthenticateC return response, nil } -// ParseCreateConversationResponse parses an HTTP response from a CreateConversationWithResponse call -func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationResponse, error) { +// ParseDeleteCustomColumnResponse parses an HTTP response from a DeleteCustomColumnWithResponse call +func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateConversationResponse{ + response := &DeleteCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Conversation + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -43476,40 +31039,40 @@ func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationRes return response, nil } -// ParseGetConversationResponse parses an HTTP response from a GetConversationWithResponse call -func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, error) { +// ParseGetCustomColumnResponse parses an HTTP response from a GetCustomColumnWithResponse call +func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetConversationResponse{ + response := &GetCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Conversation + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -43518,6 +31081,13 @@ func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43530,26 +31100,26 @@ func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, return response, nil } -// ParseSendMessageResponse parses an HTTP response from a SendMessageWithResponse call -func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) { +// ParseUpdateCustomColumnResponse parses an HTTP response from a UpdateCustomColumnWithResponse call +func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SendMessageResponse{ + response := &UpdateCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest ConversationMessage + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -43579,6 +31149,13 @@ func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43591,15 +31168,15 @@ func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) return response, nil } -// ParseListAllCustomColumnsResponse parses an HTTP response from a ListAllCustomColumnsWithResponse call -func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumnsResponse, error) { +// ParseListFiltersResponse parses an HTTP response from a ListFiltersWithResponse call +func ParseListFiltersResponse(rsp *http.Response) (*ListFiltersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllCustomColumnsResponse{ + response := &ListFiltersResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -43607,21 +31184,14 @@ func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumn switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []CustomColumn `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43662,33 +31232,29 @@ func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumn return response, nil } -// ParseSaveCustomColumnResponse parses an HTTP response from a SaveCustomColumnWithResponse call -func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnResponse, error) { +// ParseListFilterTagsResponse parses an HTTP response from a ListFilterTagsWithResponse call +func ParseListFilterTagsResponse(rsp *http.Response) (*ListFilterTagsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SaveCustomColumnResponse{ + response := &ListFilterTagsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest CustomColumn - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -43730,15 +31296,15 @@ func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnRespons return response, nil } -// ParseDeleteCustomColumnResponse parses an HTTP response from a DeleteCustomColumnWithResponse call -func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnResponse, error) { +// ParseDeleteFilterResponse parses an HTTP response from a DeleteFilterWithResponse call +func ParseDeleteFilterResponse(rsp *http.Response) (*DeleteFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteCustomColumnResponse{ + response := &DeleteFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -43784,22 +31350,22 @@ func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnRes return response, nil } -// ParseGetCustomColumnResponse parses an HTTP response from a GetCustomColumnWithResponse call -func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, error) { +// ParseGetFilterByIDResponse parses an HTTP response from a GetFilterByIDWithResponse call +func ParseGetFilterByIDResponse(rsp *http.Response) (*GetFilterByIDResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetCustomColumnResponse{ + response := &GetFilterByIDResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest CustomColumn + var dest Filter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -43845,34 +31411,27 @@ func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, return response, nil } -// ParseUpdateCustomColumnResponse parses an HTTP response from a UpdateCustomColumnWithResponse call -func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnResponse, error) { +// ParseUpdateFilterResponse parses an HTTP response from a UpdateFilterWithResponse call +func ParseUpdateFilterResponse(rsp *http.Response) (*UpdateFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateCustomColumnResponse{ + response := &UpdateFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest CustomColumn + var dest Filter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43913,69 +31472,60 @@ func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnRes return response, nil } -// ParsePutCustomColumnDataResponse parses an HTTP response from a PutCustomColumnDataWithResponse call -func ParsePutCustomColumnDataResponse(rsp *http.Response) (*PutCustomColumnDataResponse, error) { +// ParseHealthCheckResponse parses an HTTP response from a HealthCheckWithResponse call +func ParseHealthCheckResponse(rsp *http.Response) (*HealthCheckResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &PutCustomColumnDataResponse{ + response := &HealthCheckResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 202: - var dest struct { - Data CustomColumnDataImportAccepted `json:"data"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON202 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest ServiceUnavailable if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON503 = &dest } return response, nil } -// ParsePutCustomColumnValuesResponse parses an HTTP response from a PutCustomColumnValuesWithResponse call -func ParsePutCustomColumnValuesResponse(rsp *http.Response) (*PutCustomColumnValuesResponse, error) { +// ParseHealthCheckHeadResponse parses an HTTP response from a HealthCheckHeadWithResponse call +func ParseHealthCheckHeadResponse(rsp *http.Response) (*HealthCheckHeadResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &PutCustomColumnValuesResponse{ + response := &HealthCheckHeadResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest map[string]interface{} - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -43983,34 +31533,34 @@ func ParsePutCustomColumnValuesResponse(rsp *http.Response) (*PutCustomColumnVal } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest ServiceUnavailable if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON503 = &dest } return response, nil } -// ParseListFiltersTeamResponse parses an HTTP response from a ListFiltersTeamWithResponse call -func ParseListFiltersTeamResponse(rsp *http.Response) (*ListFiltersTeamResponse, error) { +// ParseListNotificationsResponse parses an HTTP response from a ListNotificationsWithResponse call +func ParseListNotificationsResponse(rsp *http.Response) (*ListNotificationsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListFiltersTeamResponse{ + response := &ListNotificationsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -44018,8 +31568,8 @@ func ParseListFiltersTeamResponse(rsp *http.Response) (*ListFiltersTeamResponse, switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []NotificationDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -44066,30 +31616,20 @@ func ParseListFiltersTeamResponse(rsp *http.Response) (*ListFiltersTeamResponse, return response, nil } -// ParseListFilterTagsTeamResponse parses an HTTP response from a ListFilterTagsTeamWithResponse call -func ParseListFilterTagsTeamResponse(rsp *http.Response) (*ListFilterTagsTeamResponse, error) { +// ParseDeleteNotificationDestinationResponse parses an HTTP response from a DeleteNotificationDestinationWithResponse call +func ParseDeleteNotificationDestinationResponse(rsp *http.Response) (*DeleteNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListFilterTagsTeamResponse{ + response := &DeleteNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44130,20 +31670,27 @@ func ParseListFilterTagsTeamResponse(rsp *http.Response) (*ListFilterTagsTeamRes return response, nil } -// ParseDeleteFilterTeamResponse parses an HTTP response from a DeleteFilterTeamWithResponse call -func ParseDeleteFilterTeamResponse(rsp *http.Response) (*DeleteFilterTeamResponse, error) { +// ParseGetNotificationDestinationResponse parses an HTTP response from a GetNotificationDestinationWithResponse call +func ParseGetNotificationDestinationResponse(rsp *http.Response) (*GetNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteFilterTeamResponse{ + response := &GetNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest NotificationDestination + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44184,27 +31731,34 @@ func ParseDeleteFilterTeamResponse(rsp *http.Response) (*DeleteFilterTeamRespons return response, nil } -// ParseGetFilterByIDTeamResponse parses an HTTP response from a GetFilterByIDTeamWithResponse call -func ParseGetFilterByIDTeamResponse(rsp *http.Response) (*GetFilterByIDTeamResponse, error) { +// ParseUpdateNotificationDestinationResponse parses an HTTP response from a UpdateNotificationDestinationWithResponse call +func ParseUpdateNotificationDestinationResponse(rsp *http.Response) (*UpdateNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetFilterByIDTeamResponse{ + response := &UpdateNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Filter + var dest NotificationDestination if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44245,22 +31799,25 @@ func ParseGetFilterByIDTeamResponse(rsp *http.Response) (*GetFilterByIDTeamRespo return response, nil } -// ParseUpdateFilterTeamResponse parses an HTTP response from a UpdateFilterTeamWithResponse call -func ParseUpdateFilterTeamResponse(rsp *http.Response) (*UpdateFilterTeamResponse, error) { +// ParseGetNotificationDestinationAlertsResponse parses an HTTP response from a GetNotificationDestinationAlertsWithResponse call +func ParseGetNotificationDestinationAlertsResponse(rsp *http.Response) (*GetNotificationDestinationAlertsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateFilterTeamResponse{ + response := &GetNotificationDestinationAlertsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Filter + var dest struct { + Items []AlertDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -44306,29 +31863,33 @@ func ParseUpdateFilterTeamResponse(rsp *http.Response) (*UpdateFilterTeamRespons return response, nil } -// ParseCreateTeamImagesResponse parses an HTTP response from a CreateTeamImagesWithResponse call -func ParseCreateTeamImagesResponse(rsp *http.Response) (*CreateTeamImagesResponse, error) { +// ParseTestNotificationDestinationResponse parses an HTTP response from a TestNotificationDestinationWithResponse call +func ParseTestNotificationDestinationResponse(rsp *http.Response) (*TestNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateTeamImagesResponse{ + response := &TestNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Items []TeamImage `json:"items"` - Metadata ListMetadata `json:"metadata"` + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest NotificationDestinationTestResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -44351,6 +31912,20 @@ func ParseCreateTeamImagesResponse(rsp *http.Response) (*CreateTeamImagesRespons } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44363,26 +31938,29 @@ func ParseCreateTeamImagesResponse(rsp *http.Response) (*CreateTeamImagesRespons return response, nil } -// ParseDeleteTeamInvitationResponse parses an HTTP response from a DeleteTeamInvitationWithResponse call -func ParseDeleteTeamInvitationResponse(rsp *http.Response) (*DeleteTeamInvitationResponse, error) { +// ParseListAllNotificationDestinationsResponse parses an HTTP response from a ListAllNotificationDestinationsWithResponse call +func ParseListAllNotificationDestinationsResponse(rsp *http.Response) (*ListAllNotificationDestinationsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteTeamInvitationResponse{ + response := &ListAllNotificationDestinationsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []NotificationDestinationListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -44405,6 +31983,13 @@ func ParseDeleteTeamInvitationResponse(rsp *http.Response) (*DeleteTeamInvitatio } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44417,83 +32002,61 @@ func ParseDeleteTeamInvitationResponse(rsp *http.Response) (*DeleteTeamInvitatio return response, nil } -// ParseListTeamInvitationsResponse parses an HTTP response from a ListTeamInvitationsWithResponse call -func ParseListTeamInvitationsResponse(rsp *http.Response) (*ListTeamInvitationsResponse, error) { +// ParseCreateNotificationDestinationResponse parses an HTTP response from a CreateNotificationDestinationWithResponse call +func ParseCreateNotificationDestinationResponse(rsp *http.Response) (*CreateNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListTeamInvitationsResponse{ + response := &CreateNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Invitation `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest NotificationDestination if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseAcceptTeamInvitationResponse parses an HTTP response from a AcceptTeamInvitationWithResponse call -func ParseAcceptTeamInvitationResponse(rsp *http.Response) (*AcceptTeamInvitationResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &AcceptTeamInvitationResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } + response.JSON401 = &dest - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest MembershipWithTeam + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 303: - var dest MembershipWithTeam + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON303 = &dest + response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -44507,20 +32070,27 @@ func ParseAcceptTeamInvitationResponse(rsp *http.Response) (*AcceptTeamInvitatio return response, nil } -// ParseRemoveTeamMembershipResponse parses an HTTP response from a RemoveTeamMembershipWithResponse call -func ParseRemoveTeamMembershipResponse(rsp *http.Response) (*RemoveTeamMembershipResponse, error) { +// ParseTestUnsavedNotificationDestinationResponse parses an HTTP response from a TestUnsavedNotificationDestinationWithResponse call +func ParseTestUnsavedNotificationDestinationResponse(rsp *http.Response) (*TestUnsavedNotificationDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &RemoveTeamMembershipResponse{ + response := &TestUnsavedNotificationDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest NotificationDestinationTestResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44568,29 +32138,26 @@ func ParseRemoveTeamMembershipResponse(rsp *http.Response) (*RemoveTeamMembershi return response, nil } -// ParseGetTeamMembershipsResponse parses an HTTP response from a GetTeamMembershipsWithResponse call -func ParseGetTeamMembershipsResponse(rsp *http.Response) (*GetTeamMembershipsResponse, error) { +// ParseCreateAWSOnboardingResponse parses an HTTP response from a CreateAWSOnboardingWithResponse call +func ParseCreateAWSOnboardingResponse(rsp *http.Response) (*CreateAWSOnboardingResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetTeamMembershipsResponse{ + response := &CreateAWSOnboardingResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []MembershipWithUser `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest OnboardingAWSCreateResponse if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -44606,20 +32173,6 @@ func ParseGetTeamMembershipsResponse(rsp *http.Response) (*GetTeamMembershipsRes } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44632,20 +32185,27 @@ func ParseGetTeamMembershipsResponse(rsp *http.Response) (*GetTeamMembershipsRes return response, nil } -// ParseDeleteTeamMembershipResponse parses an HTTP response from a DeleteTeamMembershipWithResponse call -func ParseDeleteTeamMembershipResponse(rsp *http.Response) (*DeleteTeamMembershipResponse, error) { +// ParseGetAWSOnboardingResponse parses an HTTP response from a GetAWSOnboardingWithResponse call +func ParseGetAWSOnboardingResponse(rsp *http.Response) (*GetAWSOnboardingResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteTeamMembershipResponse{ + response := &GetAWSOnboardingResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest OnboardingAWS + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44660,13 +32220,6 @@ func ParseDeleteTeamMembershipResponse(rsp *http.Response) (*DeleteTeamMembershi } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44674,13 +32227,6 @@ func ParseDeleteTeamMembershipResponse(rsp *http.Response) (*DeleteTeamMembershi } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44693,47 +32239,47 @@ func ParseDeleteTeamMembershipResponse(rsp *http.Response) (*DeleteTeamMembershi return response, nil } -// ParseDeleteNotificationDestinationResponse parses an HTTP response from a DeleteNotificationDestinationWithResponse call -func ParseDeleteNotificationDestinationResponse(rsp *http.Response) (*DeleteNotificationDestinationResponse, error) { +// ParseGetAWSAccountsInRootResponse parses an HTTP response from a GetAWSAccountsInRootWithResponse call +func ParseGetAWSAccountsInRootResponse(rsp *http.Response) (*GetAWSAccountsInRootResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteNotificationDestinationResponse{ + response := &GetAWSAccountsInRootResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest OnboardingAWSAccounts if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON404 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -44747,26 +32293,26 @@ func ParseDeleteNotificationDestinationResponse(rsp *http.Response) (*DeleteNoti return response, nil } -// ParseGetNotificationDestinationResponse parses an HTTP response from a GetNotificationDestinationWithResponse call -func ParseGetNotificationDestinationResponse(rsp *http.Response) (*GetNotificationDestinationResponse, error) { +// ParseProvisionOnboardingConfigurationResponse parses an HTTP response from a ProvisionOnboardingConfigurationWithResponse call +func ParseProvisionOnboardingConfigurationResponse(rsp *http.Response) (*ProvisionOnboardingConfigurationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetNotificationDestinationResponse{ + response := &ProvisionOnboardingConfigurationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest NotificationDestination + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -44775,13 +32321,6 @@ func ParseGetNotificationDestinationResponse(rsp *http.Response) (*GetNotificati } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44808,22 +32347,22 @@ func ParseGetNotificationDestinationResponse(rsp *http.Response) (*GetNotificati return response, nil } -// ParseUpdateNotificationDestinationResponse parses an HTTP response from a UpdateNotificationDestinationWithResponse call -func ParseUpdateNotificationDestinationResponse(rsp *http.Response) (*UpdateNotificationDestinationResponse, error) { +// ParseGetAWSAccountsInParentResponse parses an HTTP response from a GetAWSAccountsInParentWithResponse call +func ParseGetAWSAccountsInParentResponse(rsp *http.Response) (*GetAWSAccountsInParentResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateNotificationDestinationResponse{ + response := &GetAWSAccountsInParentResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest NotificationDestination + var dest OnboardingAWSAccounts if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -44843,13 +32382,6 @@ func ParseUpdateNotificationDestinationResponse(rsp *http.Response) (*UpdateNoti } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44857,13 +32389,6 @@ func ParseUpdateNotificationDestinationResponse(rsp *http.Response) (*UpdateNoti } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44876,29 +32401,26 @@ func ParseUpdateNotificationDestinationResponse(rsp *http.Response) (*UpdateNoti return response, nil } -// ParseGetNotificationDestinationAlertsResponse parses an HTTP response from a GetNotificationDestinationAlertsWithResponse call -func ParseGetNotificationDestinationAlertsResponse(rsp *http.Response) (*GetNotificationDestinationAlertsResponse, error) { +// ParseNotifyOnboardingResponse parses an HTTP response from a NotifyOnboardingWithResponse call +func ParseNotifyOnboardingResponse(rsp *http.Response) (*NotifyOnboardingResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetNotificationDestinationAlertsResponse{ + response := &NotifyOnboardingResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []AlertDetail `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -44907,27 +32429,6 @@ func ParseGetNotificationDestinationAlertsResponse(rsp *http.Response) (*GetNoti } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -44940,22 +32441,22 @@ func ParseGetNotificationDestinationAlertsResponse(rsp *http.Response) (*GetNoti return response, nil } -// ParseTestNotificationDestinationResponse parses an HTTP response from a TestNotificationDestinationWithResponse call -func ParseTestNotificationDestinationResponse(rsp *http.Response) (*TestNotificationDestinationResponse, error) { +// ParseGetOpenAPIJSONResponse parses an HTTP response from a GetOpenAPIJSONWithResponse call +func ParseGetOpenAPIJSONResponse(rsp *http.Response) (*GetOpenAPIJSONResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TestNotificationDestinationResponse{ + response := &GetOpenAPIJSONResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest NotificationDestinationTestResponse + var dest map[string]interface{} if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -44968,40 +32469,83 @@ func ParseTestNotificationDestinationResponse(rsp *http.Response) (*TestNotifica } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + } + + return response, nil +} + +// ParseGetPlatformInfoResponse parses an HTTP response from a GetPlatformInfoWithResponse call +func ParseGetPlatformInfoResponse(rsp *http.Response) (*GetPlatformInfoResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetPlatformInfoResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + PublicIps *[]string `json:"public_ips,omitempty"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + } + + return response, nil +} + +// ParseListPlatformVersionsResponse parses an HTTP response from a ListPlatformVersionsWithResponse call +func ParseListPlatformVersionsResponse(rsp *http.Response) (*ListPlatformVersionsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ListPlatformVersionsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []PlatformVersion `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45015,15 +32559,15 @@ func ParseTestNotificationDestinationResponse(rsp *http.Response) (*TestNotifica return response, nil } -// ParseListAllNotificationDestinationsResponse parses an HTTP response from a ListAllNotificationDestinationsWithResponse call -func ParseListAllNotificationDestinationsResponse(rsp *http.Response) (*ListAllNotificationDestinationsResponse, error) { +// ParseListPluginsResponse parses an HTTP response from a ListPluginsWithResponse call +func ParseListPluginsResponse(rsp *http.Response) (*ListPluginsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllNotificationDestinationsResponse{ + response := &ListPluginsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -45031,8 +32575,8 @@ func ParseListAllNotificationDestinationsResponse(rsp *http.Response) (*ListAllN switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []NotificationDestinationListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items ListPlugins `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -45046,26 +32590,52 @@ func ParseListAllNotificationDestinationsResponse(rsp *http.Response) (*ListAllN } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + } + + return response, nil +} + +// ParseGetPluginResponse parses an HTTP response from a GetPluginWithResponse call +func ParseGetPluginResponse(rsp *http.Response) (*GetPluginResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetPluginResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest ListPlugin if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45079,26 +32649,29 @@ func ParseListAllNotificationDestinationsResponse(rsp *http.Response) (*ListAllN return response, nil } -// ParseCreateNotificationDestinationResponse parses an HTTP response from a CreateNotificationDestinationWithResponse call -func ParseCreateNotificationDestinationResponse(rsp *http.Response) (*CreateNotificationDestinationResponse, error) { +// ParseListPluginVersionsResponse parses an HTTP response from a ListPluginVersionsWithResponse call +func ParseListPluginVersionsResponse(rsp *http.Response) (*ListPluginVersionsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateNotificationDestinationResponse{ + response := &ListPluginVersionsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest NotificationDestination + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []PluginVersionList `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -45128,13 +32701,6 @@ func ParseCreateNotificationDestinationResponse(rsp *http.Response) (*CreateNoti } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45147,34 +32713,27 @@ func ParseCreateNotificationDestinationResponse(rsp *http.Response) (*CreateNoti return response, nil } -// ParseTestUnsavedNotificationDestinationResponse parses an HTTP response from a TestUnsavedNotificationDestinationWithResponse call -func ParseTestUnsavedNotificationDestinationResponse(rsp *http.Response) (*TestUnsavedNotificationDestinationResponse, error) { +// ParseGetPluginVersionResponse parses an HTTP response from a GetPluginVersionWithResponse call +func ParseGetPluginVersionResponse(rsp *http.Response) (*GetPluginVersionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TestUnsavedNotificationDestinationResponse{ + response := &GetPluginVersionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest NotificationDestinationTestResponse + var dest PluginVersionDetails if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45196,13 +32755,6 @@ func ParseTestUnsavedNotificationDestinationResponse(rsp *http.Response) (*TestU } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45215,40 +32767,47 @@ func ParseTestUnsavedNotificationDestinationResponse(rsp *http.Response) (*TestU return response, nil } -// ParseCreateAWSOnboardingResponse parses an HTTP response from a CreateAWSOnboardingWithResponse call -func ParseCreateAWSOnboardingResponse(rsp *http.Response) (*CreateAWSOnboardingResponse, error) { +// ParseDownloadPluginAssetResponse parses an HTTP response from a DownloadPluginAssetWithResponse call +func ParseDownloadPluginAssetResponse(rsp *http.Response) (*DownloadPluginAssetResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateAWSOnboardingResponse{ + response := &DownloadPluginAssetResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest OnboardingAWSCreateResponse + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PluginAsset if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45262,33 +32821,29 @@ func ParseCreateAWSOnboardingResponse(rsp *http.Response) (*CreateAWSOnboardingR return response, nil } -// ParseGetAWSOnboardingResponse parses an HTTP response from a GetAWSOnboardingWithResponse call -func ParseGetAWSOnboardingResponse(rsp *http.Response) (*GetAWSOnboardingResponse, error) { +// ParseListPluginVersionTablesResponse parses an HTTP response from a ListPluginVersionTablesWithResponse call +func ParseListPluginVersionTablesResponse(rsp *http.Response) (*ListPluginVersionTablesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetAWSOnboardingResponse{ + response := &ListPluginVersionTablesResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest OnboardingAWS - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err + var dest struct { + Items []PluginTable `json:"items"` + Metadata ListMetadata `json:"metadata"` } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -45316,34 +32871,27 @@ func ParseGetAWSOnboardingResponse(rsp *http.Response) (*GetAWSOnboardingRespons return response, nil } -// ParseGetAWSAccountsInRootResponse parses an HTTP response from a GetAWSAccountsInRootWithResponse call -func ParseGetAWSAccountsInRootResponse(rsp *http.Response) (*GetAWSAccountsInRootResponse, error) { +// ParseGetPluginVersionTableResponse parses an HTTP response from a GetPluginVersionTableWithResponse call +func ParseGetPluginVersionTableResponse(rsp *http.Response) (*GetPluginVersionTableResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetAWSAccountsInRootResponse{ + response := &GetPluginVersionTableResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest OnboardingAWSAccounts + var dest PluginTableDetails if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45370,26 +32918,29 @@ func ParseGetAWSAccountsInRootResponse(rsp *http.Response) (*GetAWSAccountsInRoo return response, nil } -// ParseProvisionOnboardingConfigurationResponse parses an HTTP response from a ProvisionOnboardingConfigurationWithResponse call -func ParseProvisionOnboardingConfigurationResponse(rsp *http.Response) (*ProvisionOnboardingConfigurationResponse, error) { +// ParseListPoliciesResponse parses an HTTP response from a ListPoliciesWithResponse call +func ParseListPoliciesResponse(rsp *http.Response) (*ListPoliciesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ProvisionOnboardingConfigurationResponse{ + response := &ListPoliciesResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []Policy `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -45398,12 +32949,12 @@ func ParseProvisionOnboardingConfigurationResponse(rsp *http.Response) (*Provisi } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45417,47 +32968,47 @@ func ParseProvisionOnboardingConfigurationResponse(rsp *http.Response) (*Provisi return response, nil } -// ParseGetAWSAccountsInParentResponse parses an HTTP response from a GetAWSAccountsInParentWithResponse call -func ParseGetAWSAccountsInParentResponse(rsp *http.Response) (*GetAWSAccountsInParentResponse, error) { +// ParseCreatePolicyResponse parses an HTTP response from a CreatePolicyWithResponse call +func ParseCreatePolicyResponse(rsp *http.Response) (*CreatePolicyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetAWSAccountsInParentResponse{ + response := &CreatePolicyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest OnboardingAWSAccounts + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest Policy if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45471,26 +33022,26 @@ func ParseGetAWSAccountsInParentResponse(rsp *http.Response) (*GetAWSAccountsInP return response, nil } -// ParseNotifyOnboardingResponse parses an HTTP response from a NotifyOnboardingWithResponse call -func ParseNotifyOnboardingResponse(rsp *http.Response) (*NotifyOnboardingResponse, error) { +// ParseGetPolicyMetricsResponse parses an HTTP response from a GetPolicyMetricsWithResponse call +func ParseGetPolicyMetricsResponse(rsp *http.Response) (*GetPolicyMetricsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &NotifyOnboardingResponse{ + response := &GetPolicyMetricsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PolicyMetrics if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -45499,6 +33050,13 @@ func ParseNotifyOnboardingResponse(rsp *http.Response) (*NotifyOnboardingRespons } response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45511,26 +33069,26 @@ func ParseNotifyOnboardingResponse(rsp *http.Response) (*NotifyOnboardingRespons return response, nil } -// ParseDeletePluginsByTeamResponse parses an HTTP response from a DeletePluginsByTeamWithResponse call -func ParseDeletePluginsByTeamResponse(rsp *http.Response) (*DeletePluginsByTeamResponse, error) { +// ParseGetViolationsByDomainResponse parses an HTTP response from a GetViolationsByDomainWithResponse call +func ParseGetViolationsByDomainResponse(rsp *http.Response) (*GetViolationsByDomainResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeletePluginsByTeamResponse{ + response := &GetViolationsByDomainResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest ViolationsByDomain if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -45546,13 +33104,6 @@ func ParseDeletePluginsByTeamResponse(rsp *http.Response) (*DeletePluginsByTeamR } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45565,25 +33116,22 @@ func ParseDeletePluginsByTeamResponse(rsp *http.Response) (*DeletePluginsByTeamR return response, nil } -// ParseListPluginsByTeamResponse parses an HTTP response from a ListPluginsByTeamWithResponse call -func ParseListPluginsByTeamResponse(rsp *http.Response) (*ListPluginsByTeamResponse, error) { +// ParseGetViolationsHistoryResponse parses an HTTP response from a GetViolationsHistoryWithResponse call +func ParseGetViolationsHistoryResponse(rsp *http.Response) (*GetViolationsHistoryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListPluginsByTeamResponse{ + response := &GetViolationsHistoryResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Plugin `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest ViolationsHistory if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -45603,13 +33151,6 @@ func ParseListPluginsByTeamResponse(rsp *http.Response) (*ListPluginsByTeamRespo } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45622,33 +33163,33 @@ func ParseListPluginsByTeamResponse(rsp *http.Response) (*ListPluginsByTeamRespo return response, nil } -// ParseDownloadPluginAssetByTeamResponse parses an HTTP response from a DownloadPluginAssetByTeamWithResponse call -func ParseDownloadPluginAssetByTeamResponse(rsp *http.Response) (*DownloadPluginAssetByTeamResponse, error) { +// ParseDeletePolicyResponse parses an HTTP response from a DeletePolicyWithResponse call +func ParseDeletePolicyResponse(rsp *http.Response) (*DeletePolicyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DownloadPluginAssetByTeamResponse{ + response := &DeletePolicyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest PluginAsset + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -45657,12 +33198,12 @@ func ParseDownloadPluginAssetByTeamResponse(rsp *http.Response) (*DownloadPlugin } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -45676,36 +33217,40 @@ func ParseDownloadPluginAssetByTeamResponse(rsp *http.Response) (*DownloadPlugin return response, nil } -// ParseListPoliciesResponse parses an HTTP response from a ListPoliciesWithResponse call -func ParseListPoliciesResponse(rsp *http.Response) (*ListPoliciesResponse, error) { +// ParseGetPolicyResponse parses an HTTP response from a GetPolicyWithResponse call +func ParseGetPolicyResponse(rsp *http.Response) (*GetPolicyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListPoliciesResponse{ + response := &GetPolicyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Metadata ListMetadata `json:"metadata"` - Policies []PlatformPolicy `json:"policies"` - } + var dest Policy if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -45714,33 +33259,38 @@ func ParseListPoliciesResponse(rsp *http.Response) (*ListPoliciesResponse, error } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseCreatePolicyResponse parses an HTTP response from a CreatePolicyWithResponse call -func ParseCreatePolicyResponse(rsp *http.Response) (*CreatePolicyResponse, error) { +// ParseUpdatePolicyResponse parses an HTTP response from a UpdatePolicyWithResponse call +func ParseUpdatePolicyResponse(rsp *http.Response) (*UpdatePolicyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreatePolicyResponse{ + response := &UpdatePolicyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - Data PlatformPolicy `json:"data"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest Policy if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -45749,6 +33299,13 @@ func ParseCreatePolicyResponse(rsp *http.Response) (*CreatePolicyResponse, error } response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45756,61 +33313,60 @@ func ParseCreatePolicyResponse(rsp *http.Response) (*CreatePolicyResponse, error } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseListAllFrameworksResponse parses an HTTP response from a ListAllFrameworksWithResponse call -func ParseListAllFrameworksResponse(rsp *http.Response) (*ListAllFrameworksResponse, error) { +// ParseTogglePolicyResponse parses an HTTP response from a TogglePolicyWithResponse call +func ParseTogglePolicyResponse(rsp *http.Response) (*TogglePolicyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllFrameworksResponse{ + response := &TogglePolicyResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Frameworks []PlatformPolicyFramework `json:"frameworks"` - Metadata ListMetadata `json:"metadata"` - } + var dest Policy if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest - - } - - return response, nil -} - -// ParseDeletePolicyResponse parses an HTTP response from a DeletePolicyWithResponse call -func ParseDeletePolicyResponse(rsp *http.Response) (*DeletePolicyResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &DeletePolicyResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } + response.JSON401 = &dest - switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45825,20 +33381,34 @@ func ParseDeletePolicyResponse(rsp *http.Response) (*DeletePolicyResponse, error } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseGetPolicyResponse parses an HTTP response from a GetPolicyWithResponse call -func ParseGetPolicyResponse(rsp *http.Response) (*GetPolicyResponse, error) { +// ParseGetPolicyViolationsResponse parses an HTTP response from a GetPolicyViolationsWithResponse call +func ParseGetPolicyViolationsResponse(rsp *http.Response) (*GetPolicyViolationsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetPolicyResponse{ + response := &GetPolicyViolationsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -45846,13 +33416,28 @@ func ParseGetPolicyResponse(rsp *http.Response) (*GetPolicyResponse, error) { switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Data PlatformPolicy `json:"data"` + Items []PolicyViolation `json:"items"` + Metadata *ListMetadata `json:"metadata,omitempty"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -45860,20 +33445,27 @@ func ParseGetPolicyResponse(rsp *http.Response) (*GetPolicyResponse, error) { } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseUpdatePolicyResponse parses an HTTP response from a UpdatePolicyWithResponse call -func ParseUpdatePolicyResponse(rsp *http.Response) (*UpdatePolicyResponse, error) { +// ParseGetPolicyViolationsHistoryResponse parses an HTTP response from a GetPolicyViolationsHistoryWithResponse call +func ParseGetPolicyViolationsHistoryResponse(rsp *http.Response) (*GetPolicyViolationsHistoryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdatePolicyResponse{ + response := &GetPolicyViolationsHistoryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -45881,19 +33473,20 @@ func ParseUpdatePolicyResponse(rsp *http.Response) (*UpdatePolicyResponse, error switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Data PlatformPolicy `json:"data"` + Items []PolicyEvaluationLog `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden @@ -45909,20 +33502,27 @@ func ParseUpdatePolicyResponse(rsp *http.Response) (*UpdatePolicyResponse, error } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseListPolicyFrameworksResponse parses an HTTP response from a ListPolicyFrameworksWithResponse call -func ParseListPolicyFrameworksResponse(rsp *http.Response) (*ListPolicyFrameworksResponse, error) { +// ParseListPolicyGroupsResponse parses an HTTP response from a ListPolicyGroupsWithResponse call +func ParseListPolicyGroupsResponse(rsp *http.Response) (*ListPolicyGroupsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListPolicyFrameworksResponse{ + response := &ListPolicyGroupsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -45930,106 +33530,120 @@ func ParseListPolicyFrameworksResponse(rsp *http.Response) (*ListPolicyFramework switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Frameworks []PlatformPolicyFramework `json:"frameworks"` - Metadata ListMetadata `json:"metadata"` + Items []PolicyGroupWithCounts `json:"items"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest } return response, nil } -// ParseListPolicyRulesResponse parses an HTTP response from a ListPolicyRulesWithResponse call -func ParseListPolicyRulesResponse(rsp *http.Response) (*ListPolicyRulesResponse, error) { +// ParseCreatePolicyGroupResponse parses an HTTP response from a CreatePolicyGroupWithResponse call +func ParseCreatePolicyGroupResponse(rsp *http.Response) (*CreatePolicyGroupResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListPolicyRulesResponse{ + response := &CreatePolicyGroupResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Metadata ListMetadata `json:"metadata"` - Rules []PlatformPolicyRule `json:"rules"` + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest PolicyGroup + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest } return response, nil } -// ParseListPolicyRuleDetailsResponse parses an HTTP response from a ListPolicyRuleDetailsWithResponse call -func ParseListPolicyRuleDetailsResponse(rsp *http.Response) (*ListPolicyRuleDetailsResponse, error) { +// ParseDeletePolicyGroupResponse parses an HTTP response from a DeletePolicyGroupWithResponse call +func ParseDeletePolicyGroupResponse(rsp *http.Response) (*DeletePolicyGroupResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListPolicyRuleDetailsResponse{ + response := &DeletePolicyGroupResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Details []PlatformPolicyRuleDetail `json:"details"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -46038,31 +33652,48 @@ func ParseListPolicyRuleDetailsResponse(rsp *http.Response) (*ListPolicyRuleDeta } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseTogglePolicyResponse parses an HTTP response from a TogglePolicyWithResponse call -func ParseTogglePolicyResponse(rsp *http.Response) (*TogglePolicyResponse, error) { +// ParseListPoliciesInGroupResponse parses an HTTP response from a ListPoliciesInGroupWithResponse call +func ParseListPoliciesInGroupResponse(rsp *http.Response) (*ListPoliciesInGroupResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TogglePolicyResponse{ + response := &ListPoliciesInGroupResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []Policy `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden @@ -46078,29 +33709,34 @@ func ParseTogglePolicyResponse(rsp *http.Response) (*TogglePolicyResponse, error } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseGetPolicyViolationsHistoryResponse parses an HTTP response from a GetPolicyViolationsHistoryWithResponse call -func ParseGetPolicyViolationsHistoryResponse(rsp *http.Response) (*GetPolicyViolationsHistoryResponse, error) { +// ParseUpdatePolicyGroupResponse parses an HTTP response from a UpdatePolicyGroupWithResponse call +func ParseUpdatePolicyGroupResponse(rsp *http.Response) (*UpdatePolicyGroupResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetPolicyViolationsHistoryResponse{ + response := &UpdatePolicyGroupResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Details []PlatformPolicyViolationHistory `json:"details"` - } + var dest PolicyGroup if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -46113,20 +33749,55 @@ func ParseGetPolicyViolationsHistoryResponse(rsp *http.Response) (*GetPolicyViol } response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseListAllQueriesTeamResponse parses an HTTP response from a ListAllQueriesTeamWithResponse call -func ParseListAllQueriesTeamResponse(rsp *http.Response) (*ListAllQueriesTeamResponse, error) { +// ParseListAllQueriesResponse parses an HTTP response from a ListAllQueriesWithResponse call +func ParseListAllQueriesResponse(rsp *http.Response) (*ListAllQueriesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllQueriesTeamResponse{ + response := &ListAllQueriesResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46182,15 +33853,15 @@ func ParseListAllQueriesTeamResponse(rsp *http.Response) (*ListAllQueriesTeamRes return response, nil } -// ParseExecuteAdHocQueryTeamResponse parses an HTTP response from a ExecuteAdHocQueryTeamWithResponse call -func ParseExecuteAdHocQueryTeamResponse(rsp *http.Response) (*ExecuteAdHocQueryTeamResponse, error) { +// ParseExecuteAdHocQueryResponse parses an HTTP response from a ExecuteAdHocQueryWithResponse call +func ParseExecuteAdHocQueryResponse(rsp *http.Response) (*ExecuteAdHocQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ExecuteAdHocQueryTeamResponse{ + response := &ExecuteAdHocQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46253,15 +33924,15 @@ func ParseExecuteAdHocQueryTeamResponse(rsp *http.Response) (*ExecuteAdHocQueryT return response, nil } -// ParseSaveQueryTeamResponse parses an HTTP response from a SaveQueryTeamWithResponse call -func ParseSaveQueryTeamResponse(rsp *http.Response) (*SaveQueryTeamResponse, error) { +// ParseSaveQueryResponse parses an HTTP response from a SaveQueryWithResponse call +func ParseSaveQueryResponse(rsp *http.Response) (*SaveQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SaveQueryTeamResponse{ + response := &SaveQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46314,15 +33985,15 @@ func ParseSaveQueryTeamResponse(rsp *http.Response) (*SaveQueryTeamResponse, err return response, nil } -// ParseListQueryTagsTeamResponse parses an HTTP response from a ListQueryTagsTeamWithResponse call -func ParseListQueryTagsTeamResponse(rsp *http.Response) (*ListQueryTagsTeamResponse, error) { +// ParseListQueryTagsResponse parses an HTTP response from a ListQueryTagsWithResponse call +func ParseListQueryTagsResponse(rsp *http.Response) (*ListQueryTagsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListQueryTagsTeamResponse{ + response := &ListQueryTagsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46378,15 +34049,15 @@ func ParseListQueryTagsTeamResponse(rsp *http.Response) (*ListQueryTagsTeamRespo return response, nil } -// ParseDeleteSavedQueryTeamResponse parses an HTTP response from a DeleteSavedQueryTeamWithResponse call -func ParseDeleteSavedQueryTeamResponse(rsp *http.Response) (*DeleteSavedQueryTeamResponse, error) { +// ParseDeleteSavedQueryResponse parses an HTTP response from a DeleteSavedQueryWithResponse call +func ParseDeleteSavedQueryResponse(rsp *http.Response) (*DeleteSavedQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteSavedQueryTeamResponse{ + response := &DeleteSavedQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46432,15 +34103,15 @@ func ParseDeleteSavedQueryTeamResponse(rsp *http.Response) (*DeleteSavedQueryTea return response, nil } -// ParseGetSavedQueryTeamResponse parses an HTTP response from a GetSavedQueryTeamWithResponse call -func ParseGetSavedQueryTeamResponse(rsp *http.Response) (*GetSavedQueryTeamResponse, error) { +// ParseGetSavedQueryResponse parses an HTTP response from a GetSavedQueryWithResponse call +func ParseGetSavedQueryResponse(rsp *http.Response) (*GetSavedQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSavedQueryTeamResponse{ + response := &GetSavedQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46493,15 +34164,15 @@ func ParseGetSavedQueryTeamResponse(rsp *http.Response) (*GetSavedQueryTeamRespo return response, nil } -// ParseUpdateQueryTeamResponse parses an HTTP response from a UpdateQueryTeamWithResponse call -func ParseUpdateQueryTeamResponse(rsp *http.Response) (*UpdateQueryTeamResponse, error) { +// ParseUpdateQueryResponse parses an HTTP response from a UpdateQueryWithResponse call +func ParseUpdateQueryResponse(rsp *http.Response) (*UpdateQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateQueryTeamResponse{ + response := &UpdateQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46615,15 +34286,15 @@ func ParseDeleteAlertResponse(rsp *http.Response) (*DeleteAlertResponse, error) return response, nil } -// ParseExecuteSavedQueryTeamResponse parses an HTTP response from a ExecuteSavedQueryTeamWithResponse call -func ParseExecuteSavedQueryTeamResponse(rsp *http.Response) (*ExecuteSavedQueryTeamResponse, error) { +// ParseExecuteSavedQueryResponse parses an HTTP response from a ExecuteSavedQueryWithResponse call +func ParseExecuteSavedQueryResponse(rsp *http.Response) (*ExecuteSavedQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ExecuteSavedQueryTeamResponse{ + response := &ExecuteSavedQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46686,15 +34357,15 @@ func ParseExecuteSavedQueryTeamResponse(rsp *http.Response) (*ExecuteSavedQueryT return response, nil } -// ParseQueryListFiltersTeamResponse parses an HTTP response from a QueryListFiltersTeamWithResponse call -func ParseQueryListFiltersTeamResponse(rsp *http.Response) (*QueryListFiltersTeamResponse, error) { +// ParseQueryListFiltersResponse parses an HTTP response from a QueryListFiltersWithResponse call +func ParseQueryListFiltersResponse(rsp *http.Response) (*QueryListFiltersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &QueryListFiltersTeamResponse{ + response := &QueryListFiltersResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46757,15 +34428,15 @@ func ParseQueryListFiltersTeamResponse(rsp *http.Response) (*QueryListFiltersTea return response, nil } -// ParseQuerySaveFilterTeamResponse parses an HTTP response from a QuerySaveFilterTeamWithResponse call -func ParseQuerySaveFilterTeamResponse(rsp *http.Response) (*QuerySaveFilterTeamResponse, error) { +// ParseQuerySaveFilterResponse parses an HTTP response from a QuerySaveFilterWithResponse call +func ParseQuerySaveFilterResponse(rsp *http.Response) (*QuerySaveFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &QuerySaveFilterTeamResponse{ + response := &QuerySaveFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -46832,15 +34503,15 @@ func ParseQuerySaveFilterTeamResponse(rsp *http.Response) (*QuerySaveFilterTeamR return response, nil } -// ParseQueryListFilterTagsTeamResponse parses an HTTP response from a QueryListFilterTagsTeamWithResponse call -func ParseQueryListFilterTagsTeamResponse(rsp *http.Response) (*QueryListFilterTagsTeamResponse, error) { +// ParseQueryListFilterTagsResponse parses an HTTP response from a QueryListFilterTagsWithResponse call +func ParseQueryListFilterTagsResponse(rsp *http.Response) (*QueryListFilterTagsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &QueryListFilterTagsTeamResponse{ + response := &QueryListFilterTagsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -47241,7 +34912,7 @@ func ParseListAllRBACRolesResponse(rsp *http.Response) (*ListAllRBACRolesRespons switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []RBACRole `json:"items"` + Items []Role `json:"items"` Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -47311,7 +34982,7 @@ func ParseCreateRBACRoleResponse(rsp *http.Response) (*CreateRBACRoleResponse, e switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest RBACRole + var dest Role if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -47433,7 +35104,7 @@ func ParseGetRBACRoleResponse(rsp *http.Response) (*GetRBACRoleResponse, error) switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest RBACRole + var dest Role if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -47501,7 +35172,7 @@ func ParseUpdateRBACRoleResponse(rsp *http.Response) (*UpdateRBACRoleResponse, e switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest RBACRole + var dest Role if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -47986,33 +35657,87 @@ func ParseUpdateReportResponse(rsp *http.Response) (*UpdateReportResponse, error return response, nil } -// ParseCreateSyncDestinationTestConnectionResponse parses an HTTP response from a CreateSyncDestinationTestConnectionWithResponse call -func ParseCreateSyncDestinationTestConnectionResponse(rsp *http.Response) (*CreateSyncDestinationTestConnectionResponse, error) { +// ParseGetSettingsResponse parses an HTTP response from a GetSettingsWithResponse call +func ParseGetSettingsResponse(rsp *http.Response) (*GetSettingsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateSyncDestinationTestConnectionResponse{ + response := &GetSettingsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest SyncDestinationTestConnection + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PlatformSettings if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseUpdateSettingsResponse parses an HTTP response from a UpdateSettingsWithResponse call +func ParseUpdateSettingsResponse(rsp *http.Response) (*UpdateSettingsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &UpdateSettingsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PlatformSettings + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -48021,6 +35746,13 @@ func ParseCreateSyncDestinationTestConnectionResponse(rsp *http.Response) (*Crea } response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48035,12 +35767,66 @@ func ParseCreateSyncDestinationTestConnectionResponse(rsp *http.Response) (*Crea } response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseGetDataSettingsResponse parses an HTTP response from a GetDataSettingsWithResponse call +func ParseGetDataSettingsResponse(rsp *http.Response) (*GetDataSettingsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDataSettingsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PlatformDataSettings + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -48054,22 +35840,22 @@ func ParseCreateSyncDestinationTestConnectionResponse(rsp *http.Response) (*Crea return response, nil } -// ParseGetSyncDestinationTestConnectionResponse parses an HTTP response from a GetSyncDestinationTestConnectionWithResponse call -func ParseGetSyncDestinationTestConnectionResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionResponse, error) { +// ParseUpdateDataSettingsResponse parses an HTTP response from a UpdateDataSettingsWithResponse call +func ParseUpdateDataSettingsResponse(rsp *http.Response) (*UpdateDataSettingsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncDestinationTestConnectionResponse{ + response := &UpdateDataSettingsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncDestinationTestConnection + var dest PlatformDataSettings if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -48096,6 +35882,13 @@ func ParseGetSyncDestinationTestConnectionResponse(rsp *http.Response) (*GetSync } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48108,26 +35901,26 @@ func ParseGetSyncDestinationTestConnectionResponse(rsp *http.Response) (*GetSync return response, nil } -// ParseUpdateSyncTestConnectionForSyncDestinationResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncDestinationWithResponse call -func ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { +// ParseCreateSlackConnectionResponse parses an HTTP response from a CreateSlackConnectionWithResponse call +func ParseCreateSlackConnectionResponse(rsp *http.Response) (*CreateSlackConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateSyncTestConnectionForSyncDestinationResponse{ + response := &CreateSlackConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncDestinationTestConnection + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest SlackConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -48136,6 +35929,13 @@ func ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp *http.Response) } response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48169,15 +35969,15 @@ func ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp *http.Response) return response, nil } -// ParseGetSyncDestinationTestConnectionLogsResponse parses an HTTP response from a GetSyncDestinationTestConnectionLogsWithResponse call -func ParseGetSyncDestinationTestConnectionLogsResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionLogsResponse, error) { +// ParseListSlackChannelsResponse parses an HTTP response from a ListSlackChannelsWithResponse call +func ParseListSlackChannelsResponse(rsp *http.Response) (*ListSlackChannelsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncDestinationTestConnectionLogsResponse{ + response := &ListSlackChannelsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -48185,27 +35985,26 @@ func ParseGetSyncDestinationTestConnectionLogsResponse(rsp *http.Response) (*Get switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - // Location The location to download the test connection logs from - Location string `json:"location"` + Items []SlackChannel `json:"items"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -48228,28 +36027,32 @@ func ParseGetSyncDestinationTestConnectionLogsResponse(rsp *http.Response) (*Get } response.JSON500 = &dest - case rsp.StatusCode == 200: - // Content-type (text/plain) unsupported - } return response, nil } -// ParseGetSyncDestinationTestConnectionLogsLiveResponse parses an HTTP response from a GetSyncDestinationTestConnectionLogsLiveWithResponse call -func ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) { +// ParseCreateSyncDestinationTestConnectionResponse parses an HTTP response from a CreateSyncDestinationTestConnectionWithResponse call +func ParseCreateSyncDestinationTestConnectionResponse(rsp *http.Response) (*CreateSyncDestinationTestConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncDestinationTestConnectionLogsLiveResponse{ + response := &CreateSyncDestinationTestConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest SyncDestinationTestConnection + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48278,6 +36081,13 @@ func ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp *http.Response) ( } response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48290,25 +36100,76 @@ func ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp *http.Response) ( return response, nil } -// ParseGetSyncDestinationTestConnectionLogsQueryResponse parses an HTTP response from a GetSyncDestinationTestConnectionLogsQueryWithResponse call -func ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) { +// ParseGetSyncDestinationTestConnectionResponse parses an HTTP response from a GetSyncDestinationTestConnectionWithResponse call +func ParseGetSyncDestinationTestConnectionResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncDestinationTestConnectionLogsQueryResponse{ + response := &GetSyncDestinationTestConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` + var dest SyncDestinationTestConnection + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseUpdateSyncTestConnectionForSyncDestinationResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncDestinationWithResponse call +func ParseUpdateSyncTestConnectionForSyncDestinationResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &UpdateSyncTestConnectionForSyncDestinationResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SyncDestinationTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -48321,12 +36182,12 @@ func ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp *http.Response) } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -48349,42 +36210,25 @@ func ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp *http.Response) } response.JSON500 = &dest - case rsp.StatusCode == 200: - // Content-type (text/plain) unsupported - } return response, nil } -// ParsePromoteSyncDestinationTestConnectionResponse parses an HTTP response from a PromoteSyncDestinationTestConnectionWithResponse call -func ParsePromoteSyncDestinationTestConnectionResponse(rsp *http.Response) (*PromoteSyncDestinationTestConnectionResponse, error) { +// ParseGetSyncDestinationTestConnectionLogsLiveResponse parses an HTTP response from a GetSyncDestinationTestConnectionLogsLiveWithResponse call +func ParseGetSyncDestinationTestConnectionLogsLiveResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &PromoteSyncDestinationTestConnectionResponse{ + response := &GetSyncDestinationTestConnectionLogsLiveResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncDestination - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest SyncDestination - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48425,15 +36269,15 @@ func ParsePromoteSyncDestinationTestConnectionResponse(rsp *http.Response) (*Pro return response, nil } -// ParseListSyncDestinationsResponse parses an HTTP response from a ListSyncDestinationsWithResponse call -func ParseListSyncDestinationsResponse(rsp *http.Response) (*ListSyncDestinationsResponse, error) { +// ParseGetSyncDestinationTestConnectionLogsQueryResponse parses an HTTP response from a GetSyncDestinationTestConnectionLogsQueryWithResponse call +func ParseGetSyncDestinationTestConnectionLogsQueryResponse(rsp *http.Response) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListSyncDestinationsResponse{ + response := &GetSyncDestinationTestConnectionLogsQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -48441,8 +36285,8 @@ func ParseListSyncDestinationsResponse(rsp *http.Response) (*ListSyncDestination switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []SyncDestination `json:"items"` - Metadata ListMetadata `json:"metadata"` + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -48470,6 +36314,13 @@ func ParseListSyncDestinationsResponse(rsp *http.Response) (*ListSyncDestination } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48477,25 +36328,49 @@ func ParseListSyncDestinationsResponse(rsp *http.Response) (*ListSyncDestination } response.JSON500 = &dest + case rsp.StatusCode == 200: + // Content-type (text/plain) unsupported + } return response, nil } -// ParseDeleteSyncDestinationResponse parses an HTTP response from a DeleteSyncDestinationWithResponse call -func ParseDeleteSyncDestinationResponse(rsp *http.Response) (*DeleteSyncDestinationResponse, error) { +// ParsePromoteSyncDestinationTestConnectionResponse parses an HTTP response from a PromoteSyncDestinationTestConnectionWithResponse call +func ParsePromoteSyncDestinationTestConnectionResponse(rsp *http.Response) (*PromoteSyncDestinationTestConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteSyncDestinationResponse{ + response := &PromoteSyncDestinationTestConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SyncDestination + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest SyncDestination + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48529,27 +36404,37 @@ func ParseDeleteSyncDestinationResponse(rsp *http.Response) (*DeleteSyncDestinat return response, nil } -// ParseGetSyncDestinationResponse parses an HTTP response from a GetSyncDestinationWithResponse call -func ParseGetSyncDestinationResponse(rsp *http.Response) (*GetSyncDestinationResponse, error) { +// ParseListSyncDestinationsResponse parses an HTTP response from a ListSyncDestinationsWithResponse call +func ParseListSyncDestinationsResponse(rsp *http.Response) (*ListSyncDestinationsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncDestinationResponse{ + response := &ListSyncDestinationsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncDestination + var dest struct { + Items []SyncDestination `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48576,34 +36461,20 @@ func ParseGetSyncDestinationResponse(rsp *http.Response) (*GetSyncDestinationRes return response, nil } -// ParseUpdateSyncDestinationResponse parses an HTTP response from a UpdateSyncDestinationWithResponse call -func ParseUpdateSyncDestinationResponse(rsp *http.Response) (*UpdateSyncDestinationResponse, error) { +// ParseDeleteSyncDestinationResponse parses an HTTP response from a DeleteSyncDestinationWithResponse call +func ParseDeleteSyncDestinationResponse(rsp *http.Response) (*DeleteSyncDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateSyncDestinationResponse{ + response := &DeleteSyncDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncDestination - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48637,26 +36508,26 @@ func ParseUpdateSyncDestinationResponse(rsp *http.Response) (*UpdateSyncDestinat return response, nil } -// ParseMigrateSyncDestinationResponse parses an HTTP response from a MigrateSyncDestinationWithResponse call -func ParseMigrateSyncDestinationResponse(rsp *http.Response) (*MigrateSyncDestinationResponse, error) { +// ParseGetSyncDestinationResponse parses an HTTP response from a GetSyncDestinationWithResponse call +func ParseGetSyncDestinationResponse(rsp *http.Response) (*GetSyncDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &MigrateSyncDestinationResponse{ + response := &GetSyncDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SyncDestination if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -48672,13 +36543,6 @@ func ParseMigrateSyncDestinationResponse(rsp *http.Response) (*MigrateSyncDestin } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48691,25 +36555,22 @@ func ParseMigrateSyncDestinationResponse(rsp *http.Response) (*MigrateSyncDestin return response, nil } -// ParseListSyncDestinationSyncsResponse parses an HTTP response from a ListSyncDestinationSyncsWithResponse call -func ParseListSyncDestinationSyncsResponse(rsp *http.Response) (*ListSyncDestinationSyncsResponse, error) { +// ParseUpdateSyncDestinationResponse parses an HTTP response from a UpdateSyncDestinationWithResponse call +func ParseUpdateSyncDestinationResponse(rsp *http.Response) (*UpdateSyncDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListSyncDestinationSyncsResponse{ + response := &UpdateSyncDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []ListSync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest SyncDestination if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -48736,6 +36597,13 @@ func ParseListSyncDestinationSyncsResponse(rsp *http.Response) (*ListSyncDestina } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48748,22 +36616,25 @@ func ParseListSyncDestinationSyncsResponse(rsp *http.Response) (*ListSyncDestina return response, nil } -// ParseGetTestConnectionForSyncDestinationResponse parses an HTTP response from a GetTestConnectionForSyncDestinationWithResponse call -func ParseGetTestConnectionForSyncDestinationResponse(rsp *http.Response) (*GetTestConnectionForSyncDestinationResponse, error) { +// ParseListSyncDestinationSyncsResponse parses an HTTP response from a ListSyncDestinationSyncsWithResponse call +func ParseListSyncDestinationSyncsResponse(rsp *http.Response) (*ListSyncDestinationSyncsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetTestConnectionForSyncDestinationResponse{ + response := &ListSyncDestinationSyncsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncTestConnection + var dest struct { + Items []ListSync `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -48802,26 +36673,26 @@ func ParseGetTestConnectionForSyncDestinationResponse(rsp *http.Response) (*GetT return response, nil } -// ParseCreateSyncSourceTestConnectionResponse parses an HTTP response from a CreateSyncSourceTestConnectionWithResponse call -func ParseCreateSyncSourceTestConnectionResponse(rsp *http.Response) (*CreateSyncSourceTestConnectionResponse, error) { +// ParseGetTestConnectionForSyncDestinationResponse parses an HTTP response from a GetTestConnectionForSyncDestinationWithResponse call +func ParseGetTestConnectionForSyncDestinationResponse(rsp *http.Response) (*GetTestConnectionForSyncDestinationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateSyncSourceTestConnectionResponse{ + response := &GetTestConnectionForSyncDestinationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest SyncSourceTestConnection + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SyncTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -48844,20 +36715,6 @@ func ParseCreateSyncSourceTestConnectionResponse(rsp *http.Response) (*CreateSyn } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48870,40 +36727,40 @@ func ParseCreateSyncSourceTestConnectionResponse(rsp *http.Response) (*CreateSyn return response, nil } -// ParseGetSyncSourceTestConnectionResponse parses an HTTP response from a GetSyncSourceTestConnectionWithResponse call -func ParseGetSyncSourceTestConnectionResponse(rsp *http.Response) (*GetSyncSourceTestConnectionResponse, error) { +// ParseCreateSyncSourceTestConnectionResponse parses an HTTP response from a CreateSyncSourceTestConnectionWithResponse call +func ParseCreateSyncSourceTestConnectionResponse(rsp *http.Response) (*CreateSyncSourceTestConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncSourceTestConnectionResponse{ + response := &CreateSyncSourceTestConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: var dest SyncSourceTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -48912,6 +36769,20 @@ func ParseGetSyncSourceTestConnectionResponse(rsp *http.Response) (*GetSyncSourc } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48924,15 +36795,15 @@ func ParseGetSyncSourceTestConnectionResponse(rsp *http.Response) (*GetSyncSourc return response, nil } -// ParseUpdateSyncTestConnectionForSyncSourceResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncSourceWithResponse call -func ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { +// ParseGetSyncSourceTestConnectionResponse parses an HTTP response from a GetSyncSourceTestConnectionWithResponse call +func ParseGetSyncSourceTestConnectionResponse(rsp *http.Response) (*GetSyncSourceTestConnectionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateSyncTestConnectionForSyncSourceResponse{ + response := &GetSyncSourceTestConnectionResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -48945,12 +36816,12 @@ func ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp *http.Response) (*Up } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden @@ -48966,13 +36837,6 @@ func ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp *http.Response) (*Up } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -48985,25 +36849,22 @@ func ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp *http.Response) (*Up return response, nil } -// ParseGetSyncSourceTestConnectionLogsResponse parses an HTTP response from a GetSyncSourceTestConnectionLogsWithResponse call -func ParseGetSyncSourceTestConnectionLogsResponse(rsp *http.Response) (*GetSyncSourceTestConnectionLogsResponse, error) { +// ParseUpdateSyncTestConnectionForSyncSourceResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncSourceWithResponse call +func ParseUpdateSyncTestConnectionForSyncSourceResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncSourceResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncSourceTestConnectionLogsResponse{ + response := &UpdateSyncTestConnectionForSyncSourceResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // Location The location to download the test connection logs from - Location string `json:"location"` - } + var dest SyncSourceTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -49016,12 +36877,12 @@ func ParseGetSyncSourceTestConnectionLogsResponse(rsp *http.Response) (*GetSyncS } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -49044,9 +36905,6 @@ func ParseGetSyncSourceTestConnectionLogsResponse(rsp *http.Response) (*GetSyncS } response.JSON500 = &dest - case rsp.StatusCode == 200: - // Content-type (text/plain) unsupported - } return response, nil @@ -49453,60 +37311,6 @@ func ParseUpdateSyncSourceResponse(rsp *http.Response) (*UpdateSyncSourceRespons return response, nil } -// ParseMigrateSyncSourceResponse parses an HTTP response from a MigrateSyncSourceWithResponse call -func ParseMigrateSyncSourceResponse(rsp *http.Response) (*MigrateSyncSourceResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &MigrateSyncSourceResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - // ParseListSyncSourceSyncsResponse parses an HTTP response from a ListSyncSourceSyncsWithResponse call func ParseListSyncSourceSyncsResponse(rsp *http.Response) (*ListSyncSourceSyncsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -49769,141 +37573,34 @@ func ParseGetSyncTransformerResponse(rsp *http.Response) (*GetSyncTransformerRes return response, nil } -// ParseUpdateSyncTransformerResponse parses an HTTP response from a UpdateSyncTransformerWithResponse call -func ParseUpdateSyncTransformerResponse(rsp *http.Response) (*UpdateSyncTransformerResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &UpdateSyncTransformerResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncTransformer - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseListSyncTransformerSyncDestinationsResponse parses an HTTP response from a ListSyncTransformerSyncDestinationsWithResponse call -func ParseListSyncTransformerSyncDestinationsResponse(rsp *http.Response) (*ListSyncTransformerSyncDestinationsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &ListSyncTransformerSyncDestinationsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []SyncDestination `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseListSyncTransformerSyncsResponse parses an HTTP response from a ListSyncTransformerSyncsWithResponse call -func ParseListSyncTransformerSyncsResponse(rsp *http.Response) (*ListSyncTransformerSyncsResponse, error) { +// ParseUpdateSyncTransformerResponse parses an HTTP response from a UpdateSyncTransformerWithResponse call +func ParseUpdateSyncTransformerResponse(rsp *http.Response) (*UpdateSyncTransformerResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListSyncTransformerSyncsResponse{ + response := &UpdateSyncTransformerResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Sync `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest SyncTransformer if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -49918,6 +37615,13 @@ func ParseListSyncTransformerSyncsResponse(rsp *http.Response) (*ListSyncTransfo } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -49930,15 +37634,15 @@ func ParseListSyncTransformerSyncsResponse(rsp *http.Response) (*ListSyncTransfo return response, nil } -// ParseListSyncUpgradesResponse parses an HTTP response from a ListSyncUpgradesWithResponse call -func ParseListSyncUpgradesResponse(rsp *http.Response) (*ListSyncUpgradesResponse, error) { +// ParseListSyncTransformerSyncDestinationsResponse parses an HTTP response from a ListSyncTransformerSyncDestinationsWithResponse call +func ParseListSyncTransformerSyncDestinationsResponse(rsp *http.Response) (*ListSyncTransformerSyncDestinationsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListSyncUpgradesResponse{ + response := &ListSyncTransformerSyncDestinationsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -49946,21 +37650,14 @@ func ParseListSyncUpgradesResponse(rsp *http.Response) (*ListSyncUpgradesRespons switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []SyncUpgrade `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []SyncDestination `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -49987,15 +37684,15 @@ func ParseListSyncUpgradesResponse(rsp *http.Response) (*ListSyncUpgradesRespons return response, nil } -// ParseListSyncsResponse parses an HTTP response from a ListSyncsWithResponse call -func ParseListSyncsResponse(rsp *http.Response) (*ListSyncsResponse, error) { +// ParseListSyncTransformerSyncsResponse parses an HTTP response from a ListSyncTransformerSyncsWithResponse call +func ParseListSyncTransformerSyncsResponse(rsp *http.Response) (*ListSyncTransformerSyncsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListSyncsResponse{ + response := &ListSyncTransformerSyncsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -50003,7 +37700,7 @@ func ParseListSyncsResponse(rsp *http.Response) (*ListSyncsResponse, error) { switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []ListSync `json:"items"` + Items []Sync `json:"items"` Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50011,13 +37708,6 @@ func ParseListSyncsResponse(rsp *http.Response) (*ListSyncsResponse, error) { } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50044,26 +37734,29 @@ func ParseListSyncsResponse(rsp *http.Response) (*ListSyncsResponse, error) { return response, nil } -// ParseCreateSyncResponse parses an HTTP response from a CreateSyncWithResponse call -func ParseCreateSyncResponse(rsp *http.Response) (*CreateSyncResponse, error) { +// ParseListSyncUpgradesResponse parses an HTTP response from a ListSyncUpgradesWithResponse call +func ParseListSyncUpgradesResponse(rsp *http.Response) (*ListSyncUpgradesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateSyncResponse{ + response := &ListSyncUpgradesResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Sync + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []SyncUpgrade `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -50079,12 +37772,12 @@ func ParseCreateSyncResponse(rsp *http.Response) (*CreateSyncResponse, error) { } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON404 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -50098,15 +37791,15 @@ func ParseCreateSyncResponse(rsp *http.Response) (*CreateSyncResponse, error) { return response, nil } -// ParseGetTestConnectionConnectorCredentialsResponse parses an HTTP response from a GetTestConnectionConnectorCredentialsWithResponse call -func ParseGetTestConnectionConnectorCredentialsResponse(rsp *http.Response) (*GetTestConnectionConnectorCredentialsResponse, error) { +// ParseListSyncsResponse parses an HTTP response from a ListSyncsWithResponse call +func ParseListSyncsResponse(rsp *http.Response) (*ListSyncsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetTestConnectionConnectorCredentialsResponse{ + response := &ListSyncsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -50114,11 +37807,8 @@ func ParseGetTestConnectionConnectorCredentialsResponse(rsp *http.Response) (*Ge switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - // Aws AWS connector credentials response - Aws *ConnectorCredentialsResponseAWS `json:"aws,omitempty"` - - // Oauth OAuth connector credentials response - Oauth *ConnectorCredentialsResponseOAuth `json:"oauth,omitempty"` + Items []ListSync `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -50146,13 +37836,6 @@ func ParseGetTestConnectionConnectorCredentialsResponse(rsp *http.Response) (*Ge } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50165,29 +37848,26 @@ func ParseGetTestConnectionConnectorCredentialsResponse(rsp *http.Response) (*Ge return response, nil } -// ParseGetTestConnectionConnectorIdentityResponse parses an HTTP response from a GetTestConnectionConnectorIdentityWithResponse call -func ParseGetTestConnectionConnectorIdentityResponse(rsp *http.Response) (*GetTestConnectionConnectorIdentityResponse, error) { +// ParseCreateSyncResponse parses an HTTP response from a CreateSyncWithResponse call +func ParseCreateSyncResponse(rsp *http.Response) (*CreateSyncResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetTestConnectionConnectorIdentityResponse{ + response := &CreateSyncResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // Aws AWS connector identity response - Aws *ConnectorIdentityResponseAWS `json:"aws,omitempty"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest Sync if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -50203,13 +37883,6 @@ func ParseGetTestConnectionConnectorIdentityResponse(rsp *http.Response) (*GetTe } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50610,33 +38283,20 @@ func ParseUpdateSyncRunResponse(rsp *http.Response) (*UpdateSyncRunResponse, err return response, nil } -// ParseGetSyncRunConnectorCredentialsResponse parses an HTTP response from a GetSyncRunConnectorCredentialsWithResponse call -func ParseGetSyncRunConnectorCredentialsResponse(rsp *http.Response) (*GetSyncRunConnectorCredentialsResponse, error) { +// ParseGetSyncRunLogsLiveResponse parses an HTTP response from a GetSyncRunLogsLiveWithResponse call +func ParseGetSyncRunLogsLiveResponse(rsp *http.Response) (*GetSyncRunLogsLiveResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunConnectorCredentialsResponse{ + response := &GetSyncRunLogsLiveResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // Aws AWS connector credentials response - Aws *ConnectorCredentialsResponseAWS `json:"aws,omitempty"` - - // Oauth OAuth connector credentials response - Oauth *ConnectorCredentialsResponseOAuth `json:"oauth,omitempty"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50677,15 +38337,15 @@ func ParseGetSyncRunConnectorCredentialsResponse(rsp *http.Response) (*GetSyncRu return response, nil } -// ParseGetSyncRunConnectorIdentityResponse parses an HTTP response from a GetSyncRunConnectorIdentityWithResponse call -func ParseGetSyncRunConnectorIdentityResponse(rsp *http.Response) (*GetSyncRunConnectorIdentityResponse, error) { +// ParseGetSyncRunLogsQueryResponse parses an HTTP response from a GetSyncRunLogsQueryWithResponse call +func ParseGetSyncRunLogsQueryResponse(rsp *http.Response) (*GetSyncRunLogsQueryResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunConnectorIdentityResponse{ + response := &GetSyncRunLogsQueryResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -50693,8 +38353,8 @@ func ParseGetSyncRunConnectorIdentityResponse(rsp *http.Response) (*GetSyncRunCo switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - // Aws AWS connector identity response - Aws *ConnectorIdentityResponseAWS `json:"aws,omitempty"` + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -50736,35 +38396,28 @@ func ParseGetSyncRunConnectorIdentityResponse(rsp *http.Response) (*GetSyncRunCo } response.JSON500 = &dest + case rsp.StatusCode == 200: + // Content-type (text/plain) unsupported + } return response, nil } -// ParseGetSyncRunLogsResponse parses an HTTP response from a GetSyncRunLogsWithResponse call -func ParseGetSyncRunLogsResponse(rsp *http.Response) (*GetSyncRunLogsResponse, error) { +// ParseCreateSyncRunProgressResponse parses an HTTP response from a CreateSyncRunProgressWithResponse call +func ParseCreateSyncRunProgressResponse(rsp *http.Response) (*CreateSyncRunProgressResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunLogsResponse{ + response := &CreateSyncRunProgressResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // Location The location to download the sync run logs from - Location string `json:"location"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50800,28 +38453,89 @@ func ParseGetSyncRunLogsResponse(rsp *http.Response) (*GetSyncRunLogsResponse, e } response.JSON500 = &dest - case rsp.StatusCode == 200: - // Content-type (text/plain) unsupported + } + + return response, nil +} + +// ParseGetSyncRunStatsResponse parses an HTTP response from a GetSyncRunStatsWithResponse call +func ParseGetSyncRunStatsResponse(rsp *http.Response) (*GetSyncRunStatsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetSyncRunStatsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SyncRunStats + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest } return response, nil } -// ParseGetSyncRunLogsLiveResponse parses an HTTP response from a GetSyncRunLogsLiveWithResponse call -func ParseGetSyncRunLogsLiveResponse(rsp *http.Response) (*GetSyncRunLogsLiveResponse, error) { +// ParseGetSyncRunTablesResponse parses an HTTP response from a GetSyncRunTablesWithResponse call +func ParseGetSyncRunTablesResponse(rsp *http.Response) (*GetSyncRunTablesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunLogsLiveResponse{ + response := &GetSyncRunTablesResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []SyncRunTableStat `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50843,6 +38557,63 @@ func ParseGetSyncRunLogsLiveResponse(rsp *http.Response) (*GetSyncRunLogsLiveRes } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseListTablesResponse parses an HTTP response from a ListTablesWithResponse call +func ParseListTablesResponse(rsp *http.Response) (*ListTablesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &ListTablesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []TableListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50862,15 +38633,15 @@ func ParseGetSyncRunLogsLiveResponse(rsp *http.Response) (*GetSyncRunLogsLiveRes return response, nil } -// ParseGetSyncRunLogsQueryResponse parses an HTTP response from a GetSyncRunLogsQueryWithResponse call -func ParseGetSyncRunLogsQueryResponse(rsp *http.Response) (*GetSyncRunLogsQueryResponse, error) { +// ParseGetTablesDataResponse parses an HTTP response from a GetTablesDataWithResponse call +func ParseGetTablesDataResponse(rsp *http.Response) (*GetTablesDataResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunLogsQueryResponse{ + response := &GetTablesDataResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -50878,21 +38649,14 @@ func ParseGetSyncRunLogsQueryResponse(rsp *http.Response) (*GetSyncRunLogsQueryR switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` + Metadata ListMetadata `json:"metadata"` + Syncs []TableDataListItem `json:"syncs"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -50900,19 +38664,12 @@ func ParseGetSyncRunLogsQueryResponse(rsp *http.Response) (*GetSyncRunLogsQueryR } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -50921,23 +38678,20 @@ func ParseGetSyncRunLogsQueryResponse(rsp *http.Response) (*GetSyncRunLogsQueryR } response.JSON500 = &dest - case rsp.StatusCode == 200: - // Content-type (text/plain) unsupported - } return response, nil } -// ParseCreateSyncRunProgressResponse parses an HTTP response from a CreateSyncRunProgressWithResponse call -func ParseCreateSyncRunProgressResponse(rsp *http.Response) (*CreateSyncRunProgressResponse, error) { +// ParseTablesDataActionResponse parses an HTTP response from a TablesDataActionWithResponse call +func ParseTablesDataActionResponse(rsp *http.Response) (*TablesDataActionResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateSyncRunProgressResponse{ + response := &TablesDataActionResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -50957,12 +38711,12 @@ func ParseCreateSyncRunProgressResponse(rsp *http.Response) (*CreateSyncRunProgr } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity @@ -50983,40 +38737,42 @@ func ParseCreateSyncRunProgressResponse(rsp *http.Response) (*CreateSyncRunProgr return response, nil } -// ParseGetSyncRunStatsResponse parses an HTTP response from a GetSyncRunStatsWithResponse call -func ParseGetSyncRunStatsResponse(rsp *http.Response) (*GetSyncRunStatsResponse, error) { +// ParseBatchTableSchemasResponse parses an HTTP response from a BatchTableSchemasWithResponse call +func ParseBatchTableSchemasResponse(rsp *http.Response) (*BatchTableSchemasResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunStatsResponse{ + response := &BatchTableSchemasResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SyncRunStats + var dest struct { + Items []BatchTableSchemaItem `json:"items"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -51025,6 +38781,13 @@ func ParseGetSyncRunStatsResponse(rsp *http.Response) (*GetSyncRunStatsResponse, } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51037,15 +38800,15 @@ func ParseGetSyncRunStatsResponse(rsp *http.Response) (*GetSyncRunStatsResponse, return response, nil } -// ParseGetSyncRunTablesResponse parses an HTTP response from a GetSyncRunTablesWithResponse call -func ParseGetSyncRunTablesResponse(rsp *http.Response) (*GetSyncRunTablesResponse, error) { +// ParseTableListColumnsResponse parses an HTTP response from a TableListColumnsWithResponse call +func ParseTableListColumnsResponse(rsp *http.Response) (*TableListColumnsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSyncRunTablesResponse{ + response := &TableListColumnsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51053,27 +38816,27 @@ func ParseGetSyncRunTablesResponse(rsp *http.Response) (*GetSyncRunTablesRespons switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []SyncRunTableStat `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []TableColumnListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -51082,6 +38845,13 @@ func ParseGetSyncRunTablesResponse(rsp *http.Response) (*GetSyncRunTablesRespons } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51094,15 +38864,15 @@ func ParseGetSyncRunTablesResponse(rsp *http.Response) (*GetSyncRunTablesRespons return response, nil } -// ParseListTablesTeamResponse parses an HTTP response from a ListTablesTeamWithResponse call -func ParseListTablesTeamResponse(rsp *http.Response) (*ListTablesTeamResponse, error) { +// ParseTableColumnListValuesResponse parses an HTTP response from a TableColumnListValuesWithResponse call +func ParseTableColumnListValuesResponse(rsp *http.Response) (*TableColumnListValuesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListTablesTeamResponse{ + response := &TableColumnListValuesResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51110,8 +38880,8 @@ func ParseListTablesTeamResponse(rsp *http.Response) (*ListTablesTeamResponse, e switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []TableListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []TableColumnValueListItem `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -51158,15 +38928,15 @@ func ParseListTablesTeamResponse(rsp *http.Response) (*ListTablesTeamResponse, e return response, nil } -// ParseBatchTableSchemasTeamResponse parses an HTTP response from a BatchTableSchemasTeamWithResponse call -func ParseBatchTableSchemasTeamResponse(rsp *http.Response) (*BatchTableSchemasTeamResponse, error) { +// ParseTableListRowsResponse parses an HTTP response from a TableListRowsWithResponse call +func ParseTableListRowsResponse(rsp *http.Response) (*TableListRowsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &BatchTableSchemasTeamResponse{ + response := &TableListRowsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51174,13 +38944,21 @@ func ParseBatchTableSchemasTeamResponse(rsp *http.Response) (*BatchTableSchemasT switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []BatchTableSchemaItem `json:"items"` + Data TableData `json:"data"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51221,15 +38999,15 @@ func ParseBatchTableSchemasTeamResponse(rsp *http.Response) (*BatchTableSchemasT return response, nil } -// ParseTableListColumnsTeamResponse parses an HTTP response from a TableListColumnsTeamWithResponse call -func ParseTableListColumnsTeamResponse(rsp *http.Response) (*TableListColumnsTeamResponse, error) { +// ParseTableRowByIdResponse parses an HTTP response from a TableRowByIdWithResponse call +func ParseTableRowByIdResponse(rsp *http.Response) (*TableRowByIdResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableListColumnsTeamResponse{ + response := &TableRowByIdResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51237,14 +39015,21 @@ func ParseTableListColumnsTeamResponse(rsp *http.Response) (*TableListColumnsTea switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []TableColumnListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` + Data TableRow `json:"data"` + Matches []TableRowFieldMatch `json:"matches"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51285,15 +39070,15 @@ func ParseTableListColumnsTeamResponse(rsp *http.Response) (*TableListColumnsTea return response, nil } -// ParseTableColumnListValuesTeamResponse parses an HTTP response from a TableColumnListValuesTeamWithResponse call -func ParseTableColumnListValuesTeamResponse(rsp *http.Response) (*TableColumnListValuesTeamResponse, error) { +// ParseTableListFiltersResponse parses an HTTP response from a TableListFiltersWithResponse call +func ParseTableListFiltersResponse(rsp *http.Response) (*TableListFiltersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableColumnListValuesTeamResponse{ + response := &TableListFiltersResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51301,14 +39086,21 @@ func ParseTableColumnListValuesTeamResponse(rsp *http.Response) (*TableColumnLis switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []TableColumnValueListItem `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51349,30 +39141,34 @@ func ParseTableColumnListValuesTeamResponse(rsp *http.Response) (*TableColumnLis return response, nil } -// ParseTableListRowsTeamResponse parses an HTTP response from a TableListRowsTeamWithResponse call -func ParseTableListRowsTeamResponse(rsp *http.Response) (*TableListRowsTeamResponse, error) { +// ParseTableSaveFilterResponse parses an HTTP response from a TableSaveFilterWithResponse call +func ParseTableSaveFilterResponse(rsp *http.Response) (*TableSaveFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableListRowsTeamResponse{ + response := &TableSaveFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Data TableData `json:"data"` - Metadata ListMetadata `json:"metadata"` - } + var dest Filter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest Filter + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51420,15 +39216,15 @@ func ParseTableListRowsTeamResponse(rsp *http.Response) (*TableListRowsTeamRespo return response, nil } -// ParseTableRowByIdTeamResponse parses an HTTP response from a TableRowByIdTeamWithResponse call -func ParseTableRowByIdTeamResponse(rsp *http.Response) (*TableRowByIdTeamResponse, error) { +// ParseTableListFilterTagsResponse parses an HTTP response from a TableListFilterTagsWithResponse call +func ParseTableListFilterTagsResponse(rsp *http.Response) (*TableListFilterTagsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableRowByIdTeamResponse{ + response := &TableListFilterTagsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51436,21 +39232,14 @@ func ParseTableRowByIdTeamResponse(rsp *http.Response) (*TableRowByIdTeamRespons switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Data TableRow `json:"data"` - Matches []TableRowFieldMatch `json:"matches"` + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51491,15 +39280,15 @@ func ParseTableRowByIdTeamResponse(rsp *http.Response) (*TableRowByIdTeamRespons return response, nil } -// ParseTableListFiltersTeamResponse parses an HTTP response from a TableListFiltersTeamWithResponse call -func ParseTableListFiltersTeamResponse(rsp *http.Response) (*TableListFiltersTeamResponse, error) { +// ParseTableSchemaResponse parses an HTTP response from a TableSchemaWithResponse call +func ParseTableSchemaResponse(rsp *http.Response) (*TableSchemaResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableListFiltersTeamResponse{ + response := &TableSchemaResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51507,21 +39296,14 @@ func ParseTableListFiltersTeamResponse(rsp *http.Response) (*TableListFiltersTea switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` + DefaultColumns []string `json:"default_columns"` + Schema TableSchema `json:"schema"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51562,54 +39344,90 @@ func ParseTableListFiltersTeamResponse(rsp *http.Response) (*TableListFiltersTea return response, nil } -// ParseTableSaveFilterTeamResponse parses an HTTP response from a TableSaveFilterTeamWithResponse call -func ParseTableSaveFilterTeamResponse(rsp *http.Response) (*TableSaveFilterTeamResponse, error) { +// ParseListTeamsResponse parses an HTTP response from a ListTeamsWithResponse call +func ParseListTeamsResponse(rsp *http.Response) (*ListTeamsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableSaveFilterTeamResponse{ + response := &ListTeamsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Filter + var dest struct { + Items []Team `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Filter + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseDownloadPluginAssetByTeamResponse parses an HTTP response from a DownloadPluginAssetByTeamWithResponse call +func ParseDownloadPluginAssetByTeamResponse(rsp *http.Response) (*DownloadPluginAssetByTeamResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DownloadPluginAssetByTeamResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PluginAsset + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -51618,12 +39436,12 @@ func ParseTableSaveFilterTeamResponse(rsp *http.Response) (*TableSaveFilterTeamR } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON429 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -51637,36 +39455,33 @@ func ParseTableSaveFilterTeamResponse(rsp *http.Response) (*TableSaveFilterTeamR return response, nil } -// ParseTableListFilterTagsTeamResponse parses an HTTP response from a TableListFilterTagsTeamWithResponse call -func ParseTableListFilterTagsTeamResponse(rsp *http.Response) (*TableListFilterTagsTeamResponse, error) { +// ParseUpdateSyncTestConnectionForSyncDestinationTeamResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncDestinationTeamWithResponse call +func ParseUpdateSyncTestConnectionForSyncDestinationTeamResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableListFilterTagsTeamResponse{ + response := &UpdateSyncTestConnectionForSyncDestinationTeamResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest SyncDestinationTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden @@ -51701,24 +39516,22 @@ func ParseTableListFilterTagsTeamResponse(rsp *http.Response) (*TableListFilterT return response, nil } -// ParseTableListRelationsTeamResponse parses an HTTP response from a TableListRelationsTeamWithResponse call -func ParseTableListRelationsTeamResponse(rsp *http.Response) (*TableListRelationsTeamResponse, error) { +// ParseUpdateSyncTestConnectionForSyncSourceTeamResponse parses an HTTP response from a UpdateSyncTestConnectionForSyncSourceTeamWithResponse call +func ParseUpdateSyncTestConnectionForSyncSourceTeamResponse(rsp *http.Response) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableListRelationsTeamResponse{ + response := &UpdateSyncTestConnectionForSyncSourceTeamResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Data []TableRelation `json:"data"` - } + var dest SyncSourceTestConnection if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -51731,13 +39544,6 @@ func ParseTableListRelationsTeamResponse(rsp *http.Response) (*TableListRelation } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51752,6 +39558,13 @@ func ParseTableListRelationsTeamResponse(rsp *http.Response) (*TableListRelation } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51764,29 +39577,26 @@ func ParseTableListRelationsTeamResponse(rsp *http.Response) (*TableListRelation return response, nil } -// ParseTableSchemaTeamResponse parses an HTTP response from a TableSchemaTeamWithResponse call -func ParseTableSchemaTeamResponse(rsp *http.Response) (*TableSchemaTeamResponse, error) { +// ParseCreateSyncRunProgressTeamResponse parses an HTTP response from a CreateSyncRunProgressTeamWithResponse call +func ParseCreateSyncRunProgressTeamResponse(rsp *http.Response) (*CreateSyncRunProgressTeamResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TableSchemaTeamResponse{ + response := &CreateSyncRunProgressTeamResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - DefaultColumns []string `json:"default_columns"` - Schema TableSchema `json:"schema"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -51795,13 +39605,6 @@ func ParseTableSchemaTeamResponse(rsp *http.Response) (*TableSchemaTeamResponse, } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -51964,15 +39767,15 @@ func ParseGetGroupedTeamUsageSummaryResponse(rsp *http.Response) (*GetGroupedTea return response, nil } -// ParseListUsersByTeamResponse parses an HTTP response from a ListUsersByTeamWithResponse call -func ParseListUsersByTeamResponse(rsp *http.Response) (*ListUsersByTeamResponse, error) { +// ParseGetCurrentUserResponse parses an HTTP response from a GetCurrentUserWithResponse call +func ParseGetCurrentUserResponse(rsp *http.Response) (*GetCurrentUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListUsersByTeamResponse{ + response := &GetCurrentUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -51980,14 +39783,97 @@ func ParseListUsersByTeamResponse(rsp *http.Response) (*ListUsersByTeamResponse, switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []User `json:"items"` - Metadata ListMetadata `json:"metadata"` + CreatedAt *time.Time `json:"created_at,omitempty"` + Email string `json:"email"` + + // Enabled Whether the user is enabled + Enabled bool `json:"enabled"` + EventIdentifiers *map[string]interface{} `json:"event_identifiers,omitempty"` + GroupIdentifier *string `json:"group_identifier,omitempty"` + + // ID ID of the User + ID openapi_types.UUID `json:"id"` + LastLoginAt *time.Time `json:"last_login_at,omitempty"` + + // MFAConfigured Whether the user has MFA configured + MFAConfigured bool `json:"mfa_configured"` + + // Name The unique name for the user. + Name *UserName `json:"name,omitempty"` + + // ProfileImageURL Profile image URL of user + ProfileImageURL *string `json:"profile_image_url,omitempty"` + Provider UserProvider `json:"provider"` + + // RegisteredTeamInternal Whether the team is internal or not + RegisteredTeamInternal *bool `json:"registered_team_internal,omitempty"` + + // RegisteredTeamName The name of the team that the platform is registered with + RegisteredTeamName *string `json:"registered_team_name,omitempty"` + Roles []Role `json:"roles"` + + // TrackingOptedIn Whether anonymous user tracking was opted into + TrackingOptedIn *bool `json:"tracking_opted_in,omitempty"` + UpdatedAt *time.Time `json:"updated_at,omitempty"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest struct { + Message string `json:"message"` + + // PasswordResetRequired Whether the user needs to reset their password + PasswordResetRequired *bool `json:"password_reset_required,omitempty"` + Status int `json:"status"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseUpdateCurrentUserResponse parses an HTTP response from a UpdateCurrentUserWithResponse call +func ParseUpdateCurrentUserResponse(rsp *http.Response) (*UpdateCurrentUserResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &UpdateCurrentUserResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest User + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52009,12 +39895,12 @@ func ParseListUsersByTeamResponse(rsp *http.Response) (*ListUsersByTeamResponse, } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: + var dest MethodNotAllowed if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON405 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -52028,33 +39914,40 @@ func ParseListUsersByTeamResponse(rsp *http.Response) (*ListUsersByTeamResponse, return response, nil } -// ParseUploadImageResponse parses an HTTP response from a UploadImageWithResponse call -func ParseUploadImageResponse(rsp *http.Response) (*UploadImageResponse, error) { +// ParseSendAnonymousEventResponse parses an HTTP response from a SendAnonymousEventWithResponse call +func ParseSendAnonymousEventResponse(rsp *http.Response) (*SendAnonymousEventResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UploadImageResponse{ + response := &SendAnonymousEventResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest ImageURL + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -52068,15 +39961,15 @@ func ParseUploadImageResponse(rsp *http.Response) (*UploadImageResponse, error) return response, nil } -// ParseGetCurrentUserResponse parses an HTTP response from a GetCurrentUserWithResponse call -func ParseGetCurrentUserResponse(rsp *http.Response) (*GetCurrentUserResponse, error) { +// ParseAuthenticateUserResponse parses an HTTP response from a AuthenticateUserWithResponse call +func ParseAuthenticateUserResponse(rsp *http.Response) (*AuthenticateUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetCurrentUserResponse{ + response := &AuthenticateUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52084,41 +39977,22 @@ func ParseGetCurrentUserResponse(rsp *http.Response) (*GetCurrentUserResponse, e switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - CreatedAt *time.Time `json:"created_at,omitempty"` - Email string `json:"email"` - EventIdentifiers *map[string]interface{} `json:"event_identifiers,omitempty"` - GroupIdentifier *string `json:"group_identifier,omitempty"` - - // ID ID of the User - ID openapi_types.UUID `json:"id"` - LastLoginAt *time.Time `json:"last_login_at,omitempty"` - - // Name The unique name for the user. - Name *UserName `json:"name,omitempty"` - - // ProfileImageURL Profile image URL of user - ProfileImageURL *string `json:"profile_image_url,omitempty"` - - // RegisteredTeamInternal Whether the team is internal or not - RegisteredTeamInternal *bool `json:"registered_team_internal,omitempty"` - - // RegisteredTeamName The name of the team that the platform is registered with - RegisteredTeamName *string `json:"registered_team_name,omitempty"` - UpdatedAt *time.Time `json:"updated_at,omitempty"` + IDToken string `json:"id_token"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest struct { - Message string `json:"message"` - - // PasswordResetRequired Whether the user needs to reset their password - PasswordResetRequired *bool `json:"password_reset_required,omitempty"` - Status int `json:"status"` + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -52131,6 +40005,34 @@ func ParseGetCurrentUserResponse(rsp *http.Response) (*GetCurrentUserResponse, e } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: + var dest MethodNotAllowed + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON405 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52143,27 +40045,20 @@ func ParseGetCurrentUserResponse(rsp *http.Response) (*GetCurrentUserResponse, e return response, nil } -// ParseUpdateCurrentUserResponse parses an HTTP response from a UpdateCurrentUserWithResponse call -func ParseUpdateCurrentUserResponse(rsp *http.Response) (*UpdateCurrentUserResponse, error) { +// ParseChangeUserPasswordResponse parses an HTTP response from a ChangeUserPasswordWithResponse call +func ParseChangeUserPasswordResponse(rsp *http.Response) (*ChangeUserPasswordResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateCurrentUserResponse{ + response := &ChangeUserPasswordResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest User - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52185,6 +40080,13 @@ func ParseUpdateCurrentUserResponse(rsp *http.Response) (*UpdateCurrentUserRespo } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: var dest MethodNotAllowed if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52192,6 +40094,13 @@ func ParseUpdateCurrentUserResponse(rsp *http.Response) (*UpdateCurrentUserRespo } response.JSON405 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52204,15 +40113,15 @@ func ParseUpdateCurrentUserResponse(rsp *http.Response) (*UpdateCurrentUserRespo return response, nil } -// ParseSendAnonymousEventResponse parses an HTTP response from a SendAnonymousEventWithResponse call -func ParseSendAnonymousEventResponse(rsp *http.Response) (*SendAnonymousEventResponse, error) { +// ParseUpdateCustomerResponse parses an HTTP response from a UpdateCustomerWithResponse call +func ParseUpdateCustomerResponse(rsp *http.Response) (*UpdateCustomerResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SendAnonymousEventResponse{ + response := &UpdateCustomerResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52225,6 +40134,13 @@ func ParseSendAnonymousEventResponse(rsp *http.Response) (*SendAnonymousEventRes } response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52232,12 +40148,12 @@ func ParseSendAnonymousEventResponse(rsp *http.Response) (*SendAnonymousEventRes } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -52251,29 +40167,20 @@ func ParseSendAnonymousEventResponse(rsp *http.Response) (*SendAnonymousEventRes return response, nil } -// ParseAuthenticateLocalUserResponse parses an HTTP response from a AuthenticateLocalUserWithResponse call -func ParseAuthenticateLocalUserResponse(rsp *http.Response) (*AuthenticateLocalUserResponse, error) { +// ParseSendUserEventResponse parses an HTTP response from a SendUserEventWithResponse call +func ParseSendUserEventResponse(rsp *http.Response) (*SendUserEventResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &AuthenticateLocalUserResponse{ + response := &SendUserEventResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - IDToken string `json:"id_token"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52288,13 +40195,6 @@ func ParseAuthenticateLocalUserResponse(rsp *http.Response) (*AuthenticateLocalU } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52302,13 +40202,6 @@ func ParseAuthenticateLocalUserResponse(rsp *http.Response) (*AuthenticateLocalU } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON405 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52316,13 +40209,6 @@ func ParseAuthenticateLocalUserResponse(rsp *http.Response) (*AuthenticateLocalU } response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52335,15 +40221,15 @@ func ParseAuthenticateLocalUserResponse(rsp *http.Response) (*AuthenticateLocalU return response, nil } -// ParseChangeLocalUserPasswordResponse parses an HTTP response from a ChangeLocalUserPasswordWithResponse call -func ParseChangeLocalUserPasswordResponse(rsp *http.Response) (*ChangeLocalUserPasswordResponse, error) { +// ParseLogoutUserResponse parses an HTTP response from a LogoutUserWithResponse call +func ParseLogoutUserResponse(rsp *http.Response) (*LogoutUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ChangeLocalUserPasswordResponse{ + response := &LogoutUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52384,13 +40270,6 @@ func ParseChangeLocalUserPasswordResponse(rsp *http.Response) (*ChangeLocalUserP } response.JSON405 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52403,15 +40282,15 @@ func ParseChangeLocalUserPasswordResponse(rsp *http.Response) (*ChangeLocalUserP return response, nil } -// ParseUpdateCustomerResponse parses an HTTP response from a UpdateCustomerWithResponse call -func ParseUpdateCustomerResponse(rsp *http.Response) (*UpdateCustomerResponse, error) { +// ParseLoginUserResponse parses an HTTP response from a LoginUserWithResponse call +func ParseLoginUserResponse(rsp *http.Response) (*LoginUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateCustomerResponse{ + response := &LoginUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52431,6 +40310,13 @@ func ParseUpdateCustomerResponse(rsp *http.Response) (*UpdateCustomerResponse, e } response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52438,6 +40324,13 @@ func ParseUpdateCustomerResponse(rsp *http.Response) (*UpdateCustomerResponse, e } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: + var dest MethodNotAllowed + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON405 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52450,15 +40343,15 @@ func ParseUpdateCustomerResponse(rsp *http.Response) (*UpdateCustomerResponse, e return response, nil } -// ParseSendUserEventResponse parses an HTTP response from a SendUserEventWithResponse call -func ParseSendUserEventResponse(rsp *http.Response) (*SendUserEventResponse, error) { +// ParseUserTOTPDeleteResponse parses an HTTP response from a UserTOTPDeleteWithResponse call +func ParseUserTOTPDeleteResponse(rsp *http.Response) (*UserTOTPDeleteResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SendUserEventResponse{ + response := &UserTOTPDeleteResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52478,55 +40371,26 @@ func ParseSendUserEventResponse(rsp *http.Response) (*SendUserEventResponse, err } response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseListCurrentUserInvitationsResponse parses an HTTP response from a ListCurrentUserInvitationsWithResponse call -func ParseListCurrentUserInvitationsResponse(rsp *http.Response) (*ListCurrentUserInvitationsResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &ListCurrentUserInvitationsResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } + response.JSON403 = &dest - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []InvitationWithToken `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: + var dest MethodNotAllowed if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON404 = &dest + response.JSON405 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -52540,67 +40404,30 @@ func ParseListCurrentUserInvitationsResponse(rsp *http.Response) (*ListCurrentUs return response, nil } -// ParseGetCurrentLocalUserResponse parses an HTTP response from a GetCurrentLocalUserWithResponse call -func ParseGetCurrentLocalUserResponse(rsp *http.Response) (*GetCurrentLocalUserResponse, error) { +// ParseUserTOTPSetupResponse parses an HTTP response from a UserTOTPSetupWithResponse call +func ParseUserTOTPSetupResponse(rsp *http.Response) (*UserTOTPSetupResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetCurrentLocalUserResponse{ + response := &UserTOTPSetupResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest LocalUserWithTeams - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err + var dest struct { + Secret string `json:"secret"` + Url string `json:"url"` } - response.JSON403 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseLogoutUserResponse parses an HTTP response from a LogoutUserWithResponse call -func ParseLogoutUserResponse(rsp *http.Response) (*LogoutUserResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &LogoutUserResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } + response.JSON200 = &dest - switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52636,6 +40463,13 @@ func ParseLogoutUserResponse(rsp *http.Response) (*LogoutUserResponse, error) { } response.JSON405 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52648,15 +40482,15 @@ func ParseLogoutUserResponse(rsp *http.Response) (*LogoutUserResponse, error) { return response, nil } -// ParseLoginUserResponse parses an HTTP response from a LoginUserWithResponse call -func ParseLoginUserResponse(rsp *http.Response) (*LoginUserResponse, error) { +// ParseUserTOTPVerifyResponse parses an HTTP response from a UserTOTPVerifyWithResponse call +func ParseUserTOTPVerifyResponse(rsp *http.Response) (*UserTOTPVerifyResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &LoginUserResponse{ + response := &UserTOTPVerifyResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52697,6 +40531,20 @@ func ParseLoginUserResponse(rsp *http.Response) (*LoginUserResponse, error) { } response.JSON405 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52709,15 +40557,15 @@ func ParseLoginUserResponse(rsp *http.Response) (*LoginUserResponse, error) { return response, nil } -// ParseGetCurrentUserMembershipsResponse parses an HTTP response from a GetCurrentUserMembershipsWithResponse call -func ParseGetCurrentUserMembershipsResponse(rsp *http.Response) (*GetCurrentUserMembershipsResponse, error) { +// ParseListUsersResponse parses an HTTP response from a ListUsersWithResponse call +func ParseListUsersResponse(rsp *http.Response) (*ListUsersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetCurrentUserMembershipsResponse{ + response := &ListUsersResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52725,14 +40573,21 @@ func ParseGetCurrentUserMembershipsResponse(rsp *http.Response) (*GetCurrentUser switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - Items []MembershipWithTeam `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []User `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52747,6 +40602,13 @@ func ParseGetCurrentUserMembershipsResponse(rsp *http.Response) (*GetCurrentUser } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52759,20 +40621,27 @@ func ParseGetCurrentUserMembershipsResponse(rsp *http.Response) (*GetCurrentUser return response, nil } -// ParseResetLocalUserPasswordResponse parses an HTTP response from a ResetLocalUserPasswordWithResponse call -func ParseResetLocalUserPasswordResponse(rsp *http.Response) (*ResetLocalUserPasswordResponse, error) { +// ParseAddUserResponse parses an HTTP response from a AddUserWithResponse call +func ParseAddUserResponse(rsp *http.Response) (*AddUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ResetLocalUserPasswordResponse{ + response := &AddUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest User + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -52827,65 +40696,15 @@ func ParseResetLocalUserPasswordResponse(rsp *http.Response) (*ResetLocalUserPas return response, nil } -// ParseCreateUserTokenResponse parses an HTTP response from a CreateUserTokenWithResponse call -func ParseCreateUserTokenResponse(rsp *http.Response) (*CreateUserTokenResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &CreateUserTokenResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } - - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest struct { - // CustomToken Token to exchange for refresh token - CustomToken string `json:"custom_token"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON400 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON401 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON500 = &dest - - } - - return response, nil -} - -// ParseUserTOTPDeleteResponse parses an HTTP response from a UserTOTPDeleteWithResponse call -func ParseUserTOTPDeleteResponse(rsp *http.Response) (*UserTOTPDeleteResponse, error) { +// ParseDeleteUserResponse parses an HTTP response from a DeleteUserWithResponse call +func ParseDeleteUserResponse(rsp *http.Response) (*DeleteUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UserTOTPDeleteResponse{ + response := &DeleteUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -52919,12 +40738,12 @@ func ParseUserTOTPDeleteResponse(rsp *http.Response) (*UserTOTPDeleteResponse, e } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON405 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -52938,25 +40757,22 @@ func ParseUserTOTPDeleteResponse(rsp *http.Response) (*UserTOTPDeleteResponse, e return response, nil } -// ParseUserTOTPSetupResponse parses an HTTP response from a UserTOTPSetupWithResponse call -func ParseUserTOTPSetupResponse(rsp *http.Response) (*UserTOTPSetupResponse, error) { +// ParseGetUserResponse parses an HTTP response from a GetUserWithResponse call +func ParseGetUserResponse(rsp *http.Response) (*GetUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UserTOTPSetupResponse{ + response := &GetUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Secret string `json:"secret"` - Url string `json:"url"` - } + var dest User if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -52990,13 +40806,6 @@ func ParseUserTOTPSetupResponse(rsp *http.Response) (*UserTOTPSetupResponse, err } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON405 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -53016,20 +40825,27 @@ func ParseUserTOTPSetupResponse(rsp *http.Response) (*UserTOTPSetupResponse, err return response, nil } -// ParseUserTOTPVerifyResponse parses an HTTP response from a UserTOTPVerifyWithResponse call -func ParseUserTOTPVerifyResponse(rsp *http.Response) (*UserTOTPVerifyResponse, error) { +// ParseUpdateUserResponse parses an HTTP response from a UpdateUserWithResponse call +func ParseUpdateUserResponse(rsp *http.Response) (*UpdateUserResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UserTOTPVerifyResponse{ + response := &UpdateUserResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest User + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -53058,13 +40874,6 @@ func ParseUserTOTPVerifyResponse(rsp *http.Response) (*UserTOTPVerifyResponse, e } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: - var dest MethodNotAllowed - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON405 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -53072,13 +40881,6 @@ func ParseUserTOTPVerifyResponse(rsp *http.Response) (*UserTOTPVerifyResponse, e } response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON429 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -53091,15 +40893,15 @@ func ParseUserTOTPVerifyResponse(rsp *http.Response) (*UserTOTPVerifyResponse, e return response, nil } -// ParseDeleteUserResponse parses an HTTP response from a DeleteUserWithResponse call -func ParseDeleteUserResponse(rsp *http.Response) (*DeleteUserResponse, error) { +// ParseDeleteUserTOTPResponse parses an HTTP response from a DeleteUserTOTPWithResponse call +func ParseDeleteUserTOTPResponse(rsp *http.Response) (*DeleteUserTOTPResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteUserResponse{ + response := &DeleteUserTOTPResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -53133,12 +40935,12 @@ func ParseDeleteUserResponse(rsp *http.Response) (*DeleteUserResponse, error) { } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 405: + var dest MethodNotAllowed if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON405 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError diff --git a/spec.json b/spec.json index 66e7bd2..30c635b 100644 --- a/spec.json +++ b/spec.json @@ -58,6 +58,9 @@ { "name": "images" }, + { + "name": "notifications" + }, { "name": "plugins" }, @@ -67,9 +70,6 @@ { "name": "queries" }, - { - "name": "registry" - }, { "name": "reports" }, @@ -180,14 +180,6 @@ "format": "uuid" } }, - { - "name": "team_name", - "in": "query", - "description": "Filter by team name", - "schema": { - "type": "string" - } - }, { "name": "event_type", "in": "query", @@ -233,7 +225,7 @@ { "name": "search", "in": "query", - "description": "Search across user name, team name, event type, entity display name, and user IP address", + "description": "Search across user name, event type, entity display name, and user IP address", "schema": { "type": "string" } @@ -394,84 +386,53 @@ "security": [] } }, - "/manage/assetview": { + "/platform-info": { "get": { - "description": "Get assetview status", - "operationId": "AssetViewGetStatus", + "description": "Information about the platform", + "operationId": "GetPlatformInfo", "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { "required": [ - "is_running" + "items" ], "properties": { - "is_running": { - "type": "boolean", - "description": "Whether the assetview is currently running" + "public_ips": { + "type": "array", + "items": { + "type": "string" + } } } } } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "admin" - ] - }, - "post": { - "description": "Trigger assetview run", - "operationId": "AssetViewTrigger", - "responses": { - "201": { - "description": "Triggered new run" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "403": { - "$ref": "#/components/responses/Forbidden" + }, + "description": "Response" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "admin" + "platform" ] } }, - "/manage/assetview/logs": { + "/platform-versions": { "get": { - "description": "List asset view logs", - "operationId": "AssetViewListLogs", + "description": "List platform versions", + "operationId": "ListPlatformVersions", "parameters": [ - { - "$ref": "#/components/parameters/per_page" - }, { "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/assetview_run_type" + "$ref": "#/components/parameters/per_page" } ], "responses": { @@ -485,10 +446,10 @@ ], "properties": { "items": { + "type": "array", "items": { - "$ref": "#/components/schemas/AssetViewRun" - }, - "type": "array" + "$ref": "#/components/schemas/PlatformVersion" + } }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -497,392 +458,295 @@ } } }, - "description": "Created" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Response" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "admin" + "platform" ] } }, - "/manage/auth/saml": { + "/plugins": { "get": { - "description": "Get SAML integration information", - "operationId": "ManageGetSAML", + "description": "List all plugins", + "operationId": "ListPlugins", + "parameters": [ + { + "$ref": "#/components/parameters/plugin_sort_by" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/plugin_include_release_stages" + }, + { + "$ref": "#/components/parameters/plugin_exclude_release_stages" + } + ], "responses": { "200": { - "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SAMLConfig" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "$ref": "#/components/schemas/ListPlugins" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } - } + }, + "description": "Response" }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "admin" + "plugins" ] - }, - "patch": { - "description": "Update SAML integration information", - "operationId": "ManageUpdateSAML", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SAMLConfigUpdate" - } - } + } + }, + "/plugins/{team_name}/{plugin_kind}/{plugin_name}": { + "get": { + "description": "Get details about a given plugin.", + "operationId": "GetPlugin", + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" } - }, + ], "responses": { "200": { - "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SAMLConfig" + "$ref": "#/components/schemas/ListPlugin" } } - } + }, + "description": "Response" }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "admin" + "plugins" ] } }, - "/manage/register-platform": { + "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions": { "get": { - "description": "Get platform registry information", - "operationId": "ManageGetPlatformRegistry", + "description": "List all versions for a given plugin", + "operationId": "ListPluginVersions", + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_sort_by" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/include_drafts" + }, + { + "$ref": "#/components/parameters/include_fips" + }, + { + "$ref": "#/components/parameters/include_prereleases" + }, + { + "$ref": "#/components/parameters/version_filter" + } + ], "responses": { "200": { - "description": "Success", "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, "required": [ - "installation_id" + "items", + "metadata" ], "properties": { - "installation_id": { - "type": "string", - "description": "Installation ID", - "x-go-name": "InstallationID" - }, - "activation_id": { - "type": "string", - "description": "Activation ID", - "format": "uuid", - "x-go-name": "ActivationID" - }, - "team_name": { - "type": "string", - "description": "Name of the team that was activated" - }, - "api_key_last_four": { - "type": "string", - "description": "Last 4 characters of the API key", - "x-go-name": "APIKeyLastFour" - }, - "last_activated_at": { - "type": "string", - "description": "Timestamp of the last activation", - "format": "date-time" - }, - "next_activation_at": { - "type": "string", - "description": "Timestamp of the next activation", - "format": "date-time" - }, - "offline_license_registered_to": { - "type": "string", - "description": "Name the offline license is registered to" + "items": { + "items": { + "$ref": "#/components/schemas/PluginVersionList" + }, + "type": "array" }, - "offline_license_expires_at": { - "type": "string", - "description": "Timestamp of the offline license expiration", - "format": "date-time" + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } - } + }, + "description": "Response" }, "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "admin" + "plugins" ] - }, - "post": { - "description": "Register platform usage by API key", - "operationId": "ManageRegisterPlatform", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "api_key" - ], - "properties": { - "api_key": { - "type": "string", - "description": "Team API key to activate platform with", - "x-go-name": "APIKey", - "minLength": 32 - } - } - } - } + } + }, + "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}": { + "get": { + "description": "Get details about a given plugin version.", + "operationId": "GetPluginVersion", + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_name" } - }, + ], "responses": { "200": { - "description": "Success", "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "team_name" - ], - "properties": { - "team_name": { - "type": "string", - "description": "Name of the team that was activated" - } - } + "$ref": "#/components/schemas/PluginVersionDetails" } } - } + }, + "description": "Response" }, - "205": { - "description": "Activation method is no longer valid", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "error" - ], - "properties": { - "error": { - "type": "string", - "description": "Error message" - }, - "button_text": { - "type": "string", - "description": "Text for the button" - }, - "button_url": { - "type": "string", - "format": "url", - "description": "URL for the button", - "x-go-name": "ButtonURL" - } - } - } - } - } + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - "400": { - "$ref": "#/components/responses/BadRequest" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "admin" + "plugins" ] } }, - "/manage/register-platform/offline": { - "post": { - "description": "Register platform usage by offline license", - "operationId": "ManageRegisterPlatformWithOfflineLicense", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "license" - ], - "properties": { - "license": { - "type": "string", - "format": "byte", - "description": "Offline license" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "registered_to", - "expires_at" - ], - "properties": { - "registered_to": { - "type": "string", - "description": "Name the offline license is registered to" - }, - "expires_at": { - "type": "string", - "description": "Timestamp of the offline license expiration", - "format": "date-time" - } - } - } - } + "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { + "get": { + "description": "Download an asset for a given plugin version and target", + "operationId": "DownloadPluginAsset", + "parameters": [ + { + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" } }, - "400": { - "$ref": "#/components/responses/BadRequest" + { + "$ref": "#/components/parameters/team_name" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "$ref": "#/components/parameters/plugin_kind" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + { + "$ref": "#/components/parameters/plugin_name" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" + { + "$ref": "#/components/parameters/version_name" }, - "500": { - "$ref": "#/components/responses/InternalError" + { + "$ref": "#/components/parameters/target_name" } - }, - "tags": [ - "admin" - ] - } - }, - "/manage/settings": { - "get": { - "description": "Show current platform settings", - "operationId": "GetSettings", + ], "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformSettings" + "$ref": "#/components/schemas/PluginAsset" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "admin" - ] - }, - "patch": { - "description": "Update platform settings", - "operationId": "UpdateSettings", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PlatformSettingsUpdate" - } - } - } - }, - "responses": { - "200": { + "302": { "description": "Response", - "content": { - "application/json": { + "headers": { + "Location": { "schema": { - "$ref": "#/components/schemas/PlatformSettings" + "type": "string" } } } @@ -890,39 +754,48 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "429": { + "$ref": "#/components/responses/TooManyRequests" }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "admin" + "plugins" ] } }, - "/manage/teams": { + "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/tables": { "get": { - "description": "List all teams", - "operationId": "ManageListAllTeams", + "description": "List tables for a given plugin version. This only applies to source plugins.", + "operationId": "ListPluginVersionTables", "parameters": [ { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_name" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" } ], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { @@ -933,7 +806,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/PluginTable" }, "type": "array" }, @@ -943,148 +816,97 @@ } } } - } + }, + "description": "Response" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "teams", - "admin" + "plugins" ] } }, - "/manage/teams/{team_name}": { + "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/tables/{table_name}": { "get": { - "description": "Get a team", - "operationId": "ManageGetTeam", + "description": "Get schema for a given table and plugin version. This only applies to source plugins.", + "operationId": "GetPluginVersionTable", "parameters": [ { "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_name" + }, + { + "in": "path", + "name": "table_name", + "required": true, + "schema": { + "type": "string" + } } ], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/PluginTableDetails" } } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "teams", - "admin" - ] - }, - "delete": { - "description": "Delete a team", - "operationId": "ManageDeleteTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + }, + "description": "Response" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, + "security": [], "tags": [ - "teams", - "admin" + "plugins" ] } }, - "/manage/teams/{team_name}/members": { + "/alerts": { "get": { - "description": "List team members", - "operationId": "ManageListTeamMembers", + "description": "List all alerts", + "operationId": "ListAllAlerts", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/per_page" - }, - { - "name": "user_search", - "description": "Search by user name or email", - "in": "query", - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/alert_states" }, { - "name": "role", - "description": "Search by user role. Only for default roles.", - "in": "query", - "schema": { - "$ref": "#/components/schemas/RBACDefaultRole" - } + "$ref": "#/components/parameters/enabled" }, { - "name": "custom_role_id", - "description": "Search by custom role.", - "in": "query", - "schema": { - "$ref": "#/components/schemas/RBACCustomRoleID" - } + "$ref": "#/components/parameters/query_tags" } ], "responses": { @@ -1100,7 +922,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/MembershipWithUser" + "$ref": "#/components/schemas/AlertDetail" }, "type": "array" }, @@ -1112,9 +934,6 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -1132,113 +951,58 @@ } }, "tags": [ - "teams", - "admin" + "alerts" ] - }, - "put": { - "description": "Add team member", - "operationId": "ManageAddTeamMember", + } + }, + "/alerts/test": { + "post": { + "description": "Test an unsaved alert", + "operationId": "TestUnsavedAlert", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "query", + "name": "query_id", + "required": false, + "description": "ID of the query to fill in the alert", + "schema": { + "$ref": "#/components/schemas/QueryID" + }, + "x-go-name": "QueryID" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "user_id" - ], - "properties": { - "user_id": { - "description": "ID of the User", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "UserID" - }, - "roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACDefaultRole" - } - }, - "custom_roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACCustomRoleID" - } - } - } + "$ref": "#/components/schemas/AlertCreate" } } } }, "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "teams", - "admin" - ] - }, - "delete": { - "description": "Remove team member", - "operationId": "ManageRemoveTeamMember", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "user_id" - ], - "properties": { - "user_id": { - "description": "ID of the User", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "UserID" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "results" + ], + "properties": { + "results": { + "type": "array", + "description": "Notification results for the test alert", + "items": { + "$ref": "#/components/schemas/AlertTestResponse" + } + } } } } } - } - }, - "responses": { - "204": { - "description": "Success" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -1260,21 +1024,101 @@ } }, "tags": [ - "teams", - "admin" + "alerts" ] } }, - "/manage/users": { + "/policies": { "get": { - "description": "List all users", - "operationId": "ListLocalUsers", + "description": "List all policies for a team", + "operationId": "ListPolicies", "parameters": [ { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/policy_status" + }, + { + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (policy matches any)" + }, + { + "in": "query", + "name": "domain", + "required": false, + "schema": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "description": "Filter by domain" + }, + { + "in": "query", + "name": "policy_group_ids", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupID" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy groups (policy matches any)" + }, + { + "in": "query", + "name": "search", + "required": false, + "schema": { + "type": "string" + }, + "description": "Search in policy name and description" + }, + { + "in": "query", + "name": "sort_by", + "required": false, + "schema": { + "type": "string", + "enum": [ + "name", + "domain", + "severity", + "violation_count", + "last_run_at", + "created_at" + ], + "default": "created_at" + }, + "description": "Field to sort by" + }, + { + "in": "query", + "name": "sort_dir", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc" + }, + "description": "Sort direction" } ], "responses": { @@ -1290,7 +1134,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/LocalUser" + "$ref": "#/components/schemas/Policy" }, "type": "array" }, @@ -1308,91 +1152,44 @@ "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users", - "admin" + "policies" ] - } - }, - "/manage/users/add": { + }, "post": { - "description": "Add new user", - "operationId": "AddLocalUser", - "parameters": [], + "description": "Create a new policy", + "operationId": "CreatePolicy", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "name", - "roles" - ], - "properties": { - "email": { - "type": "string" - }, - "name": { - "type": "string" - }, - "password": { - "type": "string" - }, - "roles": { - "description": "Global roles for the user", - "type": "array", - "minItems": 0, - "items": { - "type": "string", - "enum": [ - "admin:write", - "admin:read" - ] - } - } - } + "$ref": "#/components/schemas/PolicyCreate" } } } }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/LocalUser" + "$ref": "#/components/schemas/Policy" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -1401,33 +1198,29 @@ } }, "tags": [ - "users", - "admin" + "policies" ] } }, - "/manage/users/{user_id}": { + "/policies/{policy_id}": { "get": { - "description": "Get user details", - "operationId": "GetLocalUser", + "description": "Get a policy by ID", + "operationId": "GetPolicy", "parameters": [ { - "$ref": "#/components/parameters/user_id" + "$ref": "#/components/parameters/policy_id" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/LocalUserWithTeams" + "$ref": "#/components/schemas/Policy" } } - }, - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -1438,57 +1231,27 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users", - "admin" + "policies" ] }, - "patch": { - "description": "Update user", - "operationId": "UpdateLocalUser", + "put": { + "description": "Update a policy", + "operationId": "UpdatePolicy", "parameters": [ { - "$ref": "#/components/parameters/user_id" + "$ref": "#/components/parameters/policy_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "email": { - "type": "string" - }, - "name": { - "type": "string" - }, - "password": { - "type": "string" - }, - "enabled": { - "type": "boolean" - }, - "roles": { - "description": "Global roles for the user", - "type": "array", - "items": { - "type": "string", - "enum": [ - "admin:write", - "admin:read" - ] - } - } - } + "$ref": "#/components/schemas/PolicyUpdate" } } } @@ -1499,7 +1262,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/LocalUser" + "$ref": "#/components/schemas/Policy" } } } @@ -1524,24 +1287,20 @@ } }, "tags": [ - "users", - "admin" + "policies" ] }, "delete": { - "description": "Delete user", - "operationId": "DeleteLocalUser", + "description": "Delete a policy", + "operationId": "DeletePolicy", "parameters": [ { - "$ref": "#/components/parameters/user_id" + "$ref": "#/components/parameters/policy_id" } ], "responses": { "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -1560,41 +1319,29 @@ } }, "tags": [ - "users", - "admin" + "policies" ] } }, - "/manage/users/{user_id}/reset": { + "/policies/{policy_id}/toggle": { "post": { - "description": "Create password reset token for user", - "operationId": "CreateLocalUserResetToken", + "description": "Toggle a policy's status (active/paused)", + "operationId": "TogglePolicy", "parameters": [ { - "$ref": "#/components/parameters/user_id" + "$ref": "#/components/parameters/policy_id" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "reset_token" - ], - "properties": { - "reset_token": { - "type": "string" - } - } + "$ref": "#/components/schemas/Policy" } } - }, - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -1613,54 +1360,37 @@ } }, "tags": [ - "users", - "admin" + "policies" ] } }, - "/manage/users/{user_id}/totp": { - "delete": { - "description": "Disable/Reset MFA for a specific user", - "operationId": "ManageUserTOTPDelete", + "/policies/{policy_id}/violations": { + "get": { + "description": "Get violations for a policy", + "operationId": "GetPolicyViolations", "parameters": [ { - "$ref": "#/components/parameters/user_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" + "$ref": "#/components/parameters/policy_id" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "$ref": "#/components/parameters/page" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + { + "$ref": "#/components/parameters/per_page" }, - "500": { - "$ref": "#/components/responses/InternalError" + { + "name": "search", + "in": "query", + "description": "Text search term to filter violations by resource_type_label, name, account_name, cloud, or region", + "required": false, + "schema": { + "type": "string" + } } - }, - "tags": [ - "users" - ] - } - }, - "/platform-info": { - "get": { - "description": "Information about the platform", - "operationId": "GetPlatformInfo", + ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { @@ -1668,44 +1398,74 @@ "items" ], "properties": { - "public_ips": { - "type": "array", + "items": { "items": { - "type": "string" - } + "$ref": "#/components/schemas/PolicyViolation" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } - }, - "description": "Response" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "platform" + "policies" ] } }, - "/platform-versions": { + "/policies/{policy_id}/violations-history": { "get": { - "description": "List platform versions", - "operationId": "ListPlatformVersions", + "description": "Get violation history for a policy", + "operationId": "GetPolicyViolationsHistory", "parameters": [ { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/policy_id" }, { "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "in": "query", + "name": "start_time", + "required": false, + "schema": { + "type": "string", + "format": "date-time" + } + }, + { + "in": "query", + "name": "end_time", + "required": false, + "schema": { + "type": "string", + "format": "date-time" + } } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { @@ -1715,10 +1475,10 @@ ], "properties": { "items": { - "type": "array", "items": { - "$ref": "#/components/schemas/PlatformVersion" - } + "$ref": "#/components/schemas/PolicyEvaluationLog" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -1726,234 +1486,427 @@ } } } - }, - "description": "Response" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "platform" + "policies" ] } }, - "/plugins": { + "/policies/metrics": { "get": { - "description": "List all plugins", - "operationId": "ListPlugins", + "description": "Get policy metrics summary", + "operationId": "GetPolicyMetrics", "parameters": [ { - "$ref": "#/components/parameters/plugin_sort_by" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (policy matches any)" }, { - "$ref": "#/components/parameters/plugin_include_release_stages" + "in": "query", + "name": "domain", + "required": false, + "schema": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "description": "Filter by domain" }, { - "$ref": "#/components/parameters/plugin_exclude_release_stages" + "in": "query", + "name": "policy_group_ids", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupID" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy groups (policy matches any)" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "$ref": "#/components/schemas/ListPlugins" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/PolicyMetrics" } } - }, - "description": "Response" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "policies" ] - }, - "post": { - "description": "Create a plugin owned by the specified team. User must be part of that team.", - "operationId": "CreatePlugin", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PluginCreate" + } + }, + "/policies/violations-by-domain": { + "get": { + "description": "Get violations grouped by domain", + "operationId": "GetViolationsByDomain", + "parameters": [ + { + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" } - } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (policy matches any)" + }, + { + "in": "query", + "name": "domain", + "required": false, + "schema": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "description": "Filter by domain" + }, + { + "in": "query", + "name": "policy_group_ids", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupID" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy groups (policy matches any)" } - }, + ], "responses": { - "201": { + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Plugin" + "$ref": "#/components/schemas/ViolationsByDomain" } } - }, - "description": "Created" + } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "plugins" + "policies" ] } }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}": { + "/policies/violations-history": { "get": { - "description": "Get details about a given plugin.", - "operationId": "GetPlugin", + "description": "Get violations history over time", + "operationId": "GetViolationsHistory", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "query", + "name": "start_date", + "required": false, + "schema": { + "type": "string", + "format": "date" + }, + "description": "Start date for the query range (YYYY-MM-DD)" }, { - "$ref": "#/components/parameters/plugin_kind" + "in": "query", + "name": "end_date", + "required": false, + "schema": { + "type": "string", + "format": "date" + }, + "description": "End date for the query range (YYYY-MM-DD)" }, { - "$ref": "#/components/parameters/plugin_name" + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (policy matches any)" + }, + { + "in": "query", + "name": "domain", + "required": false, + "schema": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "description": "Filter by domain" + }, + { + "in": "query", + "name": "policy_group_ids", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupID" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy groups (policy matches any)" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ListPlugin" + "$ref": "#/components/schemas/ViolationsHistory" } } - }, - "description": "Response" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "404": { - "$ref": "#/components/responses/NotFound" + "403": { + "$ref": "#/components/responses/Forbidden" }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "policies" ] - }, - "patch": { - "description": "Update a plugin", - "operationId": "UpdatePlugin", - "tags": [ - "plugins" - ], + } + }, + "/policy-groups": { + "get": { + "description": "List all policy groups", + "operationId": "ListPolicyGroups", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" + "in": "query", + "name": "search", + "required": false, + "schema": { + "type": "string" + }, + "description": "Search in policy group name and description" }, { - "$ref": "#/components/parameters/plugin_name" + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter to policy groups that contain at least one policy with any of these severities" } ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "items" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupWithCounts" + } + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "policies" + ] + }, + "post": { + "description": "Create a new policy group", + "operationId": "CreatePolicyGroup", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginUpdate" + "$ref": "#/components/schemas/PolicyGroupCreate" } } } }, "responses": { - "200": { - "description": "Updated", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Plugin" + "$ref": "#/components/schemas/PolicyGroup" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "delete": { - "description": "Delete plugin by team and plugin name", - "operationId": "DeletePluginByTeamAndPluginName", + }, + "tags": [ + "policies" + ] + } + }, + "/policy-groups/{policy_group_id}": { + "get": { + "description": "List policies in a policy group", + "operationId": "ListPoliciesInGroup", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/policy_group_id" }, { - "$ref": "#/components/parameters/plugin_kind" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/plugin_name" + "$ref": "#/components/parameters/page" + }, + { + "in": "query", + "name": "sort_by", + "required": false, + "schema": { + "type": "string", + "enum": [ + "name", + "policy_count" + ], + "default": "name" + }, + "description": "Field to sort by" + }, + { + "in": "query", + "name": "sort_dir", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc" + }, + "description": "Sort direction" } ], "responses": { - "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/Policy" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -1969,70 +1922,36 @@ } }, "tags": [ - "plugins" + "policies" ] - } - }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions": { - "get": { - "description": "List all versions for a given plugin", - "operationId": "ListPluginVersions", + }, + "put": { + "description": "Update a policy group", + "operationId": "UpdatePolicyGroup", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_sort_by" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/include_drafts" - }, - { - "$ref": "#/components/parameters/include_fips" - }, - { - "$ref": "#/components/parameters/include_prereleases" - }, - { - "$ref": "#/components/parameters/version_filter" + "$ref": "#/components/parameters/policy_group_id" } ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/PolicyGroupUpdate" + } + } + } + }, "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/PluginVersionList" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/PolicyGroup" } } - }, - "description": "Response" + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -2046,44 +1965,28 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "policies" ] - } - }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}": { - "get": { - "description": "Get details about a given plugin version.", - "operationId": "GetPluginVersion", + }, + "delete": { + "description": "Delete a policy group", + "operationId": "DeletePolicyGroup", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/policy_group_id" } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PluginVersionDetails" - } - } - }, - "description": "Response" + "204": { + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -2098,27 +2001,75 @@ "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "policies" ] - }, - "put": { - "description": "Create a new plugin version, or update a draft version", - "operationId": "CreatePluginVersion", + } + }, + "/apikeys": { + "get": { + "description": "List all API Keys", + "operationId": "ListAPIKeys", + "tags": [ + "api-keys" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/plugin_kind" + "$ref": "#/components/parameters/page" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata", + "allowed_roles" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/APIKey" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + }, + "allowed_roles": { + "description": "List of allowed roles when creating a new API key", + "type": "array", + "items": { + "$ref": "#/components/schemas/Role" + } + } + } + } + } + } }, - { - "$ref": "#/components/parameters/plugin_name" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - { - "$ref": "#/components/parameters/version_name" + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } + } + }, + "post": { + "description": "Create new API Key.", + "operationId": "CreateAPIKey", + "tags": [ + "api-keys" ], "requestBody": { "content": { @@ -2126,51 +2077,22 @@ "schema": { "type": "object", "required": [ - "message", - "protocols", - "supported_targets", - "package_type", - "checksums" + "expires_at", + "name" ], "properties": { - "message": { - "type": "string", - "minLength": 1, - "maxLength": 30000, - "description": "A message describing what's new or changed in this version.\nThis message will be displayed to users in the plugin's changelog.\nSupports limited markdown syntax.\n" - }, - "protocols": { - "$ref": "#/components/schemas/PluginProtocols" + "name": { + "$ref": "#/components/schemas/APIKeyName" }, - "supported_targets": { - "type": "array", - "description": "The targets supported by this plugin version, formatted as _", - "example": [ - "linux_arm64", - "darwin_amd64", - "windows_amd64" - ], - "items": { - "type": "string" - } + "expires_at": { + "type": "string", + "format": "date-time" }, - "checksums": { + "roles": { "type": "array", - "description": "List of SHA-256 checksums for this plugin version, one for each supported target.", "items": { - "type": "string" + "$ref": "#/components/schemas/RoleID" } - }, - "package_type": { - "$ref": "#/components/schemas/PluginPackageType" - }, - "spec_json_schema": { - "$ref": "#/components/schemas/PluginSpecJSONSchema" - }, - "ui_id": { - "type": "string", - "format": "uuid", - "x-go-name": "UIID" } } } @@ -2178,22 +2100,12 @@ } }, "responses": { - "200": { - "description": "Success (the plugin version was updated)", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PluginVersion" - } - } - } - }, "201": { - "description": "Success (the plugin version was created)", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginVersion" + "$ref": "#/components/schemas/APIKey" } } } @@ -2207,47 +2119,71 @@ "403": { "$ref": "#/components/responses/Forbidden" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/apikeys/{apikey_id}": { + "delete": { + "description": "Delete API Key. This will remove any future access by this API Key.", + "operationId": "DeleteAPIKey", "tags": [ - "plugins" - ] - }, - "patch": { - "description": "Update a given plugin version", - "operationId": "UpdatePluginVersion", + "api-keys" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/apikey_id" + } + ], + "responses": { + "204": { + "description": "Deleted" }, - { - "$ref": "#/components/parameters/plugin_kind" + "400": { + "$ref": "#/components/responses/BadRequest" }, - { - "$ref": "#/components/parameters/plugin_name" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - { - "$ref": "#/components/parameters/version_name" + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - ], + } + } + }, + "/conversations": { + "post": { + "operationId": "CreateConversation", + "summary": "Start a new chat conversation", + "description": "Create a new AI chat conversation", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginVersionUpdate" + "$ref": "#/components/schemas/ConversationCreate" } } } }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Conversation created successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginVersion" + "$ref": "#/components/schemas/Conversation" } } } @@ -2258,67 +2194,41 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "404": { - "$ref": "#/components/responses/NotFound" + "429": { + "$ref": "#/components/responses/TooManyRequests" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "plugins" + "chat" ] } }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { + "/conversations/{conversation_id}": { "get": { - "description": "Download an asset for a given plugin version and target", - "operationId": "DownloadPluginAsset", + "operationId": "GetConversation", + "summary": "Retrieve a chat conversation", + "description": "Get details of an existing AI chat conversation. Useful for polling for updates.", "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "$ref": "#/components/parameters/target_name" + "$ref": "#/components/parameters/conversation_id" } ], "responses": { "200": { - "description": "Response", + "description": "Conversation retrieved successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginAsset" + "$ref": "#/components/schemas/Conversation" } } } }, - "302": { - "description": "Response", - "headers": { - "Location": { - "schema": { - "type": "string" - } - } - } + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -2326,90 +2236,100 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "chat" ] }, "post": { - "description": "Get a URL to upload an asset for a given plugin version and target", - "operationId": "UploadPluginAsset", + "operationId": "SendMessage", + "summary": "Add a message to an existing conversation", + "description": "Send a new message to an existing AI chat conversation", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "$ref": "#/components/parameters/target_name" + "$ref": "#/components/parameters/conversation_id" } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ConversationSendMessage" + } + } + } + }, "responses": { "201": { - "description": "Response", + "description": "Message sent successfully", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ReleaseURL" + "$ref": "#/components/schemas/ConversationMessage" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "plugins" + "chat" ] } }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/docs": { + "/custom-columns": { "get": { - "description": "List all documentation pages for a given plugin version", - "operationId": "ListPluginVersionDocs", + "description": "List all custom columns", + "operationId": "ListAllCustomColumns", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/plugin_name" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/custom_columns_sort_bys" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/custom_columns_sort_dirs" }, { - "$ref": "#/components/parameters/per_page" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter columns by name, label, or description." } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { @@ -2420,7 +2340,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/PluginDocsPage" + "$ref": "#/components/schemas/CustomColumn" }, "type": "array" }, @@ -2430,76 +2350,51 @@ } } } - }, - "description": "Response" + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "custom-columns" ] }, - "put": { - "description": "Create or update one or more plugin version docs pages", - "operationId": "CreatePluginVersionDocs", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - } - ], + "post": { + "description": "Save a custom column", + "operationId": "SaveCustomColumn", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "pages" - ], - "properties": { - "pages": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginDocsPageCreate" - } - } - } + "$ref": "#/components/schemas/CustomColumnCreateOrUpdate" } } } }, "responses": { "201": { - "description": "Successfully created or updated", + "description": "Success", "content": { "application/json": { "schema": { - "type": "object", - "properties": { - "names": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginDocsPageName" - } - } - } + "$ref": "#/components/schemas/CustomColumn" } } } @@ -2524,68 +2419,30 @@ } }, "tags": [ - "plugins" + "custom-columns" ] - }, - "post": { - "description": "Replace (override) multiple plugin version docs pages", - "operationId": "ReplacePluginVersionDocs", + } + }, + "/custom-columns/{custom_column_id}": { + "get": { + "description": "Get a custom column", + "operationId": "GetCustomColumn", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/custom_column_id" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "pages" - ], - "properties": { - "pages": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginDocsPageCreate" - } - } - } - } - } - } - }, "responses": { - "201": { - "description": "Successfully created or updated", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "properties": { - "names": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginDocsPageName" - } - } - } + "$ref": "#/components/schemas/CustomColumn" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -2603,49 +2460,36 @@ } }, "tags": [ - "plugins" + "custom-columns" ] }, - "delete": { - "description": "Delete one or more plugin version docs pages.", - "operationId": "DeletePluginVersionDocs", + "patch": { + "description": "Update a custom column", + "operationId": "UpdateCustomColumn", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/custom_column_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "names" - ], - "properties": { - "names": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginDocsPageName" - } - } - } + "$ref": "#/components/schemas/CustomColumnCreateOrUpdate" } } } }, "responses": { - "204": { - "description": "The resource was deleted successfully." + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CustomColumn" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -2667,133 +2511,88 @@ } }, "tags": [ - "plugins" + "custom-columns" ] - } - }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/tables": { - "get": { - "description": "List tables for a given plugin version. This only applies to source plugins.", - "operationId": "ListPluginVersionTables", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "$ref": "#/components/parameters/page" - }, + }, + "delete": { + "description": "Delete a custom column", + "operationId": "DeleteCustomColumn", + "parameters": [ { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/custom_column_id" } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/PluginTable" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - }, - "description": "Response" + "204": { + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "custom-columns" ] - }, - "put": { - "description": "Create or update one or more plugin version tables. This only applies to source plugins, and can only be done if the plugin version is in draft.", - "operationId": "CreatePluginVersionTables", + } + }, + "/filters": { + "get": { + "description": "List Filters", + "operationId": "ListFilters", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/plugin_kind" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/plugin_name" + "$ref": "#/components/parameters/filter_tags" }, { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/filter_name_filter" + }, + { + "$ref": "#/components/parameters/filter_expression_filter" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "tables" - ], - "properties": { - "tables": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginTableCreate" - } - } - } - } - } - } - }, "responses": { - "201": { - "description": "Successfully created or updated", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", + "required": [ + "items", + "metadata" + ], "properties": { - "names": { + "items": { "type": "array", "items": { - "$ref": "#/components/schemas/PluginTableName" + "$ref": "#/components/schemas/Filter" } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -2811,52 +2610,46 @@ } }, "tags": [ - "plugins" + "filters" ] - }, - "delete": { - "description": "Delete one or more plugin version tables.", - "operationId": "DeletePluginVersionTables", + } + }, + "/filters/tags": { + "get": { + "description": "List Filter Tags", + "operationId": "ListFilterTags", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/page" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "names" - ], - "properties": { - "names": { - "type": "array", + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { "items": { - "$ref": "#/components/schemas/PluginTableName" + "type": "array", + "items": { + "$ref": "#/components/schemas/FilterTag" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } - } - }, - "responses": { - "204": { - "description": "The resource was deleted successfully." - }, - "400": { - "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -2875,196 +2668,109 @@ } }, "tags": [ - "plugins" + "filters" ] } }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/tables/{table_name}": { + "/filters/{filter_id}": { "get": { - "description": "Get schema for a given table and plugin version. This only applies to source plugins.", - "operationId": "GetPluginVersionTable", + "description": "Get a table filter by ID", + "operationId": "GetFilterByID", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "in": "path", - "name": "table_name", - "required": true, - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/filter_id" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginTableDetails" + "$ref": "#/components/schemas/Filter" } } - }, - "description": "Response" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, - "security": [], "tags": [ - "plugins" + "filters" ] - } - }, - "/plugins/{team_name}/{plugin_kind}/{plugin_name}/versions/{version_name}/uiassets": { - "post": { - "description": "Get URLs to upload UI assets for a given plugin version", - "operationId": "UploadPluginUIAssets", + }, + "patch": { + "description": "Update a table filter", + "operationId": "UpdateFilter", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/filter_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "assets" - ], - "properties": { - "ui_id": { - "type": "string", - "format": "uuid", - "x-go-name": "UIID" - }, - "assets": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginUIAssetUploadRequest" - } - } - } + "$ref": "#/components/schemas/FilterUpdate" } } } }, "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "ui_id", - "assets" - ], - "properties": { - "ui_id": { - "type": "string", - "description": "ID representing this upload", - "x-go-name": "UIID" - }, - "assets": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginUIAsset" - } - } - } + "$ref": "#/components/schemas/Filter" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, - "409": { - "$ref": "#/components/responses/Conflict" + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "plugins" + "filters" ] }, - "put": { - "description": "Finalize UI asset upload", - "operationId": "FinalizePluginUIAssetUpload", + "delete": { + "description": "Delete a table filter", + "operationId": "DeleteFilter", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" + "$ref": "#/components/parameters/filter_id" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "ui_id" - ], - "properties": { - "ui_id": { - "type": "string", - "description": "ID representing the finished upload", - "x-go-name": "UIID" - } - } - } - } - } - }, "responses": { "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Deleted" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -3072,6 +2778,9 @@ "403": { "$ref": "#/components/responses/Forbidden" }, + "404": { + "$ref": "#/components/responses/NotFound" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -3080,32 +2789,74 @@ } }, "tags": [ - "plugins" + "filters" ] - }, - "delete": { - "description": "Remove UI assets for a given plugin version", - "operationId": "RemovePluginUIAssets", + } + }, + "/notifications": { + "get": { + "description": "List all notifications for triggered, enabled, policy-bound alerts", + "operationId": "ListNotifications", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/plugin_kind" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/plugin_name" + "in": "query", + "name": "severities", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicySeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy severities (policy matches any)" }, { - "$ref": "#/components/parameters/version_name" + "in": "query", + "name": "policy_group_ids", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroupID" + } + }, + "style": "form", + "explode": true, + "description": "Filter by policy groups (policy matches any)" } ], "responses": { - "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/NotificationDetail" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -3113,19 +2864,25 @@ "403": { "$ref": "#/components/responses/Forbidden" }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "plugins" + "notifications" ] } }, - "/teams": { + "/notifications/destinations": { "get": { - "description": "List all teams", - "operationId": "ListTeams", + "description": "List all notification destinations", + "operationId": "ListAllNotificationDestinations", "parameters": [ { "$ref": "#/components/parameters/per_page" @@ -3147,7 +2904,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/NotificationDestinationListItem" }, "type": "array" }, @@ -3168,53 +2925,89 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "teams" + "alerts" ] }, "post": { - "description": "Create a team owned by the current user.", - "operationId": "CreateTeam", - "parameters": [], + "description": "Create notification destination", + "operationId": "CreateNotificationDestination", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "name", - "display_name" - ], - "properties": { - "name": { - "$ref": "#/components/schemas/TeamName" - }, - "display_name": { - "type": "string", - "description": "The team's display name", - "minLength": 1, - "maxLength": 255 - } - } + "$ref": "#/components/schemas/NotificationDestinationCreate" } } } }, "responses": { "201": { + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/NotificationDestination" } } - }, - "description": "Created" + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "alerts" + ] + } + }, + "/notifications/destinations/test": { + "post": { + "description": "Test an unsaved notification destination", + "operationId": "TestUnsavedNotificationDestination", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/NotificationDestinationData" + } + } + } + }, + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/NotificationDestinationTestResponse" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -3225,6 +3018,9 @@ "403": { "$ref": "#/components/responses/Forbidden" }, + "404": { + "$ref": "#/components/responses/NotFound" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -3233,17 +3029,17 @@ } }, "tags": [ - "teams" + "alerts" ] } }, - "/teams/{team_name}": { + "/notifications/destination/{notification_destination_id}": { "get": { - "description": "Get a team by name", - "operationId": "GetTeamByName", + "description": "Get notification destination", + "operationId": "GetNotificationDestination", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/notification_destination_id" } ], "responses": { @@ -3252,14 +3048,11 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/NotificationDestination" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -3269,34 +3062,30 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "teams" + "alerts" ] }, "patch": { - "description": "Update team attributes", - "operationId": "UpdateTeam", + "description": "Update a notification destination", + "operationId": "UpdateNotificationDestination", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/notification_destination_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "display_name": { - "type": "string", - "description": "The team's display name" - } - } + "$ref": "#/components/schemas/NotificationDestinationUpdate" } } } @@ -3307,7 +3096,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/NotificationDestination" } } } @@ -3324,29 +3113,28 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "teams" + "alerts" ] }, "delete": { - "description": "Delete team", - "operationId": "DeleteTeam", + "description": "Delete a notification destination", + "operationId": "DeleteNotificationDestination", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/notification_destination_id" } ], - "x-internal": true, "responses": { "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "No Content" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -3365,29 +3153,23 @@ } }, "tags": [ - "teams" + "alerts" ] } }, - "/teams/{team_name}/alerts": { + "/notifications/destination/{notification_destination_id}/alerts": { "get": { - "description": "List all alerts", - "operationId": "ListAllAlerts", + "description": "Get notification destination alerts", + "operationId": "GetNotificationDestinationAlerts", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/notification_destination_id" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/alert_states" - }, - { - "$ref": "#/components/parameters/enabled" } ], "responses": { @@ -3436,54 +3218,74 @@ ] } }, - "/teams/{team_name}/alerts/test": { + "/notifications/destination/{notification_destination_id}/test": { "post": { - "description": "Test an unsaved alert", - "operationId": "TestUnsavedAlert", + "description": "Test a notification destination", + "operationId": "TestNotificationDestination", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "in": "query", - "name": "query_id", - "required": false, - "description": "ID of the query to fill in the alert", - "schema": { - "$ref": "#/components/schemas/QueryID" - }, - "x-go-name": "QueryID" + "$ref": "#/components/parameters/notification_destination_id" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AlertCreate" + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/NotificationDestinationTestResponse" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "alerts" + ] + } + }, + "/slack": { + "post": { + "description": "Create Slack connection", + "operationId": "CreateSlackConnection", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SlackConnectionCreate" } } } }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "results" - ], - "properties": { - "results": { - "type": "array", - "description": "Notification results for the test alert", - "items": { - "$ref": "#/components/schemas/AlertTestResponse" - } - } - } + "$ref": "#/components/schemas/SlackConnection" } } } @@ -3512,50 +3314,46 @@ ] } }, - "/teams/{team_name}/apikeys": { + "/slack/{id}/channels": { "get": { - "description": "List all team API Keys", - "operationId": "ListTeamAPIKeys", - "tags": [ - "teams" - ], + "description": "List Slack channels for a connection", + "operationId": "ListSlackChannels", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" + "name": "id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "Slack connection ID" }, { - "$ref": "#/components/parameters/page" + "name": "name", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter channels by name (case-insensitive partial match)" } ], "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { + "type": "object", "required": [ - "items", - "metadata", - "allowed_roles" + "items" ], "properties": { "items": { - "items": { - "$ref": "#/components/schemas/APIKey" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - }, - "allowed_roles": { - "description": "List of allowed roles when creating a new API key", "type": "array", "items": { - "$ref": "#/components/schemas/APIKeyTeamRole" + "$ref": "#/components/schemas/SlackChannel" } } } @@ -3566,24 +3364,30 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, + }, + "tags": [ + "alerts" + ] + } + }, + "/onboardings/aws/oidc": { "post": { - "description": "Create new team API Key.", - "operationId": "CreateTeamAPIKey", + "operationId": "CreateAWSOnboarding", + "description": "Create an interactive onboarding for AWS", "tags": [ - "teams" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } + "onboardings" ], "requestBody": { "content": { @@ -3591,22 +3395,12 @@ "schema": { "type": "object", "required": [ - "expires_at", - "name" + "single_account" ], "properties": { - "name": { - "$ref": "#/components/schemas/APIKeyName" - }, - "expires_at": { - "type": "string", - "format": "date-time" - }, - "roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/APIKeyTeamRole" - } + "single_account": { + "type": "boolean", + "description": "Specifies the type of onboarding to create: either a single account onboarding or an organization onboarding\n" } } } @@ -3615,11 +3409,10 @@ }, "responses": { "201": { - "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/APIKey" + "$ref": "#/components/schemas/OnboardingAWSCreateResponse" } } } @@ -3630,107 +3423,30 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/apikeys/{apikey_id}": { - "delete": { - "description": "Delete API Key. This will remove any future access by this API Key.", - "operationId": "DeleteTeamAPIKey", - "tags": [ - "teams" - ], + "/onboardings/aws/oidc/{onboarding_id}": { + "get": { + "operationId": "GetAWSOnboarding", + "description": "Query an interactive onboarding for AWS", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/apikey_id" + "$ref": "#/components/parameters/onboarding_id" } ], - "responses": { - "204": { - "description": "Deleted" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/connectors": { - "get": { - "description": "List all configured connectors", - "operationId": "ListConnectors", "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "in": "query", - "name": "filter_type", - "required": false, - "schema": { - "type": "string" - }, - "description": "Filter connectors by a given type." - }, - { - "in": "query", - "name": "filter_plugin", - "required": false, - "schema": { - "type": "string" - }, - "description": "Filter connectors by a given plugin reference. Mutually exclusive with `type`.", - "example": "cloudquery/source/googleanalytics" - } + "onboardings" ], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/Connector" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/OnboardingAWS" } } } @@ -3748,82 +3464,70 @@ "$ref": "#/components/responses/InternalError" } } - }, + } + }, + "/onboardings/aws/oidc/{onboarding_id}/notify": { "post": { - "description": "Create new connector", - "operationId": "CreateConnector", + "operationId": "NotifyOnboarding", + "description": "Update onboarding state", "tags": [ - "syncs" + "onboardings" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/onboarding_id" } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConnectorCreate" + "$ref": "#/components/schemas/OnboardingAWSNotification" } } } }, "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Connector" - } - } - } - }, + "202": {}, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/connectors/{connector_id}": { + "/onboardings/aws/oidc/{onboarding_id}/accounts": { "get": { - "description": "Get a configured connector", - "operationId": "GetConnector", - "tags": [ - "syncs" - ], + "operationId": "GetAWSAccountsInRoot", + "description": "Query AWS accounts under organization root", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/onboarding_id" } ], + "tags": [ + "onboardings" + ], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Connector" + "$ref": "#/components/schemas/OnboardingAWSAccounts" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" @@ -3832,37 +3536,29 @@ "$ref": "#/components/responses/InternalError" } } - }, - "patch": { - "description": "Update a connector", - "operationId": "UpdateConnector", - "tags": [ - "syncs" - ], + } + }, + "/onboardings/aws/oidc/{onboarding_id}/accounts/{aws_orgunit_id}": { + "get": { + "operationId": "GetAWSAccountsInParent", + "description": "Query AWS accounts under a specifc Organizational Unit", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/onboarding_id" }, { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/aws_orgunit_id" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorUpdate" - } - } - } - }, + "tags": [ + "onboardings" + ], "responses": { "200": { - "description": "Update response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Connector" + "$ref": "#/components/schemas/OnboardingAWSAccounts" } } } @@ -3882,24 +3578,31 @@ } } }, - "/teams/{team_name}/connectors/{connector_id}/authenticate": { - "delete": { - "description": "Revoke authentication for a given connector. Any syncs relying on this connector will stop running until the connector is reauthenticated or sync references are updated.", - "operationId": "RevokeConnector", + "/onboardings/aws/oidc/{onboarding_id}/accounts/provision": { + "post": { + "operationId": "ProvisionOnboardingConfiguration", + "description": "Provision onboarding configuration into the cloud account", "tags": [ - "syncs" + "onboardings" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/onboarding_id" } ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/OnboardingAWSProvision" + } + } + } + }, "responses": { - "204": { - "description": "Deleted" + "202": {}, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -3916,19 +3619,34 @@ } } }, - "/teams/{team_name}/connectors/{connector_id}/authenticate/aws": { + "/queries": { "get": { - "description": "Get authentication status for the given AWS connector", - "operationId": "GetConnectorAuthStatusAWS", - "tags": [ - "syncs" - ], + "description": "List all queries", + "operationId": "ListAllQueries", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/query_tags" }, { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/query_name_filter" + }, + { + "$ref": "#/components/parameters/query_filter" + }, + { + "$ref": "#/components/parameters/alert_configured" + }, + { + "$ref": "#/components/parameters/alert_message_filter" + }, + { + "$ref": "#/components/parameters/alert_enabled" } ], "responses": { @@ -3937,28 +3655,31 @@ "content": { "application/json": { "schema": { + "required": [ + "items", + "metadata" + ], "properties": { - "role_arn": { - "type": "string", - "description": "ARN of role created by the user", - "x-go-name": "RoleARN" + "items": { + "items": { + "$ref": "#/components/schemas/Query" + }, + "type": "array" }, - "external_id": { - "type": "string", - "description": "External ID used for the role", - "x-go-name": "ExternalID" + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -3968,20 +3689,43 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "post": { - "description": "Authenticate or reauthenticate the given AWS connector", - "operationId": "AuthenticateConnectorAWS", + }, "tags": [ - "syncs" - ], + "queries" + ] + } + }, + "/queries/execute": { + "post": { + "description": "Run an ad-hoc SQL query against any table.\nFurther filtering can optionally be applied on top of the raw SQL results using the optional parameters. Filtering can be useful in situations where a saved query needs to be further filtered, grouped or paginated, such as in dashboards or reports.\n", + "operationId": "ExecuteAdHocQuery", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_selects" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/table_filter_ids" + }, + { + "$ref": "#/components/parameters/table_sort_bys" + }, + { + "$ref": "#/components/parameters/table_sort_dirs" + }, + { + "$ref": "#/components/parameters/table_group_bys" }, { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" } ], "requestBody": { @@ -3989,7 +3733,17 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConnectorAuthRequestAWS" + "type": "object", + "additionalProperties": false, + "required": [ + "query" + ], + "properties": { + "query": { + "type": "string", + "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" + } + } } } } @@ -4000,7 +3754,18 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConnectorAuthResponseAWS" + "required": [ + "data", + "metadata" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/TableData" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -4011,6 +3776,9 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -4020,38 +3788,36 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Complete authentication for the given AWS connector", - "operationId": "AuthenticateConnectorFinishAWS", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" - } - ], + "queries" + ] + } + }, + "/queries/save": { + "post": { + "description": "Save a query to execute later", + "operationId": "SaveQuery", "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConnectorAuthFinishRequestAWS" + "$ref": "#/components/schemas/QueryCreate" } } } }, "responses": { - "204": { - "description": "Authentication is complete." - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "201": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/QueryDetail" + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -4068,22 +3834,22 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "queries" + ] } }, - "/teams/{team_name}/connectors/{connector_id}/authenticate/gcp": { + "/queries/tags": { "get": { - "description": "Get authentication status for the given GCP connector", - "operationId": "GetConnectorAuthStatusGCP", - "tags": [ - "syncs" - ], + "description": "List Query Tags", + "operationId": "ListQueryTags", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/page" } ], "responses": { @@ -4092,22 +3858,31 @@ "content": { "application/json": { "schema": { + "required": [ + "items", + "metadata" + ], "properties": { - "service_account": { - "type": "string", - "description": "CloudQuery GCP Service Account to grant access to" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryTag" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -4117,49 +3892,38 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "post": { - "description": "Authenticate or reauthenticate the given GCP connector", - "operationId": "AuthenticateConnectorGCP", + }, "tags": [ - "syncs" - ], + "queries" + ] + } + }, + "/queries/{query_id}": { + "get": { + "description": "Get a saved query", + "operationId": "GetSavedQuery", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/query_id" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorAuthRequestGCP" - } - } - } - }, "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConnectorAuthResponseGCP" + "$ref": "#/components/schemas/QueryDetail" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -4169,27 +3933,38 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/connectors/{connector_id}/authenticate/gcp/finish": { - "post": { - "description": "Complete authentication for the given GCP connector", - "operationId": "AuthenticateConnectorFinishGCP", + }, "tags": [ - "syncs" - ], + "queries" + ] + }, + "patch": { + "description": "Update a saved query", + "operationId": "UpdateQuery", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/query_id" } ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/QueryUpdate" + } + } + } + }, "responses": { - "204": { - "description": "Authentication is complete." + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/QueryDetail" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -4209,51 +3984,29 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/connectors/{connector_id}/authenticate/oauth": { - "post": { - "description": "Authenticate or reauthenticate the given OAuth connector", - "operationId": "AuthenticateConnectorOAuth", + }, "tags": [ - "syncs" - ], + "queries" + ] + }, + "delete": { + "description": "Delete a saved query", + "operationId": "DeleteSavedQuery", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/query_id" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorAuthRequestOAuth" - } - } - } - }, "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorAuthResponseOAuth" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "204": { + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -4263,48 +4016,24 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Complete authentication for the given OAuth connector", - "operationId": "AuthenticateConnectorFinishOAuth", + }, "tags": [ - "syncs" - ], + "queries" + ] + } + }, + "/queries/{query_id}/alert": { + "delete": { + "description": "Delete an alert associated with a saved query", + "operationId": "DeleteAlert", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/connector_id" + "$ref": "#/components/parameters/query_id" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorAuthFinishRequestOAuth" - } - } - } - }, "responses": { - "200": { - "description": "First part of authentication is complete, follow redirect to continue", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConnectorAuthResponseOAuth" - } - } - } - }, "204": { - "description": "Authentication is complete." - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -4321,41 +4050,66 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "alerts" + ] } }, - "/teams/{team_name}/conversations": { + "/queries/{query_id}/execute": { "post": { - "operationId": "CreateConversation", - "summary": "Start a new chat conversation", - "description": "Create a new AI chat conversation. Note that this endpoint does not currently support API key authentication.", + "description": "Execute a saved query", + "operationId": "ExecuteSavedQuery", "parameters": [ { - "$ref": "#/components/parameters/team_name" - } - ], - "security": [ + "$ref": "#/components/parameters/query_id" + }, + { + "$ref": "#/components/parameters/table_selects" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/table_filter_ids" + }, + { + "$ref": "#/components/parameters/table_sort_bys" + }, + { + "$ref": "#/components/parameters/table_sort_dirs" + }, + { + "$ref": "#/components/parameters/table_group_bys" + }, + { + "$ref": "#/components/parameters/per_page" + }, { - "cookieAuth": [] + "$ref": "#/components/parameters/page" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ConversationCreate" - } - } - } - }, "responses": { - "201": { - "description": "Conversation created successfully", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Conversation" + "required": [ + "data", + "metadata" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/TableData" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -4366,43 +4120,63 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "chat" + "queries" ] } }, - "/teams/{team_name}/conversations/{conversation_id}": { + "/queries/{query_id}/filters": { "get": { - "operationId": "GetConversation", - "summary": "Retrieve a chat conversation", - "description": "Get details of an existing AI chat conversation. Useful for polling for updates. Note that this endpoint does not currently support API key authentication.", - "security": [ - { - "cookieAuth": [] - } - ], + "description": "List Query Filters", + "operationId": "QueryListFilters", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/query_id" }, { - "$ref": "#/components/parameters/conversation_id" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/filter_tags" } ], "responses": { "200": { - "description": "Conversation retrieved successfully", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Conversation" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Filter" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -4413,32 +4187,30 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "chat" + "queries", + "filters" ] }, "post": { - "operationId": "SendMessage", - "summary": "Add a message to an existing conversation", - "description": "Send a new message to an existing AI chat conversation. Note that this endpoint does not currently support API key authentication.", + "description": "Save Query Filter", + "operationId": "QuerySaveFilter", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/conversation_id" - } - ], - "security": [ - { - "cookieAuth": [] + "$ref": "#/components/parameters/query_id" } ], "requestBody": { @@ -4446,78 +4218,70 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConversationSendMessage" + "$ref": "#/components/schemas/FilterCreate" } } } }, "responses": { - "201": { - "description": "Message sent successfully", + "200": { + "description": "Filter already exists", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ConversationMessage" + "$ref": "#/components/schemas/Filter" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, + "201": { + "description": "Filter created", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Filter" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "chat" + "queries", + "filters" ] } }, - "/teams/{team_name}/custom-columns": { + "/queries/{query_id}/filters/tags": { "get": { - "description": "List all custom columns", - "operationId": "ListAllCustomColumns", + "description": "List Filter Tags For A Saved Query", + "operationId": "QueryListFilterTags", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/query_id" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/custom_columns_sort_bys" - }, - { - "$ref": "#/components/parameters/custom_columns_sort_dirs" - }, - { - "name": "table", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter columns by table name." - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter columns by name, label, or description." } ], "responses": { @@ -4532,10 +4296,10 @@ ], "properties": { "items": { + "type": "array", "items": { - "$ref": "#/components/schemas/CustomColumn" - }, - "type": "array" + "$ref": "#/components/schemas/FilterTag" + } }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -4545,9 +4309,6 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -4565,34 +4326,119 @@ } }, "tags": [ - "custom-columns" + "queries", + "filters" ] - }, - "post": { - "description": "Save a custom column", - "operationId": "SaveCustomColumn", + } + }, + "/reports": { + "get": { + "operationId": "ListReports", + "description": "List reports", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter reports by title or description." + }, + { + "name": "visibility", + "in": "query", + "schema": { + "type": "string", + "enum": [ + "private", + "public" + ] + } + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/report_sort_bys" + }, + { + "$ref": "#/components/parameters/report_sort_dirs" + } + ], + "responses": { + "200": { + "description": "List of reports.", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "reports", + "metadata" + ], + "properties": { + "reports": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Report" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" } + } + }, + "post": { + "description": "Create Report", + "operationId": "CreateReport", + "tags": [ + "reports" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumnCreateOrUpdate" + "$ref": "#/components/schemas/ReportCreate" } } } }, "responses": { "201": { - "description": "Success", + "description": "Created report.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumn" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/Report" + } + } } } } @@ -4600,198 +4446,196 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "custom-columns" - ] + } } }, - "/teams/{team_name}/custom-columns/{custom_column_id}": { + "/reports/{report_id}": { "get": { - "description": "Get a custom column", - "operationId": "GetCustomColumn", + "description": "Get Report", + "operationId": "GetReport", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/custom_column_id" + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." } ], "responses": { "200": { - "description": "Response", + "description": "Retrieved report.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumn" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/Report" + } + } } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "custom-columns" - ] + } }, - "patch": { - "description": "Update a custom column", - "operationId": "UpdateCustomColumn", + "put": { + "description": "Update Report", + "operationId": "UpdateReport", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/custom_column_id" + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumnCreateOrUpdate" + "$ref": "#/components/schemas/ReportUpdate" } } } }, "responses": { "200": { - "description": "Response", + "description": "Updated report.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumn" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/Report" + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "custom-columns" - ] + } }, "delete": { - "description": "Delete a custom column", - "operationId": "DeleteCustomColumn", + "description": "Delete Report", + "operationId": "DeleteReport", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/custom_column_id" + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." } ], "responses": { "204": { - "description": "Success" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "description": "Report deleted." }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "custom-columns" - ] + } } }, - "/teams/{team_name}/custom-columns/{custom_column_id}/import": { - "put": { - "description": "Import data into a Custom Column", - "operationId": "PutCustomColumnData", + "/reports/templates": { + "get": { + "operationId": "ListReportTemplates", + "description": "List report templates", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter report templates by name." }, { - "$ref": "#/components/parameters/custom_column_id" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/report_templates_sort_bys" + }, + { + "$ref": "#/components/parameters/report_templates_sort_dirs" } ], - "tags": [ - "custom-columns" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CustomColumnDataImport" - } - } - } - }, "responses": { - "202": { - "description": "Accepted import", + "200": { + "description": "List of report templates.", "content": { "application/json": { "schema": { "type": "object", "required": [ - "data" + "templates", + "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/CustomColumnDataImportAccepted" + "templates": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReportTemplate" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } @@ -4801,44 +4645,45 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" } } - } - }, - "/teams/{team_name}/custom-columns/{custom_column_id}/values": { - "put": { - "description": "Edit values within a Custom Column", - "operationId": "PutCustomColumnValues", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/custom_column_id" - } - ], + }, + "post": { + "description": "Create Report Template", + "operationId": "CreateReportTemplate", "tags": [ - "custom-columns" + "reports" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CustomColumnDataValues" + "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" } } } }, "responses": { - "200": { - "description": "Accepted values", + "201": { + "description": "Created report template.", "content": { "application/json": { "schema": { - "type": "object" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/ReportTemplate" + } + } } } } @@ -4846,254 +4691,218 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "403": { + "$ref": "#/components/responses/Forbidden" } } } }, - "/teams/{team_name}/filters": { + "/reports/templates/{template_id}": { "get": { - "description": "List Filters", - "operationId": "ListFiltersTeam", + "description": "Get Report Template", + "operationId": "GetReportTemplate", + "tags": [ + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/filter_tags" - }, - { - "$ref": "#/components/parameters/filter_name_filter" - }, - { - "$ref": "#/components/parameters/filter_expression_filter" + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." } ], "responses": { "200": { - "description": "Response", + "description": "Retrieved report template.", "content": { "application/json": { "schema": { + "type": "object", "required": [ - "items", - "metadata" + "data" ], "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Filter" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "data": { + "$ref": "#/components/schemas/ReportTemplate" } } } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, + } + }, + "put": { + "description": "Update Report Template", + "operationId": "UpdateReportTemplate", "tags": [ - "filters" - ] - } - }, - "/teams/{team_name}/filters/tags": { - "get": { - "description": "List Filter Tags", - "operationId": "ListFilterTagsTeam", + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" + } + } + } + }, "responses": { "200": { - "description": "Response", + "description": "Updated report template.", "content": { "application/json": { "schema": { + "type": "object", "required": [ - "items", - "metadata" + "data" ], "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "data": { + "$ref": "#/components/schemas/ReportTemplate" } } } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, + } + }, + "delete": { + "description": "Delete Report Template", + "operationId": "DeleteReportTemplate", "tags": [ - "filters" - ] - } - }, - "/teams/{team_name}/filters/{filter_id}": { - "get": { - "description": "Get a table filter by ID", - "operationId": "GetFilterByIDTeam", + "reports" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/filter_id" + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." } ], "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "204": { + "description": "Report template deleted." }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/sync-destination-test-connections": { + "post": { + "description": "Create a test destination connection.", + "operationId": "CreateSyncDestinationTestConnection", "tags": [ - "filters" - ] - }, - "patch": { - "description": "Update a table filter", - "operationId": "UpdateFilterTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/filter_id" - } + "syncs" ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/FilterUpdate" + "$ref": "#/components/schemas/SyncDestinationTestConnectionCreate" } } } }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Filter" + "$ref": "#/components/schemas/SyncDestinationTestConnection" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "get": { + "description": "Get a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnection", "tags": [ - "filters" - ] - }, - "delete": { - "description": "Delete a table filter", - "operationId": "DeleteFilterTeam", + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/filter_id" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "responses": { - "204": { - "description": "Deleted" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationTestConnection" + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -5104,43 +4913,43 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + }, + "patch": { + "description": "Update a sync destination test connection.", + "operationId": "UpdateSyncTestConnectionForSyncDestination", "tags": [ - "filters" - ] - } - }, - "/teams/{team_name}/images": { - "post": { - "description": "Get URLs to upload images for a given team", - "operationId": "CreateTeamImages", + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { "type": "object", "required": [ - "images" + "status" ], "properties": { - "images": { - "items": { - "$ref": "#/components/schemas/TeamImageCreate" - }, - "type": "array", - "minItems": 1 + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" + }, + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" } } } @@ -5148,32 +4957,18 @@ } }, "responses": { - "201": { - "description": "Response", + "200": { + "description": "Updated", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/TeamImage" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncDestinationTestConnection" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" }, "403": { "$ref": "#/components/responses/Forbidden" @@ -5181,31 +4976,45 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "teams" - ] + } } }, - "/teams/{team_name}/invitations": { + "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/query": { "get": { - "operationId": "ListTeamInvitations", - "description": "List of open invitations to the team", + "description": "Get logs for a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnectionLogsQuery", "tags": [ - "teams" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_destination_test_connection_id" + }, + { + "$ref": "#/components/parameters/table_filters" }, { "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -5215,64 +5024,82 @@ "application/json": { "schema": { "required": [ - "items", + "data", "metadata" ], "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Invitation" - } + "data": { + "$ref": "#/components/schemas/TableData" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } + }, + "text/plain": { + "schema": { + "type": "string", + "description": "Download file." + } } } }, - "403": { - "$ref": "#/components/responses/Forbidden" + "204": { + "description": "No logs available for a test connection that has not started." + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } } - }, - "delete": { - "operationId": "DeleteTeamInvitation", - "description": "Delete an invitation to the team, preventing the user becoming a team member", + } + }, + "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/live": { + "get": { + "description": "Get live logs for a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnectionLogsLive", "tags": [ - "teams" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } + }, + { + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "email" - ], - "properties": { - "email": { - "type": "string", - "format": "email" - } + "responses": { + "200": { + "description": "Response", + "content": { + "text/plain": { + "schema": { + "type": "string", + "description": "Chunked response logs for a test connection that is in progress." } } } - } - }, - "responses": { + }, "204": { - "description": "Response" + "description": "No logs available for a test connection that has not started." }, "400": { "$ref": "#/components/responses/BadRequest" @@ -5280,72 +5107,72 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/invitations/accept": { + "/sync-destination-test-connections/{sync_destination_test_connection_id}/promote": { "post": { - "operationId": "AcceptTeamInvitation", - "description": "Accept an invitation to the team, creating a user membership", + "description": "Promote a sync destination test connection to a sync destination.", + "operationId": "PromoteSyncDestinationTestConnection", "tags": [ - "teams" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "token" - ], - "properties": { - "token": { - "type": "string", - "format": "uuid" - } - } + "$ref": "#/components/schemas/PromoteSyncDestinationTestConnection" } } } }, "responses": { - "201": { - "description": "The invitation has been accepted and the authenticated user is now a member of the team.", + "200": { + "description": "Successful response indicating that an existing sync destination was replaced.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/MembershipWithTeam" + "$ref": "#/components/schemas/SyncDestination" } } } }, - "303": { - "description": "The authenticated user is already a member of this team.", + "201": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/MembershipWithTeam" + "$ref": "#/components/schemas/SyncDestination" } } } }, - "403": { - "description": "You do not have an invitation to join this team.", - "$ref": "#/components/responses/Forbidden" + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" @@ -5353,23 +5180,33 @@ } } }, - "/teams/{team_name}/memberships": { + "/sync-destinations": { "get": { - "description": "Get memberships to the team.", - "operationId": "GetTeamMemberships", + "description": "List all sync destination definitions.", + "operationId": "ListSyncDestinations", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/sync_generic_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { @@ -5380,23 +5217,9 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/MembershipWithUser" + "$ref": "#/components/schemas/SyncDestination" }, - "type": "array", - "example": [ - { - "roles": [ - "admin:write" - ], - "user": { - "created_at": "2017-07-14T16:53:42Z", - "email": "user@example.com", - "id": "12345678-1234-1234-1234-1234567890ab", - "name": "Sarah O'Connor", - "updated_at": "2017-07-14T16:53:42Z" - } - } - ] + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -5404,8 +5227,7 @@ } } } - }, - "description": "Response" + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -5413,48 +5235,80 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/sync-destinations/{sync_destination_name}": { + "get": { + "description": "Get a single sync destination definition.", + "operationId": "GetSyncDestination", "tags": [ - "teams" - ] + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_destination_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestination" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } }, - "delete": { - "description": "Remove a user from the team", - "operationId": "RemoveTeamMembership", + "patch": { + "description": "Update a Sync Destination definition.", + "operationId": "UpdateSyncDestination", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "email" - ], - "properties": { - "email": { - "type": "string" - } - } + "$ref": "#/components/schemas/SyncDestinationUpdate" } } } }, "responses": { - "204": { - "description": "Response" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestination" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -5462,9 +5316,6 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -5474,38 +5325,26 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "teams" - ] - } - }, - "/teams/{team_name}/memberships/{email}": { + } + }, "delete": { - "deprecated": true, - "description": "Remove a user from the team", - "operationId": "DeleteTeamMembership", + "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", + "operationId": "DeleteSyncDestination", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/email_basic" + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Deleted" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -5515,25 +5354,37 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "teams" - ] + } } }, - "/teams/{team_name}/notifications/destinations": { + "/sync-destinations/{sync_destination_name}/syncs": { "get": { - "description": "List all notification destinations", - "operationId": "ListAllNotificationDestinations", + "description": "List all Syncs for a given sync destination.", + "operationId": "ListSyncDestinationSyncs", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/migration_filter" } ], "responses": { @@ -5549,7 +5400,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/NotificationDestinationListItem" + "$ref": "#/components/schemas/ListSync" }, "type": "array" }, @@ -5561,51 +5412,43 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/sync-destinations/{sync_destination_name}/test-connections/{sync_test_connection_id}": { + "get": { + "description": "Get test connection details for sync destination.", + "operationId": "GetTestConnectionForSyncDestination", "tags": [ - "alerts" - ] - }, - "post": { - "description": "Create notification destination", - "operationId": "CreateNotificationDestination", + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_name" + }, + { + "$ref": "#/components/parameters/sync_test_connection_id" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/NotificationDestinationCreate" - } - } - } - }, "responses": { - "201": { - "description": "Success", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestination" + "$ref": "#/components/schemas/SyncTestConnection" } } } @@ -5616,50 +5459,39 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } } }, - "/teams/{team_name}/notifications/destinations/test": { + "/sync-source-test-connections": { "post": { - "description": "Test an unsaved notification destination", - "operationId": "TestUnsavedNotificationDestination", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } + "description": "Create a test source connection.", + "operationId": "CreateSyncSourceTestConnection", + "tags": [ + "syncs" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestinationData" + "$ref": "#/components/schemas/SyncSourceTestConnectionCreate" } } } }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestinationTestResponse" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -5670,34 +5502,31 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } } }, - "/teams/{team_name}/notifications/destination/{notification_destination_id}": { + "/sync-source-test-connections/{sync_source_test_connection_id}": { "get": { - "description": "Get notification destination", - "operationId": "GetNotificationDestination", + "description": "Get a sync source test connection.", + "operationId": "GetSyncSourceTestConnection", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/notification_destination_id" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "responses": { @@ -5706,7 +5535,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestination" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -5720,44 +5549,56 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } }, "patch": { - "description": "Update a notification destination", - "operationId": "UpdateNotificationDestination", + "description": "Update a sync source test connection.", + "operationId": "UpdateSyncTestConnectionForSyncSource", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/notification_destination_id" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestinationUpdate" + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" + }, + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" + } + } } } } }, "responses": { "200": { - "description": "Response", + "description": "Updated", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/NotificationDestination" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -5765,44 +5606,6 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "alerts" - ] - }, - "delete": { - "description": "Delete a notification destination", - "operationId": "DeleteNotificationDestination", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/notification_destination_id" - } - ], - "responses": { - "204": { - "description": "No Content" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -5815,28 +5618,39 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } } }, - "/teams/{team_name}/notifications/destination/{notification_destination_id}/alerts": { + "/sync-source-test-connections/{sync_source_test_connection_id}/logs/query": { "get": { - "description": "Get notification destination alerts", - "operationId": "GetNotificationDestinationAlerts", + "description": "Get logs for a sync source test connection.", + "operationId": "GetSyncSourceTestConnectionLogsQuery", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/notification_destination_id" + "$ref": "#/components/parameters/sync_source_test_connection_id" + }, + { + "$ref": "#/components/parameters/table_filters" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -5846,30 +5660,36 @@ "application/json": { "schema": { "required": [ - "items", + "data", "metadata" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/AlertDetail" - }, - "type": "array" + "data": { + "$ref": "#/components/schemas/TableData" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } + }, + "text/plain": { + "schema": { + "type": "string", + "description": "Download file." + } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -5879,135 +5699,101 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } } }, - "/teams/{team_name}/notifications/destination/{notification_destination_id}/test": { - "post": { - "description": "Test a notification destination", - "operationId": "TestNotificationDestination", + "/sync-source-test-connections/{sync_source_test_connection_id}/logs/live": { + "get": { + "description": "Get live logs for a sync source test connection.", + "operationId": "GetSyncSourceTestConnectionLogsLive", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/notification_destination_id" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "responses": { "200": { "description": "Response", "content": { - "application/json": { + "text/plain": { "schema": { - "$ref": "#/components/schemas/NotificationDestinationTestResponse" + "type": "string", + "description": "Chunked response logs for a test connection that is in progress." } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "alerts" - ] + } } }, - "/teams/{team_name}/onboardings/aws/oidc": { + "/sync-source-test-connections/{sync_source_test_connection_id}/promote": { "post": { - "operationId": "CreateAWSOnboarding", - "description": "Create an interactive onboarding for AWS", + "description": "Promote a sync source test connection to a sync source.", + "operationId": "PromoteSyncSourceTestConnection", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], - "tags": [ - "teams" - ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "single_account" - ], - "properties": { - "single_account": { - "type": "boolean", - "description": "Specifies the type of onboarding to create: either a single account onboarding or an organization onboarding\n" - } - } + "$ref": "#/components/schemas/PromoteSyncSourceTestConnection" } } } }, "responses": { - "201": { + "200": { + "description": "Successful response indicating that an existing sync source was replaced.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWSCreateResponse" + "$ref": "#/components/schemas/SyncSource" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/onboardings/aws/oidc/{onboarding_id}": { - "get": { - "operationId": "GetAWSOnboarding", - "description": "Query an interactive onboarding for AWS", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/onboarding_id" - } - ], - "tags": [ - "teams" - ], - "responses": { - "200": { + "201": { + "description": "Successful response indicating that a new sync source was created.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWS" + "$ref": "#/components/schemas/SyncSource" } } } @@ -6021,71 +5807,39 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/onboardings/aws/oidc/{onboarding_id}/notify": { + "/v2/sync-integration-test-connections": { "post": { - "operationId": "NotifyOnboarding", - "description": "Update onboarding state", + "description": "Create an integration test connection.", + "operationId": "CreateV2SyncIntegrationTestConnection", "tags": [ - "teams" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/onboarding_id" - } + "syncs" ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWSNotification" + "$ref": "#/components/schemas/SyncIntegrationTestConnectionCreateV2" } } } }, "responses": { - "202": {}, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/onboardings/aws/oidc/{onboarding_id}/accounts": { - "get": { - "operationId": "GetAWSAccountsInRoot", - "description": "Query AWS accounts under organization root", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/onboarding_id" - } - ], - "tags": [ - "teams" - ], - "responses": { - "200": { + "201": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWSAccounts" + "$ref": "#/components/schemas/SyncIntegrationTestConnectionV2" } } } @@ -6099,36 +5853,63 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/onboardings/aws/oidc/{onboarding_id}/accounts/{aws_orgunit_id}": { + "/v2/sync-integrations": { "get": { - "operationId": "GetAWSAccountsInParent", - "description": "Query AWS accounts under a specifc Organizational Unit", + "description": "List sync integrations", + "operationId": "ListV2SyncIntegrations", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/onboarding_id" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/aws_orgunit_id" + "$ref": "#/components/parameters/sync_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + }, + { + "$ref": "#/components/parameters/sync_name_filter" } ], - "tags": [ - "teams" - ], "responses": { "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWSAccounts" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/SyncIntegrationExpandedV2" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -6146,34 +5927,34 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/teams/{team_name}/onboardings/aws/oidc/{onboarding_id}/accounts/provision": { + }, "post": { - "operationId": "ProvisionOnboardingConfiguration", - "description": "Provision onboarding configuration into the cloud account", + "description": "Create a new integration associated with a completed test connection", + "operationId": "CreateV2SyncIntegration", "tags": [ - "teams" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/onboarding_id" - } + "syncs" ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/OnboardingAWSProvision" + "$ref": "#/components/schemas/SyncIntegrationCreateV2" } } } }, "responses": { - "202": {}, + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationV2" + } + } + } + }, "400": { "$ref": "#/components/responses/BadRequest" }, @@ -6183,28 +5964,25 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/plugins": { + "/v2/sync-integrations/{sync_name}": { "get": { - "description": "List all plugins for the team.", - "operationId": "ListPluginsByTeam", + "description": "Get a sync integration by name", + "operationId": "GetV2SyncIntegration", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/include_private" + "$ref": "#/components/parameters/sync_name" } ], "responses": { @@ -6213,74 +5991,56 @@ "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/Plugin" - }, - "type": "array", - "example": [ - { - "name": "aws-source", - "kind": "source", - "team_name": "cloudquery", - "display_name": "AWS Source Plugin", - "category": "cloud-infrastructure", - "created_at": "2017-07-14T16:53:42Z", - "updated_at": "2017-07-14T16:53:42Z", - "homepage": "https://cloudquery.io", - "logo": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", - "official": true, - "short_description": "Sync data from AWS to any destination", - "repository": "https://github.com/cloudquery/cloudquery", - "tier": "paid", - "usd_per_row": "0.00123", - "free_rows_per_month": 10000, - "release_stage": "preview" - } - ] - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncIntegrationExpandedV2" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "plugins" - ] + } }, - "delete": { - "description": "Delete plugins by team", - "operationId": "DeletePluginsByTeam", - "x-internal": true, + "patch": { + "description": "Update attributes of an integration", + "operationId": "UpdateV2SyncIntegration", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationUpdateV2" + } + } + } + }, "responses": { - "204": { - "description": "Response" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationV2" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -6288,111 +6048,71 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + }, + "delete": { + "description": "Delete an integration", + "operationId": "DeleteV2SyncIntegration", "tags": [ - "teams" - ] - } - }, - "/teams/{team_name}/plugins/{plugin_team}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { - "get": { - "description": "Download an asset for a given plugin version as the current team.", - "operationId": "DownloadPluginAssetByTeam", + "syncs" + ], "parameters": [ { - "in": "header", - "name": "Accept", + "$ref": "#/components/parameters/sync_name" + }, + { + "name": "delete_data", + "description": "If true, also delete data associated with this integration from the relevant destinations.", + "in": "query", "required": false, "schema": { - "type": "string" + "type": "boolean", + "default": false } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_team" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "$ref": "#/components/parameters/target_name" } ], "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PluginAsset" - } - } - } + "204": { + "description": "Success" }, - "302": { - "description": "Response", - "headers": { - "Location": { - "schema": { - "type": "string" - } - } - } + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "plugins" - ] + } } }, - "/teams/{team_name}/policies": { + "/sync-sources": { "get": { - "operationId": "ListPolicies", - "description": "List Policies", + "description": "List all sync source definitions.", + "operationId": "ListSyncSources", "tags": [ - "policies" + "syncs" ], "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter policies by name." - }, { "$ref": "#/components/parameters/per_page" }, @@ -6400,37 +6120,31 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/platform_policies_sort_bys" + "$ref": "#/components/parameters/sync_name_filter" }, { - "$ref": "#/components/parameters/platform_policies_sort_dirs" + "$ref": "#/components/parameters/sync_generic_sort_bys" }, { - "name": "sort", - "in": "query", - "schema": { - "type": "string" - }, - "description": "DEPRECATED! Sorting order." + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { "200": { - "description": "List of policies.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "policies", + "items", "metadata" ], "properties": { - "policies": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/PlatformPolicy" - } + "$ref": "#/components/schemas/SyncSource" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -6443,20 +6157,61 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/sync-sources/{sync_source_name}": { + "get": { + "description": "Get a single sync source definition.", + "operationId": "GetSyncSource", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_source_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncSource" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } }, - "post": { - "description": "Create Policy", - "operationId": "CreatePolicy", + "patch": { + "description": "Update a Sync Source definition.", + "operationId": "UpdateSyncSource", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_source_name" } ], "requestBody": { @@ -6464,26 +6219,18 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformCreateOrUpdatePolicy" + "$ref": "#/components/schemas/SyncSourceUpdate" } } } }, "responses": { - "201": { - "description": "Created policy.", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/PlatformPolicy" - } - } + "$ref": "#/components/schemas/SyncSource" } } } @@ -6491,47 +6238,96 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "delete": { + "description": "Delete a Sync Source definition. Any syncs relying on this source must be deleted first.", + "operationId": "DeleteSyncSource", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_source_name" + } + ], + "responses": { + "204": { + "description": "Deleted" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/frameworks": { + "/sync-sources/{sync_source_name}/syncs": { "get": { - "description": "List All Frameworks", - "operationId": "ListAllFrameworks", + "description": "List all Syncs for a given sync source.", + "operationId": "ListSyncSourceSyncs", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_source_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/migration_filter" } ], - "tags": [ - "policies" - ], "responses": { "200": { - "description": "List of all frameworks.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "frameworks", + "items", "metadata" ], "properties": { - "frameworks": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/PlatformPolicyFramework" - } + "$ref": "#/components/schemas/ListSync" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -6541,77 +6337,169 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/{policy_id}": { + "/sync-sources/{sync_source_name}/test-connections/{sync_test_connection_id}": { "get": { - "description": "Get Policy", - "operationId": "GetPolicy", + "description": "Get test connection details for sync source.", + "operationId": "GetTestConnectionForSyncSource", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_source_name" }, { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." + "$ref": "#/components/parameters/sync_test_connection_id" } ], "responses": { "200": { - "description": "Retrieved policy.", + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncTestConnection" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/sync-transformers": { + "get": { + "description": "List all sync transformer definitions.", + "operationId": "ListSyncTransformers", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/sync_generic_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + } + ], + "responses": { + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "data" + "items", + "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/PlatformPolicy" + "items": { + "items": { + "$ref": "#/components/schemas/SyncTransformer" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } - }, - "put": { - "description": "Update Policy", - "operationId": "UpdatePolicy", + } + }, + "/sync-transformers/{sync_transformer_name}": { + "get": { + "description": "Get a single sync transformer definition.", + "operationId": "GetSyncTransformer", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_transformer_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncTransformer" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "patch": { + "description": "Update a Sync Transformer definition.", + "operationId": "UpdateSyncTransformer", + "tags": [ + "syncs" + ], + "parameters": [ { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." + "$ref": "#/components/parameters/sync_transformer_name" } ], "requestBody": { @@ -6619,26 +6507,18 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformCreateOrUpdatePolicy" + "$ref": "#/components/schemas/SyncTransformerUpdate" } } } }, "responses": { "200": { - "description": "Updated policy.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/PlatformPolicy" - } - } + "$ref": "#/components/schemas/SyncTransformer" } } } @@ -6646,115 +6526,84 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } }, "delete": { - "description": "Delete Policy", - "operationId": "DeletePolicy", + "description": "Delete a Sync Transformer definition. Any syncs relying on this transformer must be deleted first.", + "operationId": "DeleteSyncTransformer", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." + "$ref": "#/components/parameters/sync_transformer_name" } ], "responses": { "204": { - "description": "Policy deleted." + "description": "Deleted" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/{policy_id}/frameworks": { + "/sync-transformers/{sync_transformer_name}/syncs": { "get": { - "description": "List Policy Frameworks", - "operationId": "ListPolicyFrameworks", + "description": "List all Syncs for a given sync transformer.", + "operationId": "ListSyncTransformerSyncs", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." + "$ref": "#/components/parameters/sync_transformer_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/platform_policy_frameworks_sort_bys" - }, - { - "$ref": "#/components/parameters/platform_policies_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter rules by name." - }, - { - "name": "sort", - "in": "query", - "schema": { - "type": "string" - }, - "description": "DEPRECATED! Sorting order." } ], "responses": { "200": { - "description": "List of policy frameworks.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "frameworks", + "items", "metadata" ], "properties": { - "frameworks": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/PlatformPolicyFramework" - } + "$ref": "#/components/schemas/Sync" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -6764,82 +6613,52 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/{policy_id}/rules": { + "/sync-transformers/{sync_transformer_name}/sync-destinations": { "get": { - "description": "List Policy Rules", - "operationId": "ListPolicyRules", + "description": "List all Sync Destinations for a given sync transformer.", + "operationId": "ListSyncTransformerSyncDestinations", "tags": [ - "policies" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." + "$ref": "#/components/parameters/sync_transformer_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/platform_policy_rules_sort_bys" - }, - { - "$ref": "#/components/parameters/platform_policies_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter rules by name." - }, - { - "name": "sort", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Sorting order." } ], "responses": { "200": { - "description": "List of policy rules.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "rules", + "items", "metadata" ], "properties": { - "rules": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/PlatformPolicyRule" - } + "$ref": "#/components/schemas/SyncDestination" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -6849,46 +6668,26 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/{policy_id}/rules/{rule_id}/details": { + "/sync-upgrades": { "get": { - "description": "List Policy Rule Details", - "operationId": "ListPolicyRuleDetails", + "description": "List all version upgrades for syncs", + "operationId": "ListSyncUpgrades", "tags": [ - "policies" + "syncs" ], "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." - }, - { - "name": "rule_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the rule." - }, { "$ref": "#/components/parameters/per_page" }, @@ -6896,45 +6695,37 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/platform_policy_rule_details_sort_bys" + "$ref": "#/components/parameters/sync_upgrades_sort_bys" }, { - "$ref": "#/components/parameters/platform_policies_sort_dirs" + "$ref": "#/components/parameters/sync_sort_dirs" }, { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter rules by name." + "$ref": "#/components/parameters/sync_upgrades_path_filter" }, { - "name": "sort", - "in": "query", - "schema": { - "type": "string" - }, - "description": "DEPRECATED! Sorting order." + "$ref": "#/components/parameters/sync_upgrades_kind_filter" + }, + { + "$ref": "#/components/parameters/sync_upgrades_platform_version_filter" } ], "responses": { "200": { - "description": "List of policy rule details.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "details", + "items", "metadata" ], "properties": { - "details": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/PlatformPolicyRuleDetail" - } + "$ref": "#/components/schemas/SyncUpgrade" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -6947,140 +6738,26 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/teams/{team_name}/policies/{policy_id}/toggle": { - "post": { - "description": "Toggle Policy status", - "operationId": "TogglePolicy", - "tags": [ - "policies" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." - }, - { - "name": "status", - "in": "query", - "required": true, - "schema": { - "type": "string", - "enum": [ - "paused", - "active" - ] - } - } - ], - "responses": { - "200": { - "description": "Toggled policy state." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } } }, - "/teams/{team_name}/policies/{policy_id}/violations-history": { + "/syncs": { "get": { - "description": "Get Policy Violations History for defined period.", - "operationId": "GetPolicyViolationsHistory", + "description": "List all Syncs.", + "operationId": "ListSyncs", "tags": [ - "policies" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "policy_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the policy." - }, - { - "in": "query", - "name": "start", - "required": false, - "schema": { - "type": "string", - "format": "date-time" - }, - "description": "A valid ISO 8601 date string representing the inclusive start of the period within which to return history entities. Defaults to start of current month if not specified." - }, - { - "in": "query", - "name": "end", - "required": false, - "schema": { - "type": "string", - "format": "date-time" - }, - "description": "A valid ISO 8601 date string representing the exclusive end of the period within which to return history entities. Defaults to end of current month if not specified." - } + "syncs" ], - "responses": { - "200": { - "description": "List of policy violation history entities, sorted by descending date. Where no history for a given day, no object will be returned. Where multiple, the max will be returned.", - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "details" - ], - "properties": { - "details": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PlatformPolicyViolationHistory" - } - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - } - } - } - }, - "/teams/{team_name}/queries": { - "get": { - "description": "List all queries", - "operationId": "ListAllQueriesTeam", "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, { "$ref": "#/components/parameters/per_page" }, @@ -7088,22 +6765,16 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/query_tags" - }, - { - "$ref": "#/components/parameters/query_name_filter" - }, - { - "$ref": "#/components/parameters/query_filter" + "$ref": "#/components/parameters/sync_sort_bys" }, { - "$ref": "#/components/parameters/alert_configured" + "$ref": "#/components/parameters/sync_sort_dirs" }, { - "$ref": "#/components/parameters/alert_message_filter" + "$ref": "#/components/parameters/sync_name_filter" }, { - "$ref": "#/components/parameters/alert_enabled" + "$ref": "#/components/parameters/migration_filter" } ], "responses": { @@ -7119,7 +6790,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Query" + "$ref": "#/components/schemas/ListSync" }, "type": "array" }, @@ -7131,101 +6802,43 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries" - ] - } - }, - "/teams/{team_name}/queries/execute": { + } + }, "post": { - "description": "Run an ad-hoc SQL query against any table.\nFurther filtering can optionally be applied on top of the raw SQL results using the optional parameters. Filtering can be useful in situations where a saved query needs to be further filtered, grouped or paginated, such as in dashboards or reports.\n", - "operationId": "ExecuteAdHocQueryTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_selects" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/table_filter_ids" - }, - { - "$ref": "#/components/parameters/table_sort_bys" - }, - { - "$ref": "#/components/parameters/table_sort_dirs" - }, - { - "$ref": "#/components/parameters/table_group_bys" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } + "description": "Create new Sync definition. Sync runs can be scheduled automatically, or triggered manually after sync is created.", + "operationId": "CreateSync", + "tags": [ + "syncs" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "query" - ], - "properties": { - "query": { - "type": "string", - "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" - } - } + "$ref": "#/components/schemas/SyncCreate" } } } }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "data", - "metadata" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableData" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/Sync" } } } @@ -7236,56 +6849,85 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries" - ] + } } }, - "/teams/{team_name}/queries/save": { - "post": { - "description": "Save a query to execute later", - "operationId": "SaveQueryTeam", + "/syncs/{sync_name}": { + "get": { + "description": "Get a Sync", + "operationId": "GetSync", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Sync" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "patch": { + "description": "Update a Sync", + "operationId": "UpdateSync", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueryCreate" + "$ref": "#/components/schemas/SyncUpdate" } } } }, "responses": { - "201": { - "description": "Success", + "200": { + "description": "Updated", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueryDetail" + "$ref": "#/components/schemas/Sync" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" }, "403": { "$ref": "#/components/responses/Forbidden" @@ -7299,19 +6941,54 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, + } + }, + "delete": { + "description": "Delete Sync. This will delete Sync configuration and all associated sync runs, but will not delete the associated source and destination(s). These will need to be deleted separately.", + "operationId": "DeleteSync", "tags": [ - "queries" - ] + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" + } + ], + "responses": { + "204": { + "description": "Deleted" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } } }, - "/teams/{team_name}/queries/tags": { + "/syncs/{sync_name}/runs": { "get": { - "description": "List Query Tags", - "operationId": "ListQueryTagsTeam", + "description": "List all Sync Runs.", + "operationId": "ListSyncRuns", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/migration_filter" }, { "$ref": "#/components/parameters/per_page" @@ -7332,10 +7009,10 @@ ], "properties": { "items": { - "type": "array", "items": { - "$ref": "#/components/schemas/QueryTag" - } + "$ref": "#/components/schemas/SyncRun" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -7348,34 +7025,64 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "post": { + "description": "Create new SyncRun. This will trigger a manual job run.", + "operationId": "CreateSyncRun", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" + } + ], + "responses": { + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncRun" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries" - ] + } } }, - "/teams/{team_name}/queries/{query_id}": { + "/syncs/{sync_name}/runs/{sync_run_id}": { "get": { - "description": "Get a saved query", - "operationId": "GetSavedQueryTeam", + "description": "Get a Sync Run.", + "operationId": "GetSyncRun", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/query_id" + "$ref": "#/components/parameters/sync_run_id" } ], "responses": { @@ -7384,7 +7091,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueryDetail" + "$ref": "#/components/schemas/SyncRunDetails" } } } @@ -7392,50 +7099,52 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries" - ] + } }, "patch": { - "description": "Update a saved query", - "operationId": "UpdateQueryTeam", + "description": "Update a SyncRun", + "operationId": "UpdateSyncRun", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/query_id" + "$ref": "#/components/parameters/sync_run_id" } ], "requestBody": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueryUpdate" + "type": "object", + "properties": { + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "status_reason": { + "$ref": "#/components/schemas/SyncRunStatusReason" + } + } } } } }, "responses": { "200": { - "description": "Response", + "description": "Updated", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/QueryDetail" + "$ref": "#/components/schemas/SyncRun" } } } @@ -7443,9 +7152,6 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -7458,122 +7164,42 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/syncs/{sync_name}/runs/{sync_run_id}/logs/query": { + "get": { + "description": "Get logs for a sync run.", + "operationId": "GetSyncRunLogsQuery", "tags": [ - "queries" - ] - }, - "delete": { - "description": "Delete a saved query", - "operationId": "DeleteSavedQueryTeam", + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/query_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "queries" - ] - } - }, - "/teams/{team_name}/queries/{query_id}/alert": { - "delete": { - "description": "Delete alert from saved query", - "operationId": "DeleteAlert", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/query_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "queries", - "alerts" - ] - } - }, - "/teams/{team_name}/queries/{query_id}/execute": { - "post": { - "description": "Execute a saved query", - "operationId": "ExecuteSavedQueryTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/query_id" - }, - { - "$ref": "#/components/parameters/table_selects" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/table_filter_mode" + "$ref": "#/components/parameters/sync_run_id" }, { "$ref": "#/components/parameters/table_filters" }, - { - "$ref": "#/components/parameters/table_filter_ids" - }, - { - "$ref": "#/components/parameters/table_sort_bys" - }, - { - "$ref": "#/components/parameters/table_sort_dirs" - }, - { - "$ref": "#/components/parameters/table_group_bys" - }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -7595,18 +7221,24 @@ } } } + }, + "text/plain": { + "schema": { + "type": "string", + "description": "Download file." + } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -7616,67 +7248,62 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries" - ] + } } }, - "/teams/{team_name}/queries/{query_id}/filters": { + "/syncs/{sync_name}/runs/{sync_run_id}/logs/live": { "get": { - "description": "List Query Filters", - "operationId": "QueryListFiltersTeam", + "description": "Get live logs for a sync run.", + "operationId": "GetSyncRunLogsLive", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/query_id" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_run_id" }, { - "$ref": "#/components/parameters/filter_tags" + "in": "query", + "name": "table", + "required": false, + "schema": { + "type": "string", + "description": "Table name to filter logs by. Use a single dash (\"-\") as input to exclude all table-specific log lines." + } } ], "responses": { "200": { "description": "Response", "content": { - "application/json": { + "text/plain": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Filter" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "type": "string", + "description": "Chunked response logs for a sync run that is in progress." } } } }, + "204": { + "description": "No logs available for a sync run that has not started." + }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -7686,21 +7313,23 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries", - "filters" - ] - }, + } + } + }, + "/syncs/{sync_name}/runs/{sync_run_id}/progress": { "post": { - "description": "Save Query Filter", - "operationId": "QuerySaveFilterTeam", + "description": "Create a new sync run progress update.", + "operationId": "CreateSyncRunProgress", + "x-internal": true, + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/query_id" + "$ref": "#/components/parameters/sync_run_id" } ], "requestBody": { @@ -7708,31 +7337,53 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/FilterCreate" + "type": "object", + "required": [ + "rows", + "warnings", + "errors" + ], + "properties": { + "rows": { + "type": "integer", + "format": "int64", + "description": "Number of rows synced so far" + }, + "warnings": { + "type": "integer", + "format": "int64", + "description": "Number of warnings encountered so far" + }, + "errors": { + "type": "integer", + "format": "int64", + "description": "Number of errors encountered so far" + }, + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "shard_num": { + "type": "integer", + "format": "int32", + "description": "The shard number that this progress update is for" + }, + "shard_total": { + "type": "integer", + "format": "int32", + "description": "The total number of shards for this sync run" + }, + "table_progress": { + "$ref": "#/components/schemas/SyncRunTableProgress", + "description": "Table-specific progress information including error and row counts per table" + } + } } } } }, "responses": { - "200": { - "description": "Filter already exists", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } - }, - "201": { - "description": "Filter created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } + "204": { + "description": "Progress was reported successfully" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -7740,9 +7391,6 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -7752,29 +7400,22 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries", - "filters" - ] + } } }, - "/teams/{team_name}/queries/{query_id}/filters/tags": { + "/syncs/{sync_name}/runs/{sync_run_id}/stats": { "get": { - "description": "List Filter Tags For A Saved Query", - "operationId": "QueryListFilterTagsTeam", + "description": "Get statistics on a Sync Run", + "operationId": "GetSyncRunStats", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/query_id" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_run_id" } ], "responses": { @@ -7783,76 +7424,39 @@ "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncRunStats" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries", - "filters" - ] + } } }, - "/teams/{team_name}/reports": { + "/syncs/{sync_name}/runs/{sync_run_id}/tables": { "get": { - "operationId": "ListReports", - "description": "List reports", + "description": "Get table details on a Sync Run", + "operationId": "GetSyncRunTables", "tags": [ - "reports" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter reports by title or description." + "$ref": "#/components/parameters/sync_name" }, { - "name": "visibility", - "in": "query", - "schema": { - "type": "string", - "enum": [ - "private", - "public" - ] - } + "$ref": "#/components/parameters/sync_run_id" }, { "$ref": "#/components/parameters/per_page" @@ -7861,29 +7465,28 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/report_sort_bys" + "$ref": "#/components/parameters/sync_run_table_sort_bys" }, { - "$ref": "#/components/parameters/report_sort_dirs" + "$ref": "#/components/parameters/table_sort_dirs" } ], "responses": { "200": { - "description": "List of reports.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "reports", + "items", "metadata" ], "properties": { - "reports": { - "type": "array", + "items": { "items": { - "$ref": "#/components/schemas/Report" - } + "$ref": "#/components/schemas/SyncRunTableStat" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -7896,256 +7499,250 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } - }, - "post": { - "description": "Create Report", - "operationId": "CreateReport", - "tags": [ - "reports" - ], + } + }, + "/tables": { + "get": { + "description": "List Tables", + "operationId": "ListTables", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportCreate" - } - } - } - }, "responses": { - "201": { - "description": "Created report.", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "data" + "items", + "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/Report" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "tables" + ] } }, - "/teams/{team_name}/reports/{report_id}": { + "/tables/data": { "get": { - "description": "Get Report", - "operationId": "GetReport", + "description": "Get all syncs and their associated tables. Returns data in the format needed for the delete action.", + "operationId": "GetTablesData", "tags": [ - "reports" + "tables" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report." + "$ref": "#/components/parameters/page" } ], "responses": { "200": { - "description": "Retrieved report.", + "description": "Response", "content": { "application/json": { "schema": { "type": "object", "required": [ - "data" + "syncs", + "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/Report" + "syncs": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableDataListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + }, + "example": { + "syncs": [ + { + "sync_name": "aws-integration", + "display_name": "AWS Integration", + "tables": [ + { + "name": "aws_ec2_instances", + "deletion_pending": false + }, + { + "name": "aws_s3_buckets", + "deletion_pending": true + } + ], + "plugin": "cloudquery/aws" + }, + { + "sync_name": "gcp-integration", + "display_name": "GCP Integration", + "tables": [ + { + "name": "gcp_compute_instances", + "deletion_pending": false + } + ], + "plugin": "cloudquery/gcp" + } + ], + "metadata": { + "page_size": 10, + "last_page": 1, + "total_count": 2 } } } } } }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" + "500": { + "$ref": "#/components/responses/InternalError" } } }, - "put": { - "description": "Update Report", - "operationId": "UpdateReport", + "post": { + "description": "Perform an action on table data across multiple syncs. Supported actions: delete (drops partitions for specified tenant/source/table combinations).", + "operationId": "TablesDataAction", "tags": [ - "reports" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report." - } + "tables" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ReportUpdate" + "$ref": "#/components/schemas/TableDataAction" } } } }, "responses": { - "200": { - "description": "Updated report.", - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/Report" - } - } - } - } - } + "204": { + "description": "Success - action completed" }, "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } } - }, - "delete": { - "description": "Delete Report", - "operationId": "DeleteReport", - "tags": [ - "reports" - ], + } + }, + "/tables/{table_name}/data": { + "get": { + "description": "List Table Rows", + "operationId": "TableListRows", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_name" }, { - "name": "report_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report." - } - ], - "responses": { - "204": { - "description": "Report deleted." + "$ref": "#/components/parameters/table_selects" }, - "403": { - "$ref": "#/components/responses/Forbidden" + { + "$ref": "#/components/parameters/table_filter_mode" }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/teams/{team_name}/reports/templates": { - "get": { - "operationId": "ListReportTemplates", - "description": "List report templates", - "tags": [ - "reports" - ], - "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_filters" }, { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter report templates by name." + "$ref": "#/components/parameters/table_filter_ids" }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/table_sort_bys" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/table_sort_dirs" }, { - "$ref": "#/components/parameters/report_templates_sort_bys" + "$ref": "#/components/parameters/table_group_bys" }, { - "$ref": "#/components/parameters/report_templates_sort_dirs" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" } ], "responses": { "200": { - "description": "List of report templates.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "templates", + "data", "metadata" ], "properties": { - "templates": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ReportTemplate" - } + "data": { + "$ref": "#/components/schemas/TableData" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -8158,48 +7755,67 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } - }, - "post": { - "description": "Create Report Template", - "operationId": "CreateReportTemplate", + }, "tags": [ - "reports" - ], + "tables" + ] + } + }, + "/tables/{table_name}/data/{table_row_id}": { + "get": { + "description": "Get Table row", + "operationId": "TableRowById", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_name" + }, + { + "$ref": "#/components/parameters/table_row_id" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/table_filter_ids" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" - } - } - } - }, "responses": { - "201": { - "description": "Created report template.", + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "data" + "data", + "matches" ], "properties": { "data": { - "$ref": "#/components/schemas/ReportTemplate" + "$ref": "#/components/schemas/TableRow" + }, + "matches": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableRowFieldMatch" + } } } } @@ -8209,223 +7825,301 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "tables" + ] } }, - "/teams/{team_name}/reports/templates/{template_id}": { + "/tables/{table_name}/schema": { "get": { - "description": "Get Report Template", - "operationId": "GetReportTemplate", - "tags": [ - "reports" - ], + "description": "Get Table Schema", + "operationId": "TableSchema", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "template_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." + "$ref": "#/components/parameters/table_name" } ], "responses": { "200": { - "description": "Retrieved report template.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "data" + "schema", + "default_columns" ], "properties": { - "data": { - "$ref": "#/components/schemas/ReportTemplate" + "schema": { + "$ref": "#/components/schemas/TableSchema" + }, + "default_columns": { + "type": "array", + "items": { + "type": "string", + "description": "Column name" + } } } } } } }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } - }, - "put": { - "description": "Update Report Template", - "operationId": "UpdateReportTemplate", + }, "tags": [ - "reports" - ], + "tables" + ] + } + }, + "/tables/schemas": { + "get": { + "description": "Get Table Schemas", + "operationId": "BatchTableSchemas", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "template_id", - "in": "path", + "name": "tables", + "in": "query", + "description": "A list of table names to retrieve schemas for", "required": true, "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" - } + "type": "array", + "items": { + "type": "string", + "minLength": 1 + }, + "example": [ + "aws_ec2_instances", + "aws_s3_buckets" + ] } } - }, + ], "responses": { "200": { - "description": "Updated report template.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "data" + "items" ], "properties": { - "data": { - "$ref": "#/components/schemas/ReportTemplate" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/BatchTableSchemaItem" + } } } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } - }, - "delete": { - "description": "Delete Report Template", - "operationId": "DeleteReportTemplate", + }, "tags": [ - "reports" - ], + "tables" + ] + } + }, + "/tables/{table_name}/columns": { + "get": { + "description": "Get Table Columns", + "operationId": "TableListColumns", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_name" }, { - "name": "template_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_column_name_filter" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" } ], "responses": { - "204": { - "description": "Report template deleted." + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableColumnListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "tables" + ] } }, - "/teams/{team_name}/sync-destination-test-connections": { - "post": { - "description": "Create a test destination connection.", - "operationId": "CreateSyncDestinationTestConnection", - "tags": [ - "syncs" - ], + "/tables/{table_name}/columns/{column_name}/values": { + "get": { + "description": "Get Table Column Values", + "operationId": "TableColumnListValues", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_name" + }, + { + "$ref": "#/components/parameters/column_name" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_column_value_filter" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnectionCreate" - } - } - } - }, "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableColumnValueListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "tables" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "/tables/{table_name}/filters": { "get": { - "description": "Get a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnection", - "tags": [ - "syncs" - ], + "description": "List Table Filters", + "operationId": "TableListFilters", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/table_name" }, { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/filter_tags" } ], "responses": { @@ -8434,11 +8128,28 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Filter" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -8448,59 +8159,53 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Update a sync destination test connection.", - "operationId": "UpdateSyncTestConnectionForSyncDestination", + }, "tags": [ - "syncs" - ], + "tables", + "filters" + ] + }, + "post": { + "description": "Save Table Filter", + "operationId": "TableSaveFilter", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/table_name" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "#/components/schemas/SyncTestConnectionStatus" - }, - "failure_reason": { - "type": "string", - "description": "Reason for failure", - "example": "password authentication failed for user \"exampleuser\"" - }, - "failure_code": { - "example": "INVALID_CREDENTIALS", - "type": "string", - "description": "Code for failure" - } - } + "$ref": "#/components/schemas/FilterCreate" } } } }, "responses": { "200": { - "description": "Updated", + "description": "Filter already exists", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" + "$ref": "#/components/schemas/Filter" + } + } + } + }, + "201": { + "description": "Filter created", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Filter" } } } @@ -8508,6 +8213,9 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -8520,31 +8228,26 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "tables", + "filters" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}/logs": { + "/tables/{table_name}/filters/tags": { "get": { - "description": "Deprecated. Get logs for a sync destination test connection.", - "deprecated": true, - "operationId": "GetSyncDestinationTestConnectionLogs", - "tags": [ - "syncs" - ], + "description": "List Filter Tags For A Table", + "operationId": "TableListFilterTags", "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/table_name" }, { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/page" } ], "responses": { @@ -8553,49 +8256,31 @@ "content": { "application/json": { "schema": { - "additionalProperties": false, "required": [ - "location" + "items", + "metadata" ], "properties": { - "location": { - "type": "string", - "format": "uri", - "description": "The location to download the test connection logs from" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/FilterTag" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } - }, - "title": "Test Connection Logs", - "type": "object" - } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Chunked response logs for a test connection that is in progress." - } - } - } - }, - "204": { - "description": "No logs available for a test connection that has not started." - }, - "302": { - "description": "Redirect to the logs download URL for a test connection that has completed.", - "headers": { - "Location": { - "schema": { - "type": "string", - "description": "URL to download logs" + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8605,81 +8290,94 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "queries", + "filters" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/query": { + "/usage-summary": { "get": { - "description": "Get logs for a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnectionLogsQuery", - "tags": [ - "syncs" - ], + "description": "Get a summary of usage for the specified time range.", + "operationId": "GetTeamUsageSummary", "parameters": [ { - "in": "header", - "name": "Accept", + "in": "query", + "name": "metrics", "required": false, "schema": { - "type": "string" + "type": "array", + "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", + "items": { + "type": "string", + "enum": [ + "paid_rows", + "cloud_vcpu_seconds", + "cloud_vram_byte_seconds", + "network_egress_bytes" + ] + }, + "default": [ + "paid_rows" + ] } }, { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_test_connection_id" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/per_page" + "in": "query", + "name": "start", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." + } }, { - "$ref": "#/components/parameters/page" + "in": "query", + "name": "end", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." + } }, { - "$ref": "#/components/parameters/download_file" + "in": "query", + "name": "aggregation_period", + "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", + "required": false, + "schema": { + "type": "string", + "default": "day", + "enum": [ + "day", + "month" + ] + } } ], "responses": { "200": { - "description": "Response", + "description": "A summary of usage for the specified time range.", "content": { "application/json": { "schema": { - "required": [ - "data", - "metadata" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableData" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Download file." + "$ref": "#/components/schemas/UsageSummary" } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8689,53 +8387,107 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "usage" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/live": { + "/usage-summary/{group_by}": { "get": { - "description": "Get live logs for a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnectionLogsLive", - "tags": [ - "syncs" - ], + "description": "Get a grouped summary of usage for the specified time range.", + "operationId": "GetGroupedTeamUsageSummary", "parameters": [ { - "in": "header", - "name": "Accept", + "in": "path", + "name": "group_by", + "required": true, + "schema": { + "type": "string", + "enum": [ + "price_category", + "plugin", + "sync_id" + ], + "description": "Group by usage summary. `plugin` and `price_category` groupings are only available for `paid-rows`." + } + }, + { + "in": "query", + "name": "metrics", "required": false, "schema": { - "type": "string" + "type": "array", + "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", + "items": { + "type": "string", + "enum": [ + "paid_rows", + "cloud_vcpu_seconds", + "cloud_vram_byte_seconds", + "network_egress_bytes" + ] + }, + "default": [ + "paid_rows" + ] } }, { - "$ref": "#/components/parameters/team_name" + "in": "query", + "name": "start", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." + } }, { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "in": "query", + "name": "end", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." + } + }, + { + "in": "query", + "name": "aggregation_period", + "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", + "required": false, + "schema": { + "type": "string", + "default": "day", + "enum": [ + "day", + "month" + ] + } } ], "responses": { "200": { - "description": "Response", + "description": "A summary of usage for the specified time range.", "content": { - "text/plain": { + "application/json": { "schema": { - "type": "string", - "description": "Chunked response logs for a test connection that is in progress." + "$ref": "#/components/schemas/UsageSummary" } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8745,51 +8497,61 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "usage" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}/promote": { - "post": { - "description": "Promote a sync destination test connection to a sync destination.", - "operationId": "PromoteSyncDestinationTestConnection", - "tags": [ - "syncs" - ], + "/users": { + "get": { + "description": "List all users", + "operationId": "ListUsers", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/page" + }, + { + "name": "user_search", + "description": "Search by user name or email", + "in": "query", + "schema": { + "type": "string" + } + }, + { + "name": "role_id", + "description": "Search by user role ID", + "in": "query", + "schema": { + "$ref": "#/components/schemas/RoleID" + } } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PromoteSyncDestinationTestConnection" - } - } - } - }, "responses": { "200": { - "description": "Successful response indicating that an existing sync destination was replaced.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestination" - } - } - } - }, - "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/User" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -8800,66 +8562,64 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/sync-destinations": { - "get": { - "description": "List all sync destination definitions.", - "operationId": "ListSyncDestinations", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/sync_generic_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "users" + ] + }, + "post": { + "description": "Add new user", + "operationId": "AddUser", + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "email", + "name", + "roles" + ], + "properties": { + "email": { + "type": "string" + }, + "name": { + "type": "string" + }, + "password": { + "type": "string" + }, + "roles": { + "description": "Roles for the user", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/components/schemas/RoleID" + } + } + } + } + } } - ], + }, "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncDestination" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/User" } } } @@ -8870,72 +8630,108 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users", + "admin" + ] } }, - "/teams/{team_name}/sync-destinations/{sync_destination_name}": { + "/users/{user_id}": { "get": { - "description": "Get a single sync destination definition.", - "operationId": "GetSyncDestination", - "tags": [ - "syncs" - ], + "description": "Get user details", + "operationId": "GetUser", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" + "$ref": "#/components/parameters/user_id" } ], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "$ref": "#/components/schemas/User" } } - } + }, + "description": "Response" + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users", + "admin" + ] }, "patch": { - "description": "Update a Sync Destination definition.", - "operationId": "UpdateSyncDestination", - "tags": [ - "syncs" - ], + "description": "Update user", + "operationId": "UpdateUser", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" + "$ref": "#/components/parameters/user_id" } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationUpdate" + "type": "object", + "additionalProperties": false, + "properties": { + "email": { + "type": "string" + }, + "name": { + "type": "string" + }, + "password": { + "type": "string" + }, + "enabled": { + "type": "boolean" + }, + "roles": { + "description": "Roles for the user", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/components/schemas/RoleID" + } + } + } } } } @@ -8946,7 +8742,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "$ref": "#/components/schemas/User" } } } @@ -8957,6 +8753,9 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8966,29 +8765,33 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users", + "admin" + ] }, "delete": { - "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", - "operationId": "DeleteSyncDestination", - "tags": [ - "syncs" - ], + "description": "Delete user", + "operationId": "DeleteUser", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" + "$ref": "#/components/parameters/user_id" } ], "responses": { "204": { - "description": "Deleted" + "description": "Response" + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8998,27 +8801,25 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users", + "admin" + ] } }, - "/teams/{team_name}/sync-destinations/{sync_destination_name}/migrate": { - "post": { - "description": "Run migrations on all syncs which use this Sync Destination.", - "operationId": "MigrateSyncDestination", - "tags": [ - "syncs" - ], + "/users/{user_id}/totp": { + "delete": { + "description": "Disable/Reset MFA for a specific user", + "operationId": "DeleteUserTOTP", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" + "$ref": "#/components/parameters/user_id" } ], "responses": { "204": { - "description": "Migrations have been queued for all syncs using this Sync Destination." + "description": "Success" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -9026,72 +8827,70 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ] } }, - "/teams/{team_name}/sync-destinations/{sync_destination_name}/syncs": { + "/auth/saml": { "get": { - "description": "List all Syncs for a given sync destination.", - "operationId": "ListSyncDestinationSyncs", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "description": "Get SAML integration information", + "operationId": "GetSAML", + "responses": { + "200": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SAMLConfig" + } + } + } }, - { - "$ref": "#/components/parameters/sync_name_filter" + "400": { + "$ref": "#/components/responses/BadRequest" }, - { - "$ref": "#/components/parameters/migration_filter" + "500": { + "$ref": "#/components/responses/InternalError" } - ], + }, + "tags": [ + "admin" + ] + }, + "patch": { + "description": "Update SAML integration information", + "operationId": "UpdateSAML", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SAMLConfigUpdate" + } + } + } + }, "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/ListSync" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SAMLConfig" } } } @@ -9099,138 +8898,111 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] } }, - "/teams/{team_name}/sync-destinations/{sync_destination_name}/test-connections/{sync_test_connection_id}": { + "/settings": { "get": { - "description": "Get test connection details for sync destination.", - "operationId": "GetTestConnectionForSyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" - }, - { - "$ref": "#/components/parameters/sync_test_connection_id" - } - ], + "description": "Show current platform settings", + "operationId": "GetSettings", "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTestConnection" + "$ref": "#/components/schemas/PlatformSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/sync-source-test-connections": { - "post": { - "description": "Create a test source connection.", - "operationId": "CreateSyncSourceTestConnection", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], + "admin" + ] + }, + "patch": { + "description": "Update platform settings", + "operationId": "UpdateSettings", "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnectionCreate" + "$ref": "#/components/schemas/PlatformSettingsUpdate" } } } }, "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "$ref": "#/components/schemas/PlatformSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] } }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}": { + "/settings/data": { "get": { - "description": "Get a sync source test connection.", - "operationId": "GetSyncSourceTestConnection", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" - } - ], + "description": "Show current platform data settings", + "operationId": "GetDataSettings", "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "$ref": "#/components/schemas/PlatformDataSettings" } } } @@ -9244,65 +9016,42 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] }, "patch": { - "description": "Update a sync source test connection.", - "operationId": "UpdateSyncTestConnectionForSyncSource", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" - } - ], + "description": "Update platform data settings", + "operationId": "UpdateDataSettings", "requestBody": { "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "#/components/schemas/SyncTestConnectionStatus" - }, - "failure_reason": { - "type": "string", - "description": "Reason for failure", - "example": "password authentication failed for user \"exampleuser\"" - }, - "failure_code": { - "example": "INVALID_CREDENTIALS", - "type": "string", - "description": "Code for failure" - } - } + "$ref": "#/components/schemas/PlatformDataSettingsUpdate" } } } }, "responses": { "200": { - "description": "Updated", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "$ref": "#/components/schemas/PlatformDataSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" @@ -9316,72 +9065,114 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] } }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}/logs": { + "/user": { "get": { - "description": "Deprecated. Get logs for a sync source test connection.", - "deprecated": true, - "operationId": "GetSyncSourceTestConnectionLogs", - "tags": [ - "syncs" - ], - "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" - } - ], + "description": "Get the current authenticated user from the OAuth token\n", + "operationId": "GetCurrentUser", + "parameters": [], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "additionalProperties": false, - "required": [ - "location" - ], - "properties": { - "location": { - "type": "string", - "format": "uri", - "description": "The location to download the test connection logs from" + "allOf": [ + { + "$ref": "#/components/schemas/User" + }, + { + "type": "object", + "properties": { + "event_identifiers": { + "type": "object", + "additionalProperties": true + }, + "group_identifier": { + "type": "string" + }, + "registered_team_name": { + "type": "string", + "description": "The name of the team that the platform is registered with" + }, + "registered_team_internal": { + "type": "boolean", + "description": "Whether the team is internal or not" + } + } } - }, - "title": "Test Connection Logs", - "type": "object" + ] } - }, - "text/plain": { + } + }, + "description": "Response" + }, + "401": { + "content": { + "application/json": { "schema": { - "type": "string", - "description": "Chunked response logs for a test connection that is in progress." + "allOf": [ + { + "$ref": "#/components/schemas/BasicError" + }, + { + "properties": { + "password_reset_required": { + "type": "boolean", + "description": "Whether the user needs to reset their password" + } + } + } + ] } } } }, - "204": { - "description": "No logs available for a test connection that has not started." + "403": { + "$ref": "#/components/responses/Forbidden" }, - "302": { - "description": "Redirect to the logs download URL for a test connection that has completed.", - "headers": { - "Location": { + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "users" + ] + }, + "patch": { + "description": "Update attributes for the current authenticated user from the OAuth token", + "operationId": "UpdateCurrentUser", + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/components/schemas/UserName" + }, + "tracking_opt_in": { + "type": "boolean", + "description": "Whether to opt in or out of anonymous user tracking" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { "schema": { - "type": "string", - "description": "URL to download logs" + "$ref": "#/components/schemas/User" } } } @@ -9392,203 +9183,324 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "404": { - "$ref": "#/components/responses/NotFound" + "403": { + "$ref": "#/components/responses/Forbidden" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ] } }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}/logs/query": { - "get": { - "description": "Get logs for a sync source test connection.", - "operationId": "GetSyncSourceTestConnectionLogsQuery", - "tags": [ - "syncs" - ], - "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" + "/user/anon-event": { + "post": { + "description": "Send an anonymous event", + "operationId": "SendAnonymousEvent", + "x-internal": true, + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "name", + "anonymous_id" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of event" + }, + "anonymous_id": { + "type": "string", + "description": "Anonymous ID identifying the user", + "x-go-name": "AnonymousID" + }, + "properties": { + "type": "object", + "description": "Properties of event, keys should be of string type" + } + } + } } + } + }, + "responses": { + "204": { + "description": "Success" }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" - }, - { - "$ref": "#/components/parameters/table_filters" + "400": { + "$ref": "#/components/responses/BadRequest" }, - { - "$ref": "#/components/parameters/per_page" + "404": { + "$ref": "#/components/responses/NotFound" }, - { - "$ref": "#/components/parameters/page" + "429": { + "$ref": "#/components/responses/TooManyRequests" }, - { - "$ref": "#/components/parameters/download_file" + "500": { + "$ref": "#/components/responses/InternalError" } + }, + "tags": [ + "analytics" ], + "security": [] + } + }, + "/user/authenticate": { + "post": { + "description": "Authenticate a user with password", + "operationId": "AuthenticateUser", + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "email", + "password" + ], + "properties": { + "email": { + "type": "string" + }, + "password": { + "type": "string" + } + } + } + } + } + }, "responses": { "200": { - "description": "Response", + "description": "Authentication is successful", "content": { "application/json": { "schema": { "required": [ - "data", - "metadata" + "id_token" ], "properties": { - "data": { - "$ref": "#/components/schemas/TableData" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "id_token": { + "type": "string", + "x-go-name": "IDToken" } } } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Download file." - } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ], + "security": [] } }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}/logs/live": { - "get": { - "description": "Get live logs for a sync source test connection.", - "operationId": "GetSyncSourceTestConnectionLogsLive", - "tags": [ - "syncs" - ], - "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" + "/user/change-password": { + "post": { + "description": "Change user password", + "operationId": "ChangeUserPassword", + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "email", + "old_password", + "new_password" + ], + "properties": { + "email": { + "type": "string" + }, + "old_password": { + "type": "string" + }, + "new_password": { + "type": "string" + } + } + } } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" } - ], + }, "responses": { - "200": { - "description": "Response", - "content": { - "text/plain": { + "204": { + "description": "Successful", + "headers": { + "Set-Cookie": { + "description": "Reset session cookie", "schema": { "type": "string", - "description": "Chunked response logs for a test connection that is in progress." + "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ] } }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}/promote": { - "post": { - "description": "Promote a sync source test connection to a sync source.", - "operationId": "PromoteSyncSourceTestConnection", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_test_connection_id" - } - ], + "/user/customer": { + "patch": { + "description": "Update customer details", + "operationId": "UpdateCustomer", + "x-internal": true, + "parameters": [], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PromoteSyncSourceTestConnection" + "type": "object", + "additionalProperties": false, + "required": [ + "first_name", + "last_name" + ], + "properties": { + "first_name": { + "type": "string" + }, + "last_name": { + "type": "string" + }, + "company_name": { + "type": "string" + }, + "learned_about_cq_from": { + "type": "string" + }, + "learned_about_cq_from_other": { + "type": "string" + }, + "phone": { + "type": "string" + } + } } } } }, "responses": { - "200": { - "description": "Successful response indicating that an existing sync source was replaced.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncSource" - } - } - } - }, "201": { - "description": "Successful response indicating that a new sync source was created.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncSource" + "description": "Queued for processing" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "analytics" + ] + } + }, + "/user/event": { + "post": { + "description": "Send a user event", + "operationId": "SendUserEvent", + "x-internal": true, + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of event" + }, + "properties": { + "type": "object", + "description": "Properties of event, keys should be of string type" + } } } } + } + }, + "responses": { + "204": { + "description": "Success" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -9605,38 +9517,54 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "analytics" + ] } }, - "/v2/teams/{team_name}/sync-integration-test-connections": { + "/user/totp/verify": { "post": { - "description": "Create an integration test connection.", - "operationId": "CreateV2SyncIntegrationTestConnection", - "tags": [ - "syncs" - ], + "description": "Verify a one time password for MFA", + "operationId": "UserTOTPVerify", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "name": "__cqp_sess", + "in": "cookie", + "style": "form", + "schema": { + "type": "string" + } } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationTestConnectionCreateV2" + "type": "object", + "additionalProperties": false, + "required": [ + "otp" + ], + "properties": { + "otp": { + "type": "string", + "x-go-name": "OTP" + } + } } } } }, "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { + "204": { + "description": "Multifactor authentication is complete.", + "headers": { + "Set-Cookie": { + "description": "Session cookie", "schema": { - "$ref": "#/components/schemas/SyncIntegrationTestConnectionV2" + "type": "string", + "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } @@ -9647,9 +9575,15 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -9659,36 +9593,17 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ] } }, - "/v2/teams/{team_name}/sync-integrations": { - "get": { - "description": "List sync integrations", - "operationId": "ListV2SyncIntegrations", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - } - ], + "/user/totp": { + "post": { + "description": "Set up MFA for the current user", + "operationId": "UserTOTPSetup", + "parameters": [], "responses": { "200": { "description": "Response", @@ -9696,18 +9611,15 @@ "application/json": { "schema": { "required": [ - "items", - "metadata" + "secret", + "url" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncIntegrationExpandedV2" - }, - "type": "array" + "url": { + "type": "string" }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "secret": { + "type": "string" } } } @@ -9720,42 +9632,91 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "post": { - "description": "Create a new integration associated with a completed test connection", - "operationId": "CreateV2SyncIntegration", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" + "users" + ] + }, + "delete": { + "description": "Disable MFA for the current user", + "operationId": "UserTOTPDelete", + "parameters": [], + "responses": { + "204": { + "description": "Success" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - ], + }, + "tags": [ + "users" + ] + } + }, + "/user/login": { + "post": { + "description": "Start a session using ID token", + "operationId": "LoginUser", + "parameters": [], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationCreateV2" + "type": "object", + "additionalProperties": false, + "required": [ + "id_token" + ], + "properties": { + "id_token": { + "type": "string", + "x-go-name": "IDToken" + } + } } } } }, "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { + "204": { + "description": "Authentication is complete.", + "headers": { + "Set-Cookie": { + "description": "Session cookie", "schema": { - "$ref": "#/components/schemas/SyncIntegrationV2" + "type": "string", + "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } @@ -9766,40 +9727,36 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/v2/teams/{team_name}/sync-integrations/{sync_name}": { - "get": { - "description": "Get a sync integration by name", - "operationId": "GetV2SyncIntegration", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - } + "users" ], + "security": [] + }, + "delete": { + "description": "Logout a session", + "operationId": "LogoutUser", "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { + "204": { + "description": "Logout is complete.", + "headers": { + "Set-Cookie": { + "description": "Empty session cookie", "schema": { - "$ref": "#/components/schemas/SyncIntegrationExpandedV2" + "type": "string", + "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } @@ -9810,45 +9767,48 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Update attributes of an integration", - "operationId": "UpdateV2SyncIntegration", + }, + "tags": [ + "users" + ] + } + }, + "/v2/sync-destination-test-connections": { + "post": { + "description": "Create a test destination connection.", + "operationId": "CreateV2SyncDestinationTestConnection", "tags": [ "syncs" ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - } - ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationUpdateV2" + "$ref": "#/components/schemas/CreateSyncDestinationTestConnectionV2" } } } }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationV2" + "$ref": "#/components/schemas/SyncDestinationTestConnectionV2" } } } @@ -9865,28 +9825,52 @@ "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } } - }, - "delete": { - "description": "Delete an integration", - "operationId": "DeleteV2SyncIntegration", + } + }, + "/v2/sync-destinations": { + "post": { + "description": "Create sync destination based on test connection.", + "operationId": "CreateV2SyncDestination", "tags": [ "syncs" ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateSyncDestinationV2" + } + } } - ], + }, "responses": { - "204": { - "description": "Success" + "200": { + "description": "Successful response indicating that an existing sync destination was replaced.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationV2" + } + } + } + }, + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationV2" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -9894,32 +9878,24 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } } - } - }, - "/teams/{team_name}/sync-sources": { + }, "get": { - "description": "List all sync source definitions.", - "operationId": "ListSyncSources", - "tags": [ + "description": "List all sync destination definitions.", + "operationId": "GetV2SyncDestinations", + "tags": [ "syncs" ], "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, { "$ref": "#/components/parameters/per_page" }, @@ -9949,7 +9925,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncDestinationV2" }, "type": "array" }, @@ -9976,19 +9952,16 @@ } } }, - "/teams/{team_name}/sync-sources/{sync_source_name}": { + "/v2/sync-destinations/{sync_destination_name}": { "get": { - "description": "Get a single sync source definition.", - "operationId": "GetSyncSource", + "description": "Get a single sync destination definition.", + "operationId": "GetV2SyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { @@ -9997,7 +9970,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncDestinationV2" } } } @@ -10014,17 +9987,14 @@ } }, "patch": { - "description": "Update a Sync Source definition.", - "operationId": "UpdateSyncSource", + "description": "Update a Sync Destination definition.", + "operationId": "PatchV2SyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "requestBody": { @@ -10032,7 +10002,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceUpdate" + "$ref": "#/components/schemas/SyncDestinationUpdateV2" } } } @@ -10043,7 +10013,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncDestination" } } } @@ -10066,17 +10036,14 @@ } }, "delete": { - "description": "Delete a Sync Source definition. Any syncs relying on this source must be deleted first.", - "operationId": "DeleteSyncSource", + "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", + "operationId": "DeleteV2SyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { @@ -10098,57 +10065,11 @@ } } }, - "/teams/{team_name}/sync-sources/{sync_source_name}/migrate": { - "post": { - "description": "Run migrations on all syncs which use this Sync Source.", - "operationId": "MigrateSyncSource", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" - } - ], - "responses": { - "204": { - "description": "Migrations have been queued for all syncs using this Sync Source." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/sync-sources/{sync_source_name}/syncs": { + "/rbac/permissions": { "get": { - "description": "List all Syncs for a given sync source.", - "operationId": "ListSyncSourceSyncs", - "tags": [ - "syncs" - ], + "description": "List all permissions", + "operationId": "ListAllRBACPermissions", "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" - }, { "$ref": "#/components/parameters/per_page" }, @@ -10156,16 +10077,18 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/rbac_permissions_sort_bys" }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/rbac_permissions_sort_dirs" }, { - "$ref": "#/components/parameters/migration_filter" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter permissions by name or description." } ], "responses": { @@ -10181,7 +10104,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/ListSync" + "$ref": "#/components/schemas/RBACPermission" }, "type": "array" }, @@ -10199,40 +10122,43 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/sync-sources/{sync_source_name}/test-connections/{sync_test_connection_id}": { - "get": { - "description": "Get test connection details for sync source.", - "operationId": "GetTestConnectionForSyncSource", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_source_name" - }, - { - "$ref": "#/components/parameters/sync_test_connection_id" + "rbac" + ] + }, + "post": { + "description": "Create a permission", + "operationId": "CreateRBACPermission", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACPermissionCreate" + } + } } - ], + }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTestConnection" + "$ref": "#/components/schemas/RBACPermission" } } } @@ -10243,63 +10169,40 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] } }, - "/teams/{team_name}/sync-transformers": { + "/rbac/permissions/{permission_id}": { "get": { - "description": "List all sync transformer definitions.", - "operationId": "ListSyncTransformers", - "tags": [ - "syncs" - ], + "description": "Get a permission", + "operationId": "GetRBACPermission", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/sync_generic_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/rbac_permission_id" } ], "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncTransformer" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/RBACPermission" } } } @@ -10310,125 +10213,93 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/sync-transformers/{sync_transformer_name}": { - "get": { - "description": "Get a single sync transformer definition.", - "operationId": "GetSyncTransformer", + }, "tags": [ - "syncs" - ], + "rbac" + ] + }, + "patch": { + "description": "Update a permission", + "operationId": "UpdateRBACPermission", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_transformer_name" + "$ref": "#/components/parameters/rbac_permission_id" } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACPermissionUpdate" + } + } + } + }, "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTransformer" + "$ref": "#/components/schemas/RBACPermission" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Update a Sync Transformer definition.", - "operationId": "UpdateSyncTransformer", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_transformer_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncTransformerUpdate" - } - } - } - }, - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncTransformer" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } + }, + "tags": [ + "rbac" + ] }, "delete": { - "description": "Delete a Sync Transformer definition. Any syncs relying on this transformer must be deleted first.", - "operationId": "DeleteSyncTransformer", - "tags": [ - "syncs" - ], + "description": "Delete a permission", + "operationId": "DeleteRBACPermission", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_transformer_name" + "$ref": "#/components/parameters/rbac_permission_id" } ], "responses": { "204": { - "description": "Deleted" + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -10438,28 +10309,44 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] } }, - "/teams/{team_name}/sync-transformers/{sync_transformer_name}/syncs": { + "/rbac/roles": { "get": { - "description": "List all Syncs for a given sync transformer.", - "operationId": "ListSyncTransformerSyncs", - "tags": [ - "syncs" - ], + "description": "List all roles", + "operationId": "ListAllRBACRoles", "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_transformer_name" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/rbac_roles_sort_bys" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/rbac_roles_sort_dirs" + }, + { + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter roles by name or description." + }, + { + "name": "type", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter roles by type." } ], "responses": { @@ -10475,7 +10362,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Sync" + "$ref": "#/components/schemas/Role" }, "type": "array" }, @@ -10487,130 +10374,93 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/sync-transformers/{sync_transformer_name}/sync-destinations": { - "get": { - "description": "List all Sync Destinations for a given sync transformer.", - "operationId": "ListSyncTransformerSyncDestinations", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_transformer_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" + "rbac" + ] + }, + "post": { + "description": "Create a role", + "operationId": "CreateRBACRole", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACRoleCreate" + } + } } - ], + }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncDestination" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/Role" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] } }, - "/teams/{team_name}/sync-upgrades": { + "/rbac/roles/{role_id}": { "get": { - "description": "List all version upgrades for syncs", - "operationId": "ListSyncUpgrades", - "tags": [ - "syncs" - ], + "description": "Get a role", + "operationId": "GetRBACRole", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_upgrades_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - }, - { - "$ref": "#/components/parameters/sync_upgrades_path_filter" - }, - { - "$ref": "#/components/parameters/sync_upgrades_kind_filter" - }, - { - "$ref": "#/components/parameters/sync_upgrades_platform_version_filter" + "$ref": "#/components/parameters/rbac_role_id" } ], "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncUpgrade" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/Role" } } } @@ -10621,93 +10471,29 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } - } - }, - "/teams/{team_name}/syncs": { - "get": { - "description": "List all Syncs.", - "operationId": "ListSyncs", + }, "tags": [ - "syncs" - ], + "rbac" + ] + }, + "patch": { + "description": "Update a role (custom roles only)", + "operationId": "UpdateRBACRole", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/migration_filter" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/ListSync" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - }, - "post": { - "description": "Create new Sync definition. Sync runs can be scheduled automatically, or triggered manually after sync is created.", - "operationId": "CreateSync", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/rbac_role_id" } ], "requestBody": { @@ -10715,59 +10501,18 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncCreate" + "$ref": "#/components/schemas/RBACRoleUpdate" } } } }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Sync" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}": { - "get": { - "description": "Get a Sync", - "operationId": "GetSync", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - } - ], "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Sync" + "$ref": "#/components/schemas/Role" } } } @@ -10778,51 +10523,6 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - }, - "patch": { - "description": "Update a Sync", - "operationId": "UpdateSync", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncUpdate" - } - } - } - }, - "responses": { - "200": { - "description": "Updated", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Sync" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -10835,32 +10535,29 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] }, "delete": { - "description": "Delete Sync. This will delete Sync configuration and all associated sync runs, but will not delete the associated source and destination(s). These will need to be deleted separately.", - "operationId": "DeleteSync", - "tags": [ - "syncs" - ], + "description": "Delete a role", + "operationId": "DeleteRBACRole", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/rbac_role_id" } ], "responses": { "204": { - "description": "Deleted" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Success" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -10870,26 +10567,17 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] } }, - "/teams/{team_name}/syncs/{sync_name}/runs": { + "/teams": { "get": { - "description": "List all Sync Runs.", - "operationId": "ListSyncRuns", - "tags": [ - "syncs" - ], + "description": "List all teams", + "operationId": "ListTeams", "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/migration_filter" - }, { "$ref": "#/components/parameters/per_page" }, @@ -10910,7 +10598,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/Team" }, "type": "array" }, @@ -10925,58 +10613,98 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "post": { - "description": "Create new SyncRun. This will trigger a manual job run.", - "operationId": "CreateSyncRun", + }, "tags": [ - "syncs" - ], + "teams" + ] + } + }, + "/teams/{team_name}/plugins/{plugin_team}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { + "get": { + "description": "Download an asset for a given plugin version as the current team.", + "operationId": "DownloadPluginAssetByTeam", "parameters": [ + { + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } + }, { "$ref": "#/components/parameters/team_name" }, { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/plugin_team" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_name" + }, + { + "$ref": "#/components/parameters/target_name" } ], "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/PluginAsset" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "302": { + "description": "Response", + "headers": { + "Location": { + "schema": { + "type": "string" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "plugins" + ] } }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}": { - "get": { - "description": "Get a Sync Run.", - "operationId": "GetSyncRun", + "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/progress": { + "post": { + "description": "Deprecated. Create a new sync run progress update.", + "operationId": "CreateSyncRunProgressTeam", + "x-internal": true, + "deprecated": true, "tags": [ "syncs" ], @@ -10991,16 +10719,61 @@ "$ref": "#/components/parameters/sync_run_id" } ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncRunDetails" + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "rows", + "warnings", + "errors" + ], + "properties": { + "rows": { + "type": "integer", + "format": "int64", + "description": "Number of rows synced so far" + }, + "warnings": { + "type": "integer", + "format": "int64", + "description": "Number of warnings encountered so far" + }, + "errors": { + "type": "integer", + "format": "int64", + "description": "Number of errors encountered so far" + }, + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "shard_num": { + "type": "integer", + "format": "int32", + "description": "The shard number that this progress update is for" + }, + "shard_total": { + "type": "integer", + "format": "int32", + "description": "The total number of shards for this sync run" + }, + "table_progress": { + "$ref": "#/components/schemas/SyncRunTableProgress", + "description": "Table-specific progress information including error and row counts per table" + } } } } + } + }, + "responses": { + "204": { + "description": "Progress was reported successfully" + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -11008,14 +10781,21 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } - }, + } + }, + "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}": { "patch": { - "description": "Update a SyncRun", - "operationId": "UpdateSyncRun", + "description": "Deprecated. Update a sync source test connection.", + "operationId": "UpdateSyncTestConnectionForSyncSourceTeam", + "deprecated": true, + "x-internal": true, "tags": [ "syncs" ], @@ -11024,10 +10804,7 @@ "$ref": "#/components/parameters/team_name" }, { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "requestBody": { @@ -11035,12 +10812,22 @@ "application/json": { "schema": { "type": "object", + "required": [ + "status" + ], "properties": { "status": { - "$ref": "#/components/schemas/SyncRunStatus" + "$ref": "#/components/schemas/SyncTestConnectionStatus" }, - "status_reason": { - "$ref": "#/components/schemas/SyncRunStatusReason" + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" } } } @@ -11053,7 +10840,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -11076,80 +10863,57 @@ } } }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/logs": { - "get": { - "description": "Deprecated. Get logs for a sync run.", - "operationId": "GetSyncRunLogs", + "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "patch": { + "description": "Deprecated. Update a sync destination test connection.", + "operationId": "UpdateSyncTestConnectionForSyncDestinationTeam", + "deprecated": true, + "x-internal": true, "tags": [ "syncs" ], "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, { "$ref": "#/components/parameters/team_name" }, { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "in": "query", - "name": "table", - "required": false, - "schema": { - "type": "string", - "description": "Table name to filter logs by. Use a single dash (\"-\") as input to exclude all table-specific log lines." - } + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "additionalProperties": false, - "required": [ - "location" - ], - "properties": { - "location": { - "type": "string", - "format": "uri", - "description": "The location to download the sync run logs from" - } + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" }, - "title": "Sync Run Logs", - "type": "object" - } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Chunked response logs for a sync run that is in progress." + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" + } } } } - }, - "204": { - "description": "No logs available for a sync run that has not started." - }, - "302": { - "description": "Redirect to the logs download URL for a sync run that has completed.", - "headers": { - "Location": { + } + }, + "responses": { + "200": { + "description": "Updated", + "content": { + "application/json": { "schema": { - "type": "string", - "description": "URL to download logs" + "$ref": "#/components/schemas/SyncDestinationTestConnection" } } } @@ -11157,8 +10921,8 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" @@ -11171,4309 +10935,268 @@ } } } + } + }, + "components": { + "securitySchemes": { + "bearerAuth": { + "scheme": "bearer", + "type": "http" + }, + "basicAuth": { + "scheme": "basic", + "type": "http" + }, + "cookieAuth": { + "scheme": "cookie", + "type": "http" + } }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/logs/query": { - "get": { - "description": "Get logs for a sync run.", - "operationId": "GetSyncRunLogsQuery", - "tags": [ - "syncs" - ], - "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/download_file" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "data", - "metadata" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableData" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Download file." - } - } - } - }, - "204": { - "description": "No logs available for a test connection that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/logs/live": { - "get": { - "description": "Get live logs for a sync run.", - "operationId": "GetSyncRunLogsLive", - "tags": [ - "syncs" - ], - "parameters": [ - { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "in": "query", - "name": "table", - "required": false, - "schema": { - "type": "string", - "description": "Table name to filter logs by. Use a single dash (\"-\") as input to exclude all table-specific log lines." - } - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "text/plain": { - "schema": { - "type": "string", - "description": "Chunked response logs for a sync run that is in progress." - } - } - } - }, - "204": { - "description": "No logs available for a sync run that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/progress": { - "post": { - "description": "Create a new sync run progress update.", - "operationId": "CreateSyncRunProgress", - "x-internal": true, - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "rows", - "warnings", - "errors" - ], - "properties": { - "rows": { - "type": "integer", - "format": "int64", - "description": "Number of rows synced so far" - }, - "warnings": { - "type": "integer", - "format": "int64", - "description": "Number of warnings encountered so far" - }, - "errors": { - "type": "integer", - "format": "int64", - "description": "Number of errors encountered so far" - }, - "status": { - "$ref": "#/components/schemas/SyncRunStatus" - }, - "shard_num": { - "type": "integer", - "format": "int32", - "description": "The shard number that this progress update is for" - }, - "shard_total": { - "type": "integer", - "format": "int32", - "description": "The total number of shards for this sync run" - }, - "table_progress": { - "$ref": "#/components/schemas/SyncRunTableProgress", - "description": "Table-specific progress information including error and row counts per table" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Progress was reported successfully" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/stats": { - "get": { - "description": "Get statistics on a Sync Run", - "operationId": "GetSyncRunStats", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncRunStats" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/tables": { - "get": { - "description": "Get table details on a Sync Run", - "operationId": "GetSyncRunTables", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/table_sort_bys" - }, - { - "$ref": "#/components/parameters/table_sort_dirs" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncRunTableStat" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/connector/{connector_id}/credentials": { - "get": { - "description": "Get connector credentials for a sync run.", - "operationId": "GetSyncRunConnectorCredentials", - "x-internal": true, - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "$ref": "#/components/parameters/connector_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "aws": { - "$ref": "#/components/schemas/ConnectorCredentialsResponseAWS" - }, - "oauth": { - "$ref": "#/components/schemas/ConnectorCredentialsResponseOAuth" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/connector/{connector_id}/identity": { - "get": { - "description": "Get connector identity for a sync run.", - "operationId": "GetSyncRunConnectorIdentity", - "x-internal": true, - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" - }, - { - "$ref": "#/components/parameters/connector_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "aws": { - "$ref": "#/components/schemas/ConnectorIdentityResponseAWS" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/test-connections/{sync_test_connection_id}/connector/{connector_id}/credentials": { - "get": { - "description": "Get connector credentials for a test connection", - "operationId": "GetTestConnectionConnectorCredentials", - "x-internal": true, - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_test_connection_id" - }, - { - "$ref": "#/components/parameters/connector_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "aws": { - "$ref": "#/components/schemas/ConnectorCredentialsResponseAWS" - }, - "oauth": { - "$ref": "#/components/schemas/ConnectorCredentialsResponseOAuth" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/syncs/test-connections/{sync_test_connection_id}/connector/{connector_id}/identity": { - "get": { - "description": "Get connector identity for a test connection.", - "operationId": "GetTestConnectionConnectorIdentity", - "x-internal": true, - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_test_connection_id" - }, - { - "$ref": "#/components/parameters/connector_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "type": "object", - "properties": { - "aws": { - "$ref": "#/components/schemas/ConnectorIdentityResponseAWS" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/tables": { - "get": { - "description": "List Tables", - "operationId": "ListTablesTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/data": { - "get": { - "description": "List Table Rows", - "operationId": "TableListRowsTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_selects" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/table_filter_ids" - }, - { - "$ref": "#/components/parameters/table_sort_bys" - }, - { - "$ref": "#/components/parameters/table_sort_dirs" - }, - { - "$ref": "#/components/parameters/table_group_bys" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "data", - "metadata" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableData" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/data/{table_row_id}": { - "get": { - "description": "Get Table row", - "operationId": "TableRowByIdTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_row_id" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/table_filter_ids" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "data", - "matches" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableRow" - }, - "matches": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableRowFieldMatch" - } - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/schema": { - "get": { - "description": "Get Table Schema", - "operationId": "TableSchemaTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "schema", - "default_columns" - ], - "properties": { - "schema": { - "$ref": "#/components/schemas/TableSchema" - }, - "default_columns": { - "type": "array", - "items": { - "type": "string", - "description": "Column name" - } - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/schemas": { - "get": { - "description": "Get Table Schemas", - "operationId": "BatchTableSchemasTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "name": "tables", - "in": "query", - "description": "A list of table names to retrieve schemas for", - "required": true, - "schema": { - "type": "array", - "items": { - "type": "string", - "minLength": 1 - }, - "example": [ - "aws_ec2_instances", - "aws_s3_buckets" - ] - } - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/BatchTableSchemaItem" - } - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/columns": { - "get": { - "description": "Get Table Columns", - "operationId": "TableListColumnsTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_column_name_filter" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableColumnListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/columns/{column_name}/values": { - "get": { - "description": "Get Table Column Values", - "operationId": "TableColumnListValuesTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/column_name" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_column_value_filter" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableColumnValueListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/filters": { - "get": { - "description": "List Table Filters", - "operationId": "TableListFiltersTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/filter_tags" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Filter" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables", - "filters" - ] - }, - "post": { - "description": "Save Table Filter", - "operationId": "TableSaveFilterTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FilterCreate" - } - } - } - }, - "responses": { - "200": { - "description": "Filter already exists", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } - }, - "201": { - "description": "Filter created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables", - "filters" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/filters/tags": { - "get": { - "description": "List Filter Tags For A Table", - "operationId": "TableListFilterTagsTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "queries", - "filters" - ] - } - }, - "/teams/{team_name}/tables/{table_name}/relations": { - "get": { - "description": "List Table Relations", - "operationId": "TableListRelationsTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/table_name" - }, - { - "name": "relation_name", - "description": "Filter by related table name", - "in": "query", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "data" - ], - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableRelation" - } - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "tables" - ] - } - }, - "/teams/{team_name}/usage-summary": { - "get": { - "description": "Get a summary of usage for the specified time range.", - "operationId": "GetTeamUsageSummary", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "in": "query", - "name": "metrics", - "required": false, - "schema": { - "type": "array", - "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", - "items": { - "type": "string", - "enum": [ - "paid_rows", - "cloud_vcpu_seconds", - "cloud_vram_byte_seconds", - "network_egress_bytes" - ] - }, - "default": [ - "paid_rows" - ] - } - }, - { - "in": "query", - "name": "start", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." - } - }, - { - "in": "query", - "name": "end", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." - } - }, - { - "in": "query", - "name": "aggregation_period", - "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", - "required": false, - "schema": { - "type": "string", - "default": "day", - "enum": [ - "day", - "month" - ] - } - } - ], - "responses": { - "200": { - "description": "A summary of usage for the specified time range.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UsageSummary" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "teams" - ] - } - }, - "/teams/{team_name}/usage-summary/{group_by}": { - "get": { - "description": "Get a grouped summary of usage for the specified time range.", - "operationId": "GetGroupedTeamUsageSummary", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "in": "path", - "name": "group_by", - "required": true, - "schema": { - "type": "string", - "enum": [ - "price_category", - "plugin", - "sync_id" - ], - "description": "Group by usage summary. `plugin` and `price_category` groupings are only available for `paid-rows`." - } - }, - { - "in": "query", - "name": "metrics", - "required": false, - "schema": { - "type": "array", - "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", - "items": { - "type": "string", - "enum": [ - "paid_rows", - "cloud_vcpu_seconds", - "cloud_vram_byte_seconds", - "network_egress_bytes" - ] - }, - "default": [ - "paid_rows" - ] - } - }, - { - "in": "query", - "name": "start", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." - } - }, - { - "in": "query", - "name": "end", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." - } - }, - { - "in": "query", - "name": "aggregation_period", - "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", - "required": false, - "schema": { - "type": "string", - "default": "day", - "enum": [ - "day", - "month" - ] - } - } - ], - "responses": { - "200": { - "description": "A summary of usage for the specified time range.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UsageSummary" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "teams" - ] - } - }, - "/teams/{team_name}/users": { - "get": { - "description": "List all users in the current team.", - "operationId": "ListUsersByTeam", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/User" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "teams" - ] - } - }, - "/upload/image": { - "post": { - "description": "Get a URL to upload image that will be publicly accessible", - "operationId": "UploadImage", - "parameters": [], - "tags": [ - "images" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "required": [ - "content_type" - ], - "properties": { - "content_type": { - "$ref": "#/components/schemas/ContentType" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ImageURL" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/user": { - "get": { - "description": "Get the current authenticated user from the OAuth token\n", - "operationId": "GetCurrentUser", - "parameters": [], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "$ref": "#/components/schemas/User" - }, - { - "type": "object", - "properties": { - "event_identifiers": { - "type": "object", - "additionalProperties": true - }, - "group_identifier": { - "type": "string" - }, - "registered_team_name": { - "type": "string", - "description": "The name of the team that the platform is registered with" - }, - "registered_team_internal": { - "type": "boolean", - "description": "Whether the team is internal or not" - } - } - } - ] - } - } - }, - "description": "Response" - }, - "401": { - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "$ref": "#/components/schemas/BasicError" - }, - { - "properties": { - "password_reset_required": { - "type": "boolean", - "description": "Whether the user needs to reset their password" - } - } - } - ] - } - } - } - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - }, - "patch": { - "description": "Update attributes for the current authenticated user from the OAuth token", - "operationId": "UpdateCurrentUser", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "$ref": "#/components/schemas/UserName" - }, - "tracking_opt_in": { - "type": "boolean", - "description": "Whether to opt in or out of anonymous user tracking" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/User" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/anon-event": { - "post": { - "description": "Send an anonymous event", - "operationId": "SendAnonymousEvent", - "x-internal": true, - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "name", - "anonymous_id" - ], - "properties": { - "name": { - "type": "string", - "description": "Name of event" - }, - "anonymous_id": { - "type": "string", - "description": "Anonymous ID identifying the user", - "x-go-name": "AnonymousID" - }, - "properties": { - "type": "object", - "description": "Properties of event, keys should be of string type" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "analytics" - ], - "security": [] - } - }, - "/user/authenticate": { - "post": { - "description": "Authenticate a user with password", - "operationId": "AuthenticateLocalUser", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "password" - ], - "properties": { - "email": { - "type": "string" - }, - "password": { - "type": "string" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "Authentication is successful", - "content": { - "application/json": { - "schema": { - "required": [ - "id_token" - ], - "properties": { - "id_token": { - "type": "string", - "x-go-name": "IDToken" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ], - "security": [] - } - }, - "/user/change-password": { - "post": { - "description": "Change user password", - "operationId": "ChangeLocalUserPassword", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "old_password", - "new_password" - ], - "properties": { - "email": { - "type": "string" - }, - "old_password": { - "type": "string" - }, - "new_password": { - "type": "string" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Successful", - "headers": { - "Set-Cookie": { - "description": "Reset session cookie", - "schema": { - "type": "string", - "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/customer": { - "patch": { - "description": "Update customer details", - "operationId": "UpdateCustomer", - "x-internal": true, - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "first_name", - "last_name" - ], - "properties": { - "first_name": { - "type": "string" - }, - "last_name": { - "type": "string" - }, - "company_name": { - "type": "string" - }, - "learned_about_cq_from": { - "type": "string" - }, - "learned_about_cq_from_other": { - "type": "string" - }, - "phone": { - "type": "string" - } - } - } - } - } - }, - "responses": { - "201": { - "description": "Queued for processing" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "analytics" - ] - } - }, - "/user/event": { - "post": { - "description": "Send a user event", - "operationId": "SendUserEvent", - "x-internal": true, - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "name" - ], - "properties": { - "name": { - "type": "string", - "description": "Name of event" - }, - "properties": { - "type": "object", - "description": "Properties of event, keys should be of string type" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "analytics" - ] - } - }, - "/user/invitations": { - "get": { - "operationId": "ListCurrentUserInvitations", - "description": "List of the current user's unaccepted invitations", - "tags": [ - "users" - ], - "parameters": [ - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/InvitationWithToken" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/user/totp/verify": { - "post": { - "description": "Verify a one time password for MFA", - "operationId": "UserTOTPVerify", - "parameters": [ - { - "name": "__cqp_sess", - "in": "cookie", - "style": "form", - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "otp" - ], - "properties": { - "otp": { - "type": "string", - "x-go-name": "OTP" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Multifactor authentication is complete.", - "headers": { - "Set-Cookie": { - "description": "Session cookie", - "schema": { - "type": "string", - "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/totp": { - "post": { - "description": "Set up MFA for the current user", - "operationId": "UserTOTPSetup", - "parameters": [], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "secret", - "url" - ], - "properties": { - "url": { - "type": "string" - }, - "secret": { - "type": "string" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - }, - "delete": { - "description": "Disable MFA for the current user", - "operationId": "UserTOTPDelete", - "parameters": [], - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/local": { - "get": { - "description": "Get the current authenticated local user", - "operationId": "GetCurrentLocalUser", - "parameters": [], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/LocalUserWithTeams" - } - } - }, - "description": "Response" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/login": { - "post": { - "description": "Start a session using ID token", - "operationId": "LoginUser", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "id_token" - ], - "properties": { - "id_token": { - "type": "string", - "x-go-name": "IDToken" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Authentication is complete.", - "headers": { - "Set-Cookie": { - "description": "Session cookie", - "schema": { - "type": "string", - "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ], - "security": [] - }, - "delete": { - "description": "Logout a session", - "operationId": "LogoutUser", - "responses": { - "204": { - "description": "Logout is complete.", - "headers": { - "Set-Cookie": { - "description": "Empty session cookie", - "schema": { - "type": "string", - "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/memberships": { - "get": { - "description": "Get memberships that the user has accepted.", - "operationId": "GetCurrentUserMemberships", - "parameters": [ - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "required": [ - "metadata", - "items" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/MembershipWithTeam" - }, - "type": "array", - "example": [ - { - "roles": [ - "admin:write" - ], - "team": { - "created_at": "2017-07-14T16:53:42Z", - "name": "cloudquery", - "display_name": "CloudQuery", - "plan": "free", - "is_trial_active": false, - "internal": false - } - } - ] - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - }, - "description": "Response" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/user/reset-password-token": { - "post": { - "description": "Reset user password with token", - "operationId": "ResetLocalUserPassword", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "reset_token", - "new_password" - ], - "properties": { - "email": { - "type": "string" - }, - "reset_token": { - "type": "string" - }, - "new_password": { - "type": "string" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Successful", - "headers": { - "Set-Cookie": { - "description": "Reset session cookie", - "schema": { - "type": "string", - "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ], - "security": [] - } - }, - "/user/token": { - "post": { - "description": "Start a CLI session and create a custom token", - "operationId": "CreateUserToken", - "x-internal": true, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "custom_token" - ], - "properties": { - "custom_token": { - "type": "string", - "description": "Token to exchange for refresh token" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ], - "security": [ - { - "cookieAuth": [] - } - ] - } - }, - "/users/{user_id}": { - "delete": { - "description": "Delete user", - "operationId": "DeleteUser", - "parameters": [ - { - "$ref": "#/components/parameters/user_id" - } - ], - "x-internal": true, - "responses": { - "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/registry/auth": { - "get": { - "description": "Performs authentication and authorization for our image registry.", - "operationId": "AuthRegistryRequest", - "parameters": [ - { - "in": "header", - "name": "X-Meta-Plugin-Version", - "schema": { - "type": "string" - }, - "description": "Plugin version name", - "example": "v1.0.0" - }, - { - "in": "header", - "name": "X-Meta-User-Team-Name", - "schema": { - "type": "string" - }, - "description": "User's team name" - }, - { - "in": "query", - "name": "account", - "schema": { - "type": "string" - }, - "description": "Username used for `docker login`" - }, - { - "in": "query", - "name": "service", - "schema": { - "type": "string" - }, - "description": "Service requesting the JWT token" - }, - { - "in": "query", - "name": "scope", - "schema": { - "type": "string" - }, - "description": "Multi-value string containing the repository being access and the operation type (push/pull)" - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RegistryAuthToken" - } - } - }, - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/DockerError" - }, - "401": { - "$ref": "#/components/responses/DockerError" - }, - "404": { - "$ref": "#/components/responses/DockerError" - }, - "422": { - "$ref": "#/components/responses/DockerError" - }, - "500": { - "$ref": "#/components/responses/DockerError" - } - }, - "tags": [ - "registry" - ], - "security": [ - { - "basicAuth": [] - } - ] - } - }, - "/v2/teams/{team_name}/sync-destination-test-connections": { - "post": { - "description": "Create a test destination connection.", - "operationId": "CreateV2SyncDestinationTestConnection", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateSyncDestinationTestConnectionV2" - } - } - } - }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnectionV2" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/v2/teams/{team_name}/sync-destinations": { - "post": { - "description": "Create sync destination based on test connection.", - "operationId": "CreateV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateSyncDestinationV2" - } - } - } - }, - "responses": { - "200": { - "description": "Successful response indicating that an existing sync destination was replaced.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" - } - } - } - }, - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - }, - "get": { - "description": "List all sync destination definitions.", - "operationId": "GetV2SyncDestinations", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/sync_generic_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncDestinationV2" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/v2/teams/{team_name}/sync-destinations/{sync_destination_name}": { - "get": { - "description": "Get a single sync destination definition.", - "operationId": "GetV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - }, - "patch": { - "description": "Update a Sync Destination definition.", - "operationId": "PatchV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationUpdateV2" - } - } - } - }, - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestination" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - }, - "delete": { - "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", - "operationId": "DeleteV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], - "responses": { - "204": { - "description": "Deleted" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/teams/{team_name}/rbac/permissions": { - "get": { - "description": "List all permissions", - "operationId": "ListAllRBACPermissions", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/rbac_permissions_sort_bys" - }, - { - "$ref": "#/components/parameters/rbac_permissions_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter permissions by name or description." - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/RBACPermission" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "post": { - "description": "Create a permission", - "operationId": "CreateRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermissionCreate" - } - } - } - }, - "responses": { - "201": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermission" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - } - }, - "/teams/{team_name}/rbac/permissions/{permission_id}": { - "get": { - "description": "Get a permission", - "operationId": "GetRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_permission_id" - } - ], - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermission" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "patch": { - "description": "Update a permission", - "operationId": "UpdateRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_permission_id" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermissionUpdate" - } - } - } - }, - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermission" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "delete": { - "description": "Delete a permission", - "operationId": "DeleteRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_permission_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - } - }, - "/teams/{team_name}/rbac/roles": { - "get": { - "description": "List all roles", - "operationId": "ListAllRBACRoles", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/rbac_roles_sort_bys" - }, - { - "$ref": "#/components/parameters/rbac_roles_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter roles by name or description." - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/RBACRole" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "post": { - "description": "Create a role", - "operationId": "CreateRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRoleCreate" - } - } - } - }, - "responses": { - "201": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRole" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - } - }, - "/teams/{team_name}/rbac/roles/{role_id}": { - "get": { - "description": "Get a role", - "operationId": "GetRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_role_id" - } - ], - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRole" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "patch": { - "description": "Update a role (custom roles only)", - "operationId": "UpdateRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_role_id" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRoleUpdate" - } - } - } - }, - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRole" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - }, - "delete": { - "description": "Delete a role", - "operationId": "DeleteRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/rbac_role_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "rbac" - ] - } - } - }, - "components": { - "securitySchemes": { - "bearerAuth": { - "scheme": "bearer", - "type": "http" - }, - "basicAuth": { - "scheme": "basic", - "type": "http" - }, - "cookieAuth": { - "scheme": "cookie", - "type": "http" - } - }, - "parameters": { - "per_page": { - "description": "The number of results per page (max 1000).", - "in": "query", - "name": "per_page", - "required": false, - "schema": { - "default": 100, - "maximum": 1000, - "minimum": 1, - "type": "integer", - "format": "int64" - } - }, - "page": { - "description": "Page number of the results to fetch", - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 1, - "minimum": 1, - "type": "integer", - "format": "int64" - } - }, - "assetview_run_type": { - "name": "type", - "in": "query", - "description": "AssetView run type filters", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AssetViewRunType" - } - }, - "x-go-name": "AssetViewRunTypes" - }, - "team_name": { - "in": "path", - "name": "team_name", - "required": true, - "schema": { - "$ref": "#/components/schemas/TeamName" - } - }, - "user_id": { - "name": "user_id", - "in": "path", - "required": true, - "schema": { - "$ref": "#/components/schemas/UserID" - }, - "x-go-name": "UserID" - }, - "plugin_sort_by": { - "description": "The field to sort by", - "in": "query", - "name": "sort_by", - "required": false, - "schema": { - "enum": [ - "created_at", - "updated_at", - "name", - "downloads" - ], - "type": "string" - } - }, - "plugin_include_release_stages": { - "description": "Include these release stages in the response", - "in": "query", - "name": "include_release_stages", - "required": false, - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginReleaseStage" - } - } - }, - "plugin_exclude_release_stages": { - "description": "Exclude these release stages from the response", - "in": "query", - "name": "exclude_release_stages", - "required": false, - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "default": [ - "deprecated" - ], - "items": { - "$ref": "#/components/schemas/PluginReleaseStage" - } - } - }, - "plugin_kind": { - "in": "path", - "name": "plugin_kind", - "required": true, - "schema": { - "$ref": "#/components/schemas/PluginKind" - } - }, - "plugin_name": { - "in": "path", - "name": "plugin_name", - "required": true, - "schema": { - "$ref": "#/components/schemas/PluginName" - } - }, - "version_sort_by": { - "description": "The field to sort by", - "in": "query", - "name": "sort_by", - "required": false, - "schema": { - "enum": [ - "created_at" - ], - "type": "string" - } - }, - "include_drafts": { - "description": "Whether to include draft versions", - "in": "query", - "name": "include_drafts", - "required": false, - "schema": { - "type": "boolean" - } - }, - "include_fips": { - "description": "Whether to include fips versions", - "in": "query", - "name": "include_fips", - "required": false, - "schema": { - "type": "boolean" - } - }, - "include_prereleases": { - "description": "Whether to include prerelease versions", - "in": "query", - "name": "include_prereleases", - "required": false, - "schema": { - "type": "boolean" - } - }, - "version_filter": { - "in": "query", - "name": "version_filter", - "required": false, - "schema": { - "$ref": "#/components/schemas/VersionFilter" - } - }, - "version_name": { - "in": "path", - "name": "version_name", - "required": true, - "schema": { - "$ref": "#/components/schemas/VersionName" - } - }, - "target_name": { - "in": "path", - "name": "target_name", - "required": true, - "schema": { - "type": "string" - } - }, - "alert_states": { - "name": "state", - "in": "query", - "description": "Alert states", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/AlertState" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "AlertStates" - }, - "enabled": { - "name": "enabled", + "parameters": { + "per_page": { + "description": "The number of results per page (max 1000).", "in": "query", - "description": "Enabled", - "schema": { - "type": "boolean" - } - }, - "apikey_id": { - "name": "apikey_id", - "in": "path", - "required": true, - "schema": { - "$ref": "#/components/schemas/APIKeyID" - }, - "x-go-name": "APIKeyID" - }, - "connector_id": { - "name": "connector_id", - "in": "path", - "required": true, - "x-go-name": "ConnectorID", + "name": "per_page", + "required": false, "schema": { - "$ref": "#/components/schemas/ConnectorID" + "default": 100, + "maximum": 1000, + "minimum": 1, + "type": "integer", + "format": "int64" } }, - "conversation_id": { - "name": "conversation_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the chat conversation", - "x-go-name": "ConversationID" - }, - "custom_columns_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/CustomColumnSortBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "CustomColumnSortBys" - }, - "custom_columns_sort_dirs": { - "name": "sort_dir", - "in": "query", - "description": "Custom column sort direction options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/CustomColumnSortDirection" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "CustomColumnSortDirections" - }, - "custom_column_id": { - "in": "path", - "name": "custom_column_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/CustomColumnID" - }, - "x-go-name": "CustomColumnID" - }, - "filter_tags": { - "name": "tag", - "in": "query", - "description": "Filter tags", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - } - }, - "x-go-name": "FilterTags" - }, - "filter_name_filter": { - "name": "name_filter", + "page": { + "description": "Page number of the results to fetch", "in": "query", + "name": "page", "required": false, "schema": { - "description": "Filter by filter name", - "type": "string" + "default": 1, + "minimum": 1, + "type": "integer", + "format": "int64" } }, - "filter_expression_filter": { - "name": "expression_filter", + "plugin_sort_by": { + "description": "The field to sort by", "in": "query", + "name": "sort_by", "required": false, "schema": { - "description": "Filter by filter expression", + "enum": [ + "created_at", + "updated_at", + "name", + "downloads" + ], "type": "string" } }, - "filter_id": { - "in": "path", - "name": "filter_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/FilterID" - }, - "x-go-name": "FilterID" - }, - "email_basic": { - "in": "path", - "name": "email", - "required": true, - "schema": { - "type": "string", - "example": "user@example.com" - } - }, - "notification_destination_id": { - "in": "path", - "name": "notification_destination_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/NotificationDestinationID" - }, - "x-go-name": "NotificationDestinationID" - }, - "onboarding_id": { - "name": "onboarding_id", - "in": "path", - "required": true, - "x-go-name": "OnboardingID", - "schema": { - "$ref": "#/components/schemas/OnboardingID" - } - }, - "aws_orgunit_id": { - "name": "aws_orgunit_id", - "in": "path", - "required": true, - "x-go-name": "OrganizationalUnitID", - "schema": { - "$ref": "#/components/schemas/OrganizationalUnitID" - } - }, - "include_private": { - "description": "Whether to include private plugins", + "plugin_include_release_stages": { + "description": "Include these release stages in the response", "in": "query", - "name": "include_private", + "name": "include_release_stages", "required": false, - "schema": { - "type": "boolean" - } - }, - "plugin_team": { - "in": "path", - "name": "plugin_team", - "required": true, - "schema": { - "$ref": "#/components/schemas/TeamName" - } - }, - "platform_policies_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PlatformPolicySortBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "PlatformPolicySortBys" - }, - "platform_policies_sort_dirs": { - "name": "sort_dir", - "in": "query", - "description": "Platform policies sort direction options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PlatformPolicySortDirection" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "PlatformPolicySortDirections" - }, - "platform_policy_frameworks_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PlatformPolicyFrameworkSortBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "PlatformPolicyFrameworkSortBys" - }, - "platform_policy_rules_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PlatformPolicyRuleSortBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "PlatformPolicyRuleSortBys" - }, - "platform_policy_rule_details_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/PlatformPolicyRuleDetailSortBy" + "$ref": "#/components/schemas/PluginReleaseStage" } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "PlatformPolicyRuleDetailSortBys" + } }, - "query_tags": { - "name": "tag", + "plugin_exclude_release_stages": { + "description": "Exclude these release stages from the response", "in": "query", - "description": "Query tags", + "name": "exclude_release_stages", + "required": false, "allowEmptyValue": true, "explode": true, "schema": { "type": "array", + "default": [ + "deprecated" + ], "items": { - "$ref": "#/components/schemas/QueryTag" + "$ref": "#/components/schemas/PluginReleaseStage" } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "QueryTags" + } }, - "query_name_filter": { - "name": "name_filter", - "in": "query", - "required": false, + "team_name": { + "in": "path", + "name": "team_name", + "required": true, "schema": { - "description": "Filter by query name.", - "type": "string" + "$ref": "#/components/schemas/TeamName" } }, - "query_filter": { - "name": "query_filter", - "in": "query", - "required": false, + "plugin_kind": { + "in": "path", + "name": "plugin_kind", + "required": true, "schema": { - "description": "Filter by query", - "type": "string" + "$ref": "#/components/schemas/PluginKind" } }, - "alert_configured": { - "name": "alert_configured", - "in": "query", - "description": "Alert configured", + "plugin_name": { + "in": "path", + "name": "plugin_name", + "required": true, "schema": { - "type": "boolean" + "$ref": "#/components/schemas/PluginName" } }, - "alert_message_filter": { - "name": "alert_message_filter", + "version_sort_by": { + "description": "The field to sort by", "in": "query", + "name": "sort_by", "required": false, "schema": { - "description": "Filter by alert message.", + "enum": [ + "created_at" + ], "type": "string" } }, - "alert_enabled": { - "name": "alert_enabled", + "include_drafts": { + "description": "Whether to include draft versions", "in": "query", - "description": "Alert enabled", + "name": "include_drafts", + "required": false, "schema": { "type": "boolean" } }, - "table_selects": { - "name": "select", + "include_fips": { + "description": "Whether to include fips versions", "in": "query", - "description": "Table selects. This filters the columns that are returned in the result set.", - "allowEmptyValue": true, - "explode": true, + "name": "include_fips", + "required": false, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableSelect" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "Selects" + "type": "boolean" + } }, - "table_filter_mode": { - "name": "filter_mode", + "include_prereleases": { + "description": "Whether to include prerelease versions", "in": "query", - "description": "Table filter mode.\n\nSmart mode switches between column and search mode based on the filtered table and\n\nSearch mode allows searching deeply nested data but is not available on all tables as it requires a separate indexing step.\nSearch mode is only available on resource tables or queries derived from resource tables results that contain _cq_id and _cq_source_id.\nSearch mode may also be used against cloud_assets but it will only return results from resource tables.\n\nColumn mode searches purely using the columns in the table.\nIt will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables.\n", + "name": "include_prereleases", + "required": false, "schema": { - "type": "string", - "enum": [ - "smart", - "search", - "column" - ], - "default": "smart" + "type": "boolean" } }, - "table_filters": { - "name": "filter", + "version_filter": { "in": "query", - "description": "Table filters. This filters the rows that are returned in the result set.", - "allowEmptyValue": true, - "explode": true, + "name": "version_filter", + "required": false, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterExpression" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "Filters" + "$ref": "#/components/schemas/VersionFilter" + } }, - "table_filter_ids": { - "name": "filter_id", - "in": "query", - "description": "Table filter IDs. These should be valid Saved Filter IDs. These filters\nwill be applied to the query results before returning them.\n", - "explode": true, + "version_name": { + "in": "path", + "name": "version_name", + "required": true, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterID" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "FilterIDs" + "$ref": "#/components/schemas/VersionName" + } }, - "table_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Table sort by options. This sorts the rows that are returned in the result set.", - "allowEmptyValue": true, - "explode": true, + "target_name": { + "in": "path", + "name": "target_name", + "required": true, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableSortBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "SortBys" + "type": "string" + } }, - "table_sort_dirs": { - "name": "sort_dir", + "alert_states": { + "name": "state", "in": "query", - "description": "Table sort direction options. This sorts the rows that are returned in the result set.", + "description": "Alert states", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/TableSortDirection" + "$ref": "#/components/schemas/AlertState" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SortDirections" + "x-go-name": "AlertStates" }, - "table_group_bys": { - "name": "group_by", + "enabled": { + "name": "enabled", "in": "query", - "description": "Table group by options. This groups the rows that are returned in the result set by the given columns.", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableGroupBy" - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "GroupBys" - }, - "query_id": { - "in": "path", - "name": "query_id", - "required": true, + "description": "Enabled", "schema": { - "$ref": "#/components/schemas/QueryID" - }, - "x-go-name": "QueryID" + "type": "boolean" + } }, - "report_sort_bys": { - "name": "sort_by", + "query_tags": { + "name": "tag", "in": "query", - "description": "Sort by options", + "description": "Query tags", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/ReportSortBy" + "$ref": "#/components/schemas/QueryTag" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "ReportSortBys" + "x-go-name": "QueryTags" }, - "report_sort_dirs": { - "name": "sort_dir", + "policy_status": { "in": "query", - "description": "Report sort direction options", - "allowEmptyValue": true, - "explode": true, + "name": "status", + "required": false, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ReportSortDirection" - } + "$ref": "#/components/schemas/PolicyStatus" }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "ReportSortDirections" + "x-go-name": "PolicyStatus" }, - "report_templates_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, + "policy_id": { + "in": "path", + "name": "policy_id", + "required": true, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ReportTemplateSortBy" - } + "$ref": "#/components/schemas/PolicyID" }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "ReportTemplateSortBys" + "x-go-name": "PolicyID" }, - "report_templates_sort_dirs": { - "name": "sort_dir", - "in": "query", - "description": "Report template sort direction options", - "allowEmptyValue": true, - "explode": true, + "policy_group_id": { + "in": "path", + "name": "policy_group_id", + "required": true, "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ReportTemplateSortDirection" - } + "$ref": "#/components/schemas/PolicyGroupID" }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "ReportTemplateSortDirections" + "x-go-name": "PolicyGroupID" }, - "sync_destination_test_connection_id": { - "name": "sync_destination_test_connection_id", + "apikey_id": { + "name": "apikey_id", "in": "path", "required": true, "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnectionID" + "$ref": "#/components/schemas/APIKeyID" }, - "x-go-name": "SyncDestinationTestConnectionID" - }, - "download_file": { - "description": "Whether to generate a downloadable file for the response.", - "in": "query", - "name": "download", - "required": false, - "schema": { - "type": "boolean" - } - }, - "sync_name_filter": { - "name": "filter", - "in": "query", - "required": false, + "x-go-name": "APIKeyID" + }, + "conversation_id": { + "name": "conversation_id", + "in": "path", + "required": true, "schema": { - "description": "Filter by name or display name", "type": "string", - "pattern": "^[a-zA-Z\\p{L}\\p{N}_ \\-']*$", - "x-pattern-message": "can contain only letters, numbers, spaces, hyphens, underscores, and apostrophes" - } + "format": "uuid" + }, + "description": "ID of the chat conversation", + "x-go-name": "ConversationID" }, - "sync_generic_sort_bys": { + "custom_columns_sort_bys": { "name": "sort_by", "in": "query", "description": "Sort by options", @@ -15482,219 +11205,259 @@ "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncGenericSortBy" + "$ref": "#/components/schemas/CustomColumnSortBy" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncGenericSortBys" + "x-go-name": "CustomColumnSortBys" }, - "sync_sort_dirs": { + "custom_columns_sort_dirs": { "name": "sort_dir", "in": "query", - "description": "Sync sort direction options", + "description": "Custom column sort direction options", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncSortDirection" + "$ref": "#/components/schemas/CustomColumnSortDirection" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncSortDirections" + "x-go-name": "CustomColumnSortDirections" }, - "sync_destination_name": { - "name": "sync_destination_name", + "custom_column_id": { "in": "path", + "name": "custom_column_id", "required": true, "schema": { - "description": "Unique name of the sync destination", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncDestinationName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - } + "$ref": "#/components/schemas/CustomColumnID" + }, + "x-go-name": "CustomColumnID" }, - "sync_sort_bys": { - "name": "sort_by", + "filter_tags": { + "name": "tag", "in": "query", - "description": "Sort by options", + "description": "Filter tags", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncSortBy" + "$ref": "#/components/schemas/FilterTag" } }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncSortBys" + "x-go-name": "FilterTags" }, - "migration_filter": { - "name": "migration_filter", + "filter_name_filter": { + "name": "name_filter", "in": "query", "required": false, "schema": { - "description": "Filter by migration", - "type": "boolean" + "description": "Filter by filter name", + "type": "string" } }, - "sync_test_connection_id": { - "name": "sync_test_connection_id", - "in": "path", - "required": true, + "filter_expression_filter": { + "name": "expression_filter", + "in": "query", + "required": false, "schema": { - "$ref": "#/components/schemas/SyncTestConnectionID" + "description": "Filter by filter expression", + "type": "string" } }, - "sync_source_test_connection_id": { - "name": "sync_source_test_connection_id", + "filter_id": { "in": "path", + "name": "filter_id", "required": true, "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnectionID" + "$ref": "#/components/schemas/FilterID" }, - "x-go-name": "SyncSourceTestConnectionID" + "x-go-name": "FilterID" }, - "sync_name": { - "name": "sync_name", + "notification_destination_id": { "in": "path", + "name": "notification_destination_id", "required": true, "schema": { - "description": "Unique name of the sync", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + "$ref": "#/components/schemas/NotificationDestinationID" } }, - "sync_source_name": { - "name": "sync_source_name", + "onboarding_id": { + "name": "onboarding_id", "in": "path", "required": true, + "x-go-name": "OnboardingID", "schema": { - "description": "Unique name of the sync source", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncSourceName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + "$ref": "#/components/schemas/OnboardingID" } }, - "sync_transformer_name": { - "name": "sync_transformer_name", + "aws_orgunit_id": { + "name": "aws_orgunit_id", "in": "path", "required": true, + "x-go-name": "OrganizationalUnitID", "schema": { - "description": "Unique name of the sync transformer", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncTransformerName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + "$ref": "#/components/schemas/OrganizationalUnitID" } }, - "sync_upgrades_sort_bys": { - "name": "sort_by", + "query_name_filter": { + "name": "name_filter", "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, + "required": false, "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "kind", - "path", - "prev_version", - "new_version", - "created_at" - ] - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncUpgradesSortBys" + "description": "Filter by query name.", + "type": "string" + } }, - "sync_upgrades_path_filter": { - "name": "path", + "query_filter": { + "name": "query_filter", "in": "query", "required": false, "schema": { - "$ref": "#/components/schemas/SyncPluginPath", - "example": "cloudquery/aws", - "description": "Filter by plugin path" + "description": "Filter by query", + "type": "string" } }, - "sync_upgrades_kind_filter": { - "name": "kind", + "alert_configured": { + "name": "alert_configured", "in": "query", - "required": false, + "description": "Alert configured", "schema": { - "$ref": "#/components/schemas/PluginKind", - "description": "Filter by plugin kind" + "type": "boolean" } }, - "sync_upgrades_platform_version_filter": { - "name": "platform_version", + "alert_message_filter": { + "name": "alert_message_filter", "in": "query", "required": false, "schema": { - "type": "string", - "example": "v1.1.0", - "description": "Filter by platform version" + "description": "Filter by alert message.", + "type": "string" } }, - "sync_run_id": { - "name": "sync_run_id", - "in": "path", - "required": true, + "alert_enabled": { + "name": "alert_enabled", + "in": "query", + "description": "Alert enabled", "schema": { - "$ref": "#/components/schemas/SyncRunID" + "type": "boolean" } }, - "table_name": { - "in": "path", - "name": "table_name", - "required": true, + "table_selects": { + "name": "select", + "in": "query", + "description": "Table selects. This filters the columns that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, "schema": { - "$ref": "#/components/schemas/TableName" + "type": "array", + "items": { + "$ref": "#/components/schemas/TableSelect" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "Selects" + }, + "table_filter_mode": { + "name": "filter_mode", + "in": "query", + "description": "Table filter mode.\n\nSmart mode switches between column and search mode based on the filtered table and\n\nSearch mode allows searching deeply nested data but is not available on all tables as it requires a separate indexing step.\nSearch mode is only available on resource tables or queries derived from resource tables results that contain _cq_id and _cq_source_id.\nSearch mode may also be used against cloud_assets but it will only return results from resource tables.\n\nColumn mode searches purely using the columns in the table.\nIt will work on all table results but it is not optimized for arbitrary substring searches and so may be slow on larger tables.\n", + "schema": { + "type": "string", + "enum": [ + "smart", + "search", + "column" + ], + "default": "smart" } }, - "table_row_id": { - "in": "path", - "name": "table_row_id", - "required": true, + "table_filters": { + "name": "filter", + "in": "query", + "description": "Table filters. This filters the rows that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/FilterExpression" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "Filters" + }, + "table_filter_ids": { + "name": "filter_id", + "in": "query", + "description": "Table filter IDs. These should be valid Saved Filter IDs. These filters\nwill be applied to the query results before returning them.\n", + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/FilterID" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "FilterIDs" + }, + "table_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Table sort by options. This sorts the rows that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableSortBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SortBys" + }, + "table_sort_dirs": { + "name": "sort_dir", + "in": "query", + "description": "Table sort direction options. This sorts the rows that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, "schema": { - "$ref": "#/components/schemas/TableRowID" - } + "type": "array", + "items": { + "$ref": "#/components/schemas/TableSortDirection" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SortDirections" }, - "table_column_name_filter": { - "name": "filter", + "table_group_bys": { + "name": "group_by", "in": "query", - "required": false, + "description": "Table group by options. This groups the rows that are returned in the result set by the given columns.", + "allowEmptyValue": true, + "explode": true, "schema": { - "description": "Filter by column name", - "type": "string" - } + "type": "array", + "items": { + "$ref": "#/components/schemas/TableGroupBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "GroupBys" }, - "column_name": { + "query_id": { "in": "path", - "name": "column_name", + "name": "query_id", "required": true, "schema": { - "description": "The name of a table column.", - "type": "string" - } - }, - "table_column_value_filter": { - "name": "filter", - "in": "query", - "required": false, - "schema": { - "description": "Filter by column value.", - "type": "string" - } + "$ref": "#/components/schemas/QueryID" + }, + "x-go-name": "QueryID" }, - "rbac_permissions_sort_bys": { + "report_sort_bys": { "name": "sort_by", "in": "query", "description": "Sort by options", @@ -15703,37 +11466,28 @@ "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/RBACPermissionSortBy" + "$ref": "#/components/schemas/ReportSortBy" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACPermissionSortBys" + "x-go-name": "ReportSortBys" }, - "rbac_permissions_sort_dirs": { + "report_sort_dirs": { "name": "sort_dir", "in": "query", - "description": "Sort direction options", + "description": "Report sort direction options", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/RBACPermissionSortDirection" + "$ref": "#/components/schemas/ReportSortDirection" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACPermissionSortDirections" - }, - "rbac_permission_id": { - "in": "path", - "name": "permission_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/RBACPermissionID" - }, - "x-go-name": "RBACPermissionID" + "x-go-name": "ReportSortDirections" }, - "rbac_roles_sort_bys": { + "report_templates_sort_bys": { "name": "sort_by", "in": "query", "description": "Sort by options", @@ -15742,550 +11496,406 @@ "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/RBACRoleSortBy" + "$ref": "#/components/schemas/ReportTemplateSortBy" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACRoleSortBys" + "x-go-name": "ReportTemplateSortBys" }, - "rbac_roles_sort_dirs": { + "report_templates_sort_dirs": { "name": "sort_dir", "in": "query", - "description": "Sort direction options", + "description": "Report template sort direction options", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/RBACRoleSortDirection" + "$ref": "#/components/schemas/ReportTemplateSortDirection" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACRoleSortDirections" + "x-go-name": "ReportTemplateSortDirections" }, - "rbac_role_id": { + "sync_destination_test_connection_id": { + "name": "sync_destination_test_connection_id", "in": "path", - "name": "role_id", "required": true, "schema": { - "$ref": "#/components/schemas/RBACCustomRoleID" + "$ref": "#/components/schemas/SyncDestinationTestConnectionID" }, - "x-go-name": "RBACCustomRoleID" - } - }, - "schemas": { - "UserName": { - "description": "The unique name for the user.", - "minLength": 1, - "maxLength": 255, - "pattern": "^[a-zA-Z\\p{L}][a-zA-Z\\p{L} \\-']*$", - "x-pattern-message": "can contain only letters, spaces, hyphens, and apostrophes, starting with a letter", - "type": "string", - "example": "Sarah O'Connor" + "x-go-name": "SyncDestinationTestConnectionID" }, - "User": { - "additionalProperties": false, - "description": "CloudQuery User", - "properties": { - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "id": { - "description": "ID of the User", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "ID" - }, - "email": { - "type": "string", - "example": "user@example.com" - }, - "name": { - "$ref": "#/components/schemas/UserName" - }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "type": "string", - "format": "date-time" - }, - "profile_image_url": { - "type": "string", - "description": "Profile image URL of user", - "x-go-name": "ProfileImageURL" - }, - "last_login_at": { - "type": "string", - "format": "date-time" + "download_file": { + "description": "Whether to generate a downloadable file for the response.", + "in": "query", + "name": "download", + "required": false, + "schema": { + "type": "boolean" + } + }, + "sync_name_filter": { + "name": "filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by name or display name", + "type": "string", + "pattern": "^[a-zA-Z\\p{L}\\p{N}_ \\-']*$", + "x-pattern-message": "can contain only letters, numbers, spaces, hyphens, underscores, and apostrophes" + } + }, + "sync_generic_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncGenericSortBy" } }, - "required": [ - "id", - "email" - ], - "title": "CloudQuery User", - "type": "object" + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncGenericSortBys" }, - "AuditLogEvent": { - "type": "object", - "required": [ - "id", - "user", - "event_type", - "created_at", - "user_ip_address" - ], - "properties": { - "id": { - "type": "string", - "format": "uuid", - "description": "The unique identifier of the audit log event" - }, - "user": { - "$ref": "#/components/schemas/User", - "description": "The user who performed the action" - }, - "user_ip_address": { - "type": "string", - "description": "The IP address of the user who performed the action" - }, - "team_name": { - "type": "string", - "description": "The name of the team associated with the event", - "nullable": true - }, - "event_type": { - "type": "string", - "description": "The type of event that was logged" - }, - "entity_display_name": { - "type": "string", - "description": "The display name of the entity that was affected", - "nullable": true - }, - "event_details": { - "type": "object", - "description": "Additional details about the event", - "additionalProperties": true - }, - "is_success": { - "type": "boolean", - "description": "Whether the event was successful" - }, - "created_at": { - "type": "string", - "format": "date-time", - "description": "The timestamp when the event was created" + "sync_sort_dirs": { + "name": "sort_dir", + "in": "query", + "description": "Sync sort direction options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncSortDirection" } - } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncSortDirections" }, - "ListMetadata": { - "required": [ - "page_size" - ], - "properties": { - "total_count": { - "type": "integer" - }, - "last_page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "time_ms": { - "type": "integer" - } + "sync_destination_name": { + "name": "sync_destination_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync destination", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncDestinationName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" } }, - "BasicError": { - "additionalProperties": false, - "description": "Basic Error", - "required": [ - "message", - "status" - ], - "properties": { - "message": { - "type": "string" - }, - "status": { - "type": "integer" + "sync_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncSortBy" } }, - "title": "Basic Error", - "type": "object" + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncSortBys" }, - "FieldError": { - "allOf": [ - { - "$ref": "#/components/schemas/BasicError" - }, - { - "properties": { - "errors": { - "items": { - "type": "string" - }, - "type": "array" - }, - "field_errors": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - } - }, - "type": "object" - } - ] + "migration_filter": { + "name": "migration_filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by migration", + "type": "boolean" + } }, - "AssetViewRunType": { - "description": "Type of assetview run", - "type": "string", - "enum": [ - "client_table", - "s3_source" - ] + "sync_test_connection_id": { + "name": "sync_test_connection_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncTestConnectionID" + } }, - "AssetViewRun": { - "type": "object", - "required": [ - "id", - "type", - "created_at" - ], - "properties": { - "id": { - "description": "ID of the run", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "ID" - }, - "type": { - "$ref": "#/components/schemas/AssetViewRunType" - }, - "triggered_by": { - "description": "The user who triggered the run", - "type": "string" - }, - "error_message": { - "description": "The error message if the run failed", - "type": "string" - }, - "created_at": { - "description": "The time the run was created", - "type": "string", - "format": "date-time", - "example": "2020-01-01T00:00:00Z" - }, - "finished_at": { - "description": "The time the run was finished", - "type": "string", - "format": "date-time", - "example": "2020-01-01T00:00:00Z" - } + "sync_source_test_connection_id": { + "name": "sync_source_test_connection_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncSourceTestConnectionID" + }, + "x-go-name": "SyncSourceTestConnectionID" + }, + "sync_name": { + "name": "sync_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" } }, - "SAMLConfig": { - "title": "SAML Configuration", - "type": "object", - "additionalProperties": false, - "required": [ - "platform_certificate_download_url", - "enabled", - "can_enable" - ], - "properties": { - "platform_base_url": { - "type": "string", - "description": "Base URL to the platform.", - "format": "url", - "x-go-name": "PlatformBaseURL" - }, - "platform_sso_url": { - "type": "string", - "description": "SAML service URL. Only available after `platform_base_url` is set.", - "format": "url", - "x-go-name": "PlatformSSOURL" - }, - "platform_entity_id": { - "type": "string", - "description": "SAML Entity ID. Only available after `platform_base_url` is set.", - "x-go-name": "PlatformEntityID" - }, - "platform_metadata_download_url": { - "type": "string", - "description": "URL to download platform metadata. Only available after `platform_base_url` is set.", - "format": "url", - "x-go-name": "PlatformMetadataDownloadURL" - }, - "platform_certificate_download_url": { - "type": "string", - "description": "Platform Certificate download URL", - "format": "url", - "x-go-name": "PlatformCertificateDownloadURL" - }, - "metadata_url": { - "type": "string", - "description": "Metadata URL from identity provider. Mutually exclusive with `metadata_xml`", - "format": "url", - "x-go-name": "MetadataURL" - }, - "metadata_xml": { - "type": "string", - "description": "Metadata file contents from identity provider. Mutually exclusive with `metadata_url`", - "format": "url", - "x-go-name": "MetadataXML" - }, - "logout_url": { - "type": "string", - "description": "Logout URL from identity provider", - "format": "url", - "x-go-name": "LogoutURL" - }, - "role_group_key": { - "type": "string", - "description": "Role group key name", - "example": "groups" - }, - "role_mappings": { - "type": "object", - "description": "Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group.", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "example": { - "admins-rw": [ - "admin:write", - "admin:read" - ], - "admins-ro": [ - "admin:read" - ], - "general-rw": [ - "general:write", - "general:read" - ], - "general-ro": [ - "general:read" - ] - }, - "x-go-type-skip-optional-pointer": true - }, - "default_roles": { - "type": "array", - "description": "Default roles for new users who are not in any group", - "items": { - "type": "string" - }, - "x-go-type-skip-optional-pointer": true, - "x-omitempty": false - }, - "disable_access_if_no_role_group": { - "type": "boolean", - "description": "Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in." - }, - "enabled": { - "type": "boolean", - "description": "Whether SAML is enabled" - }, - "can_enable": { - "type": "boolean", - "description": "Whether SAML can be enabled" - } + "sync_source_name": { + "name": "sync_source_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync source", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncSourceName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" } }, - "SAMLConfigUpdate": { - "title": "SAML Configuration Update", - "type": "object", - "additionalProperties": false, - "properties": { - "platform_base_url": { - "type": "string", - "description": "Base URL to the platform. This should be set first. https recommended.", - "format": "url", - "x-go-name": "PlatformBaseURL" - }, - "metadata_url": { - "type": "string", - "description": "Metadata URL from identity provider. Mutually exclusive with `metadata_xml`", - "format": "url", - "x-go-name": "MetadataURL" - }, - "metadata_xml": { - "type": "string", - "description": "Metadata file contents from identity provider. Mutually exclusive with `metadata_url`", - "format": "url", - "x-go-name": "MetadataXML" - }, - "logout_url": { - "type": "string", - "description": "Logout URL from identity provider", - "format": "url", - "x-go-name": "LogoutURL" - }, - "role_group_key": { + "sync_transformer_name": { + "name": "sync_transformer_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync transformer", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncTransformerName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + } + }, + "sync_upgrades_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { "type": "string", - "description": "Role group key name" - }, - "role_mappings": { - "type": "object", - "description": "Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group.", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "example": { - "admins-rw": [ - "admin:write", - "admin:read" - ], - "admins-ro": [ - "admin:read" - ], - "general-rw": [ - "general:write", - "general:read" - ], - "general-ro": [ - "general:read" - ] - } - }, - "default_roles": { - "type": "array", - "description": "Default roles for new users who are not in any group", - "items": { - "type": "string" - } - }, - "disable_access_if_no_role_group": { - "type": "boolean", - "description": "Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in." - }, - "enabled": { - "type": "boolean", - "description": "Whether to enable or disable SAML" + "enum": [ + "kind", + "path", + "prev_version", + "new_version", + "created_at" + ] } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncUpgradesSortBys" + }, + "sync_upgrades_path_filter": { + "name": "path", + "in": "query", + "required": false, + "schema": { + "$ref": "#/components/schemas/SyncPluginPath", + "example": "cloudquery/aws", + "description": "Filter by plugin path" } }, - "PlatformSettings": { - "type": "object", - "description": "Platform settings definition", - "required": [ - "enforce_mfa" - ], - "properties": { - "enforce_mfa": { - "type": "boolean", - "description": "Whether or not to require MFA for all users", - "default": false - } + "sync_upgrades_kind_filter": { + "name": "kind", + "in": "query", + "required": false, + "schema": { + "$ref": "#/components/schemas/PluginKind", + "description": "Filter by plugin kind" } }, - "PlatformSettingsUpdate": { - "type": "object", - "description": "Platform settings partial update", - "properties": { - "enforce_mfa": { - "type": "boolean", - "description": "Whether or not to require MFA for all users", - "default": false + "sync_upgrades_platform_version_filter": { + "name": "platform_version", + "in": "query", + "required": false, + "schema": { + "type": "string", + "example": "v1.1.0", + "description": "Filter by platform version" + } + }, + "sync_run_id": { + "name": "sync_run_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncRunID" + } + }, + "sync_run_table_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sync run table sort by options. This sorts the rows that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncRunTableSortBy" } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncRunTableSortBys" + }, + "table_name": { + "in": "path", + "name": "table_name", + "required": true, + "schema": { + "$ref": "#/components/schemas/TableName" } }, - "TeamName": { - "description": "The unique name for the team.", - "maxLength": 255, - "pattern": "^[a-z](-?[a-z0-9]+)+$", - "type": "string", - "example": "cloudquery", - "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" + "table_row_id": { + "in": "path", + "name": "table_row_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/TableRowID" + } }, - "TeamPlan": { - "description": "The plan the team is on (trial is deprecated)", - "type": "string", - "enum": [ - "free", - "paid", - "enterprise", - "trial" - ] + "table_column_name_filter": { + "name": "filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by column name", + "type": "string" + } }, - "Team": { - "additionalProperties": false, - "description": "CloudQuery Team", - "properties": { - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "name": { - "$ref": "#/components/schemas/TeamName" - }, - "plan": { - "$ref": "#/components/schemas/TeamPlan" - }, - "plan_end_time": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "is_trial_active": { - "type": "boolean", - "example": false - }, - "trial_end_time": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "display_name": { - "description": "The team's display name", - "maxLength": 255, - "type": "string", - "example": "CloudQuery" - }, - "internal": { - "example": false, - "type": "boolean" + "column_name": { + "in": "path", + "name": "column_name", + "required": true, + "schema": { + "description": "The name of a table column.", + "type": "string" + } + }, + "table_column_value_filter": { + "name": "filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by column value.", + "type": "string" + } + }, + "user_id": { + "name": "user_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/UserID" + }, + "x-go-name": "UserID" + }, + "rbac_permissions_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACPermissionSortBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "RBACPermissionSortBys" + }, + "rbac_permissions_sort_dirs": { + "name": "sort_dir", + "in": "query", + "description": "Sort direction options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACPermissionSortDirection" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "RBACPermissionSortDirections" + }, + "rbac_permission_id": { + "in": "path", + "name": "permission_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/RBACPermissionID" + }, + "x-go-name": "RBACPermissionID" + }, + "rbac_roles_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACRoleSortBy" } }, - "required": [ - "name", - "display_name", - "plan", - "is_trial_active", - "internal" - ], - "title": "Team", - "type": "object" + "x-go-type-skip-optional-pointer": true, + "x-go-name": "RBACRoleSortBys" + }, + "rbac_roles_sort_dirs": { + "name": "sort_dir", + "in": "query", + "description": "Sort direction options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACRoleSortDirection" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "RBACRoleSortDirections" }, - "RBACDefaultRole": { - "description": "Default RBAC roles", + "rbac_role_id": { + "in": "path", + "name": "role_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/RoleID" + }, + "x-go-name": "RoleID" + }, + "plugin_team": { + "in": "path", + "name": "plugin_team", + "required": true, + "schema": { + "$ref": "#/components/schemas/TeamName" + } + } + }, + "schemas": { + "UserName": { + "description": "The unique name for the user.", + "minLength": 1, + "maxLength": 255, + "pattern": "^[a-zA-Z\\p{L}][a-zA-Z\\p{L} \\-']*$", + "x-pattern-message": "can contain only letters, spaces, hyphens, and apostrophes, starting with a letter", "type": "string", - "enum": [ - "admin:write", - "admin:read", - "general:read", - "general:write" - ] + "example": "Sarah O'Connor" }, - "RBACCustomRoleID": { - "description": "The unique ID for the custom role.", + "UserProvider": { + "title": "LocalUserProvider", "type": "string", - "format": "uuid", - "x-go-name": "RBACCustomRoleID" + "enum": [ + "local", + "saml" + ], + "default": "local" }, "RBACPermissionID": { "description": "The unique ID for the data permission.", @@ -16366,9 +11976,30 @@ } } }, - "RBACRole": { + "RoleType": { + "type": "string", + "enum": [ + "admin:write", + "admin:read", + "general:read", + "general:write", + "ci", + "schema-only", + "custom" + ], + "x-enum-varnames": [ + "AdminWrite", + "AdminRead", + "GeneralRead", + "GeneralWrite", + "CI", + "SchemaOnly", + "Custom" + ] + }, + "Role": { "type": "object", - "description": "Custom RBAC role", + "description": "Role", "required": [ "id", "name", @@ -16376,11 +12007,15 @@ "permissions", "created_by", "created_at", - "updated_at" + "updated_at", + "type" ], "properties": { "id": { - "$ref": "#/components/schemas/RBACCustomRoleID" + "description": "The unique ID for the role.", + "type": "string", + "format": "uuid", + "x-go-name": "ID" }, "name": { "type": "string" @@ -16406,137 +12041,189 @@ "example": "2017-07-14T16:53:42Z", "format": "date-time", "type": "string" + }, + "type": { + "$ref": "#/components/schemas/RoleType" } } }, - "MembershipWithUser": { + "User": { "additionalProperties": false, + "description": "User", "properties": { - "roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACDefaultRole" - } + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "id": { + "description": "ID of the User", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "ID" + }, + "email": { + "type": "string", + "example": "user@example.com" + }, + "name": { + "$ref": "#/components/schemas/UserName" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "type": "string", + "format": "date-time" + }, + "profile_image_url": { + "type": "string", + "description": "Profile image URL of user", + "x-go-name": "ProfileImageURL" + }, + "last_login_at": { + "type": "string", + "format": "date-time" + }, + "provider": { + "$ref": "#/components/schemas/UserProvider" + }, + "tracking_opted_in": { + "type": "boolean", + "description": "Whether anonymous user tracking was opted into" + }, + "mfa_configured": { + "type": "boolean", + "description": "Whether the user has MFA configured", + "x-go-name": "MFAConfigured" }, - "customRoles": { + "roles": { "type": "array", "items": { - "$ref": "#/components/schemas/RBACRole" + "$ref": "#/components/schemas/Role" } }, - "user": { - "$ref": "#/components/schemas/User" + "enabled": { + "type": "boolean", + "description": "Whether the user is enabled" } }, "required": [ - "roles", - "user" + "id", + "email", + "enabled", + "provider", + "mfa_configured", + "roles" ], - "title": "CloudQuery User Membership", + "title": "User", "type": "object" }, - "LocalUserProvider": { - "title": "LocalUserProvider", - "type": "string", - "enum": [ - "local", - "saml" + "AuditLogEvent": { + "type": "object", + "required": [ + "id", + "user", + "event_type", + "created_at", + "user_ip_address" ], - "default": "local" - }, - "LocalUser": { - "allOf": [ - { - "$ref": "#/components/schemas/User" + "properties": { + "id": { + "type": "string", + "format": "uuid", + "description": "The unique identifier of the audit log event" }, - { + "user": { + "$ref": "#/components/schemas/User", + "description": "The user who performed the action" + }, + "user_ip_address": { + "type": "string", + "description": "The IP address of the user who performed the action" + }, + "event_type": { + "type": "string", + "description": "The type of event that was logged" + }, + "entity_display_name": { + "type": "string", + "description": "The display name of the entity that was affected", + "nullable": true + }, + "event_details": { "type": "object", - "required": [ - "roles", - "enabled", - "provider" - ], - "properties": { - "roles": { - "description": "Global roles for the user", - "type": "array", - "items": { - "type": "string", - "enum": [ - "admin:write", - "admin:read" - ] - }, - "x-go-type": "[]string" - }, - "enabled": { - "type": "boolean" - }, - "provider": { - "$ref": "#/components/schemas/LocalUserProvider" - }, - "tracking_opted_in": { - "type": "boolean", - "description": "Whether anonymous user tracking was opted into" - }, - "mfa_configured": { - "type": "boolean", - "description": "Whether the user has MFA configured", - "x-go-name": "MFAConfigured" - } - } + "description": "Additional details about the event", + "additionalProperties": true + }, + "is_success": { + "type": "boolean", + "description": "Whether the event was successful" + }, + "created_at": { + "type": "string", + "format": "date-time", + "description": "The timestamp when the event was created" } - ] + } }, - "MembershipWithTeamName": { - "additionalProperties": false, + "ListMetadata": { + "required": [ + "page_size" + ], "properties": { - "roles": { - "type": "array", - "items": { - "type": "string", - "example": "admin:read" - } + "total_count": { + "type": "integer" }, - "team_name": { - "$ref": "#/components/schemas/TeamName" + "last_page": { + "type": "integer" }, - "created_at": { - "type": "string", - "format": "date-time" + "page_size": { + "type": "integer" }, - "updated_at": { - "type": "string", - "format": "date-time" + "time_ms": { + "type": "integer" } - }, + } + }, + "BasicError": { + "additionalProperties": false, + "description": "Basic Error", "required": [ - "roles", - "team_name", - "created_at", - "updated_at" + "message", + "status" ], - "title": "CloudQuery Team Membership (team name only)", + "properties": { + "message": { + "type": "string" + }, + "status": { + "type": "integer" + } + }, + "title": "Basic Error", "type": "object" }, - "LocalUserWithTeams": { + "FieldError": { "allOf": [ { - "$ref": "#/components/schemas/LocalUser" + "$ref": "#/components/schemas/BasicError" }, { - "type": "object", - "required": [ - "teams" - ], "properties": { - "teams": { - "type": "array", + "errors": { "items": { - "$ref": "#/components/schemas/MembershipWithTeamName" - } + "type": "string" + }, + "type": "array" + }, + "field_errors": { + "additionalProperties": { + "type": "string" + }, + "type": "object" } - } + }, + "type": "object" } ] }, @@ -16568,6 +12255,14 @@ "deprecated" ] }, + "TeamName": { + "description": "The unique name for the team.", + "maxLength": 255, + "pattern": "^[a-z](-?[a-z0-9]+)+$", + "type": "string", + "example": "cloudquery", + "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" + }, "PluginName": { "description": "The unique name for the plugin.", "maxLength": 255, @@ -16656,323 +12351,50 @@ "format": "date-time", "type": "string" }, - "homepage": { - "type": "string", - "example": "https://cloudquery.io" - }, - "logo": { - "type": "string", - "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e" - }, - "display_name": { - "description": "The plugin's display name", - "type": "string", - "minLength": 1, - "maxLength": 50, - "example": "AWS Source Plugin" - }, - "official": { - "description": "True if the plugin is maintained by CloudQuery, false otherwise", - "type": "boolean" - }, - "release_stage": { - "$ref": "#/components/schemas/PluginReleaseStage" - }, - "repository": { - "type": "string", - "example": "https://github.com/cloudquery/cloudquery" - }, - "short_description": { - "type": "string", - "minLength": 1, - "maxLength": 512, - "example": "Sync data from AWS to any destination" - }, - "tier": { - "$ref": "#/components/schemas/PluginTier" - }, - "public": { - "description": "Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the plugin's team.", - "type": "boolean" - }, - "usd_per_row": { - "deprecated": true, - "type": "string", - "pattern": "^\\d+(?:\\.\\d{1,10})?$", - "description": "Deprecated. Refer to `price_category` instead.", - "example": "0.0001", - "x-go-name": "USDPerRow", - "x-pattern-message": "must be a valid decimal number with up to 10 decimal places." - }, - "free_rows_per_month": { - "deprecated": true, - "type": "integer", - "format": "int64", - "description": "Deprecated. Refer to `price_category` instead.", - "example": 1000 - } - }, - "required": [ - "team_name", - "name", - "kind", - "category", - "release_stage", - "created_at", - "updated_at", - "logo", - "display_name", - "official", - "short_description", - "tier", - "usd_per_row", - "free_rows_per_month" - ], - "title": "CloudQuery Plugin", - "type": "object" - }, - "VersionName": { - "type": "string", - "description": "The version in semantic version format.", - "pattern": "^v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", - "x-pattern-message": "should be in semantic version format" - }, - "VersionRange": { - "type": "string", - "description": "A version range in semantic version format.", - "pattern": "^[^~]?v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", - "x-pattern-message": "should be a version range in semantic version format" - }, - "ListPluginPinnedVersion": { - "additionalProperties": false, - "description": "CloudQuery Pinned Plugin Version Info", - "required": [ - "name", - "range", - "initialized", - "mirroring" - ], - "properties": { - "name": { - "$ref": "#/components/schemas/VersionName" - }, - "range": { - "$ref": "#/components/schemas/VersionRange" - }, - "initialized": { - "type": "boolean", - "default": true, - "deprecated": true, - "description": "Deprecated. Assume `true`." - }, - "mirroring": { - "type": "boolean", - "default": false, - "deprecated": true, - "description": "Deprecated. Assume `false`." - } - } - }, - "ListPlugin": { - "allOf": [ - { - "$ref": "#/components/schemas/Plugin" - }, - { - "type": "object", - "properties": { - "latest_version": { - "$ref": "#/components/schemas/VersionName" - }, - "pinned_version": { - "$ref": "#/components/schemas/ListPluginPinnedVersion" - } - } - } - ] - }, - "ListPlugins": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ListPlugin" - }, - "example": [ - { - "name": "aws", - "kind": "source", - "team_name": "cloudquery", - "display_name": "AWS Source Plugin", - "category": "cloud-infrastructure", - "created_at": "2017-07-14T16:53:42Z", - "updated_at": "2017-07-14T16:53:42Z", - "homepage": "https://cloudquery.io", - "logo": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", - "official": true, - "short_description": "Sync data from AWS to any destination", - "repository": "https://github.com/cloudquery/cloudquery", - "tier": "paid", - "usd_per_row": "0.00123", - "free_rows_per_month": 10000, - "release_stage": "preview" - } - ] - }, - "PluginReleaseStageCreate": { - "description": "Official plugins can go through three release stages: Coming Soon, Preview, and GA.\nThe Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready.\nBoth Preview and GA plugins follow semantic versioning. The main differences between the two stages are:\nPreview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage.", - "type": "string", - "enum": [ - "coming-soon", - "preview", - "ga" - ], - "default": "coming-soon" - }, - "PluginCreate": { - "type": "object", - "required": [ - "team_name", - "kind", - "name", - "category", - "display_name", - "short_description", - "public" - ], - "properties": { - "team_name": { - "$ref": "#/components/schemas/TeamName" - }, - "kind": { - "$ref": "#/components/schemas/PluginKind" - }, - "name": { - "$ref": "#/components/schemas/PluginName" - }, - "category": { - "$ref": "#/components/schemas/PluginCategory" - }, - "price_category": { - "$ref": "#/components/schemas/PluginPriceCategory" - }, - "tier": { - "$ref": "#/components/schemas/PluginTier" - }, - "display_name": { - "type": "string", - "minLength": 1, - "maxLength": 50, - "description": "The plugin's display name, as shown in the CloudQuery Hub.", - "example": "AWS Source Plugin" - }, - "short_description": { - "type": "string", - "minLength": 1, - "maxLength": 512, - "description": "Short description of the plugin. This will be shown in the CloudQuery Hub.", - "example": "Sync data from AWS to any destination" - }, - "homepage": { - "type": "string", - "example": "https://cloudquery.io" - }, - "public": { - "type": "boolean", - "description": "Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the team.", - "example": true - }, - "repository": { - "type": "string", - "example": "https://github.com/cloudquery/cloudquery" - }, - "release_stage": { - "$ref": "#/components/schemas/PluginReleaseStageCreate" - }, - "logo": { - "type": "string", - "description": "URL to the plugin's logo. This will be shown in the CloudQuery Hub.", - "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", - "format": "url" - }, - "usd_per_row": { - "deprecated": true, - "type": "string", - "pattern": "^\\d+(?:\\.\\d{1,10})?$", - "description": "Deprecated. Use `price_category` instead.", - "example": "0.00001", - "x-go-name": "USDPerRow", - "x-pattern-message": "must be a valid decimal number with up to 10 decimal places." - }, - "free_rows_per_month": { - "deprecated": true, - "type": "integer", - "format": "int64", - "description": "Deprecated. Use `price_category` instead.", - "example": 10000 - } - } - }, - "PluginReleaseStageUpdate": { - "description": "Official plugins can go through three release stages: Coming Soon, Preview, and GA.\nThe Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready.\nBoth Preview and GA plugins follow semantic versioning. The main differences between the two stages are:\nPreview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage.", - "type": "string", - "enum": [ - "coming-soon", - "preview", - "ga", - "deprecated" - ] - }, - "PluginUpdate": { - "type": "object", - "properties": { - "category": { - "$ref": "#/components/schemas/PluginCategory" - }, - "price_category": { - "$ref": "#/components/schemas/PluginPriceCategory" - }, - "tier": { - "$ref": "#/components/schemas/PluginTier" + "homepage": { + "type": "string", + "example": "https://cloudquery.io" + }, + "logo": { + "type": "string", + "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e" }, "display_name": { + "description": "The plugin's display name", "type": "string", "minLength": 1, "maxLength": 50, - "description": "The plugin's display name, as shown in the CloudQuery Hub.", "example": "AWS Source Plugin" }, - "short_description": { - "type": "string", - "minLength": 1, - "maxLength": 512, - "description": "Short description of the plugin. This will be shown in the CloudQuery Hub.", - "example": "Sync data from AWS to any destination" + "official": { + "description": "True if the plugin is maintained by CloudQuery, false otherwise", + "type": "boolean" }, - "homepage": { - "type": "string", - "example": "https://cloudquery.io" + "release_stage": { + "$ref": "#/components/schemas/PluginReleaseStage" }, "repository": { "type": "string", "example": "https://github.com/cloudquery/cloudquery" }, - "logo": { + "short_description": { "type": "string", - "description": "URL to the plugin's logo. This will be shown in the CloudQuery Hub.", - "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f9e8", - "format": "url" + "minLength": 1, + "maxLength": 512, + "example": "Sync data from AWS to any destination" }, - "public": { - "type": "boolean", - "description": "If plugin is not public, it won't be visible to other teams in the CloudQuery Hub." + "tier": { + "$ref": "#/components/schemas/PluginTier" }, - "release_stage": { - "$ref": "#/components/schemas/PluginReleaseStageUpdate" + "public": { + "description": "Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the plugin's team.", + "type": "boolean" }, "usd_per_row": { "deprecated": true, "type": "string", "pattern": "^\\d+(?:\\.\\d{1,10})?$", - "description": "Deprecated. Update `price_category` instead.", + "description": "Deprecated. Refer to `price_category` instead.", "example": "0.0001", "x-go-name": "USDPerRow", "x-pattern-message": "must be a valid decimal number with up to 10 decimal places." @@ -16981,10 +12403,75 @@ "deprecated": true, "type": "integer", "format": "int64", - "description": "Deprecated. Update `price_category` instead.", + "description": "Deprecated. Refer to `price_category` instead.", "example": 1000 } - } + }, + "required": [ + "team_name", + "name", + "kind", + "category", + "release_stage", + "created_at", + "updated_at", + "logo", + "display_name", + "official", + "short_description", + "tier", + "usd_per_row", + "free_rows_per_month" + ], + "title": "CloudQuery Plugin", + "type": "object" + }, + "VersionName": { + "type": "string", + "description": "The version in semantic version format.", + "pattern": "^v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", + "x-pattern-message": "should be in semantic version format" + }, + "ListPlugin": { + "allOf": [ + { + "$ref": "#/components/schemas/Plugin" + }, + { + "type": "object", + "properties": { + "latest_version": { + "$ref": "#/components/schemas/VersionName" + } + } + } + ] + }, + "ListPlugins": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ListPlugin" + }, + "example": [ + { + "name": "aws", + "kind": "source", + "team_name": "cloudquery", + "display_name": "AWS Source Plugin", + "category": "cloud-infrastructure", + "created_at": "2017-07-14T16:53:42Z", + "updated_at": "2017-07-14T16:53:42Z", + "homepage": "https://cloudquery.io", + "logo": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", + "official": true, + "short_description": "Sync data from AWS to any destination", + "repository": "https://github.com/cloudquery/cloudquery", + "tier": "paid", + "usd_per_row": "0.00123", + "free_rows_per_month": 10000, + "release_stage": "preview" + } + ] }, "VersionFilter": { "type": "string", @@ -17103,17 +12590,6 @@ "properties": { "spec_json_schema": { "$ref": "#/components/schemas/PluginSpecJSONSchema" - }, - "connector_required": { - "type": "boolean", - "description": "Whether a connector is required for this plugin version" - }, - "connector_types": { - "type": "array", - "items": { - "type": "string" - }, - "description": "List of connector types available for this plugin version" } } } @@ -17148,47 +12624,6 @@ } ] }, - "PluginVersionUpdate": { - "type": "object", - "properties": { - "message": { - "type": "string", - "description": "Description of what's new or changed in this version (supports markdown)", - "example": "- Added support for *AWS S3* - Added support for *AWS EC2*" - }, - "draft": { - "type": "boolean", - "description": "If a plugin version is in draft, it will not show to members outside the team or be counted as the latest version. Once draft is set to false, only certain fields can be updated." - }, - "retracted": { - "type": "boolean", - "description": "If a plugin version is retracted, assets will still be available for download, but the version will be marked as retracted to discourage use." - }, - "protocols": { - "$ref": "#/components/schemas/PluginProtocols" - }, - "supported_targets": { - "type": "array", - "items": { - "type": "string" - } - }, - "checksums": { - "type": "array", - "items": { - "type": "string" - }, - "description": "The SHA-256 checksums of the plugin binaries, one per supported target." - }, - "package_type": { - "type": "string", - "description": "The package type of the plugin binaries" - }, - "spec_json_schema": { - "$ref": "#/components/schemas/PluginSpecJSONSchema" - } - } - }, "PluginAsset": { "additionalProperties": false, "description": "CloudQuery Plugin Asset", @@ -17210,65 +12645,6 @@ "title": "CloudQuery Plugin Asset", "type": "object" }, - "ReleaseURL": { - "required": [ - "url" - ], - "properties": { - "url": { - "type": "string" - } - } - }, - "PluginDocsPageName": { - "description": "The unique name for the plugin documentation page.", - "maxLength": 255, - "pattern": "^[\\w,\\s-]+$", - "type": "string", - "example": "overview", - "x-pattern-message": "can contain only letters, numbers, hyphens and commas" - }, - "PluginDocsPage": { - "additionalProperties": false, - "description": "CloudQuery Plugin Documentation Page", - "required": [ - "name", - "content" - ], - "properties": { - "name": { - "$ref": "#/components/schemas/PluginDocsPageName" - }, - "content": { - "type": "string", - "description": "The content of the documentation page. Supports markdown.", - "example": "# Getting Started\n\nThis is the getting started page." - } - }, - "title": "CloudQuery Plugin Documentation Page", - "type": "object" - }, - "PluginDocsPageCreate": { - "additionalProperties": false, - "description": "CloudQuery Plugin Documentation Page", - "required": [ - "name", - "content" - ], - "properties": { - "name": { - "$ref": "#/components/schemas/PluginDocsPageName" - }, - "content": { - "type": "string", - "minLength": 1, - "description": "The content of the documentation page. Supports markdown.", - "example": "# Getting Started\n\nThis is the getting started page." - } - }, - "title": "CloudQuery Plugin Documentation Page", - "type": "object" - }, "PluginTableName": { "description": "Name of the table", "maxLength": 255, @@ -17354,90 +12730,27 @@ "type": "string" }, "not_null": { - "description": "Whether the column is nullable", - "type": "boolean" - }, - "primary_key": { - "description": "Whether the column is part of the primary key", - "type": "boolean" - }, - "type": { - "description": "Arrow Type of the column", - "type": "string" - }, - "type_schema": { - "description": "For columns of type JSON, the schema of the JSON object", - "type": "string" - }, - "unique": { - "description": "Whether the column has a unique constraint", - "type": "boolean" - } - }, - "title": "CloudQuery Plugin Table Column", - "type": "object" - }, - "PluginTableCreate": { - "additionalProperties": false, - "description": "CloudQuery Plugin Table", - "required": [ - "name" - ], - "properties": { - "description": { - "description": "Description of the table", - "type": "string", - "example": "AWS S3 Buckets" - }, - "is_incremental": { - "description": "Whether the table is incremental", - "type": "boolean" - }, - "name": { - "$ref": "#/components/schemas/PluginTableName" - }, - "parent": { - "description": "Name of the parent table, if any", - "type": "string", - "example": "nil" - }, - "relations": { - "description": "Names of the tables that depend on this table", - "items": { - "type": "string" - }, - "type": "array", - "example": [ - "aws_s3_bucket_cors_rules" - ] - }, - "permissions_needed": { - "description": "List of permissions needed to access this table, if any", - "items": { - "type": "string" - }, - "type": "array", - "example": [ - "storage.buckets.list" - ] - }, - "title": { - "description": "Title of the table", - "type": "string", - "example": "AWS S3 Buckets" + "description": "Whether the column is nullable", + "type": "boolean" }, - "is_paid": { - "description": "Whether the table is paid", + "primary_key": { + "description": "Whether the column is part of the primary key", "type": "boolean" }, - "columns": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PluginTableColumn" - } + "type": { + "description": "Arrow Type of the column", + "type": "string" + }, + "type_schema": { + "description": "For columns of type JSON, the schema of the JSON object", + "type": "string" + }, + "unique": { + "description": "Whether the column has a unique constraint", + "type": "boolean" } }, - "title": "CloudQuery Plugin Table", + "title": "CloudQuery Plugin Table Column", "type": "object" }, "PluginTableDetails": { @@ -17503,48 +12816,6 @@ }, "type": "object" }, - "PluginUIAssetUploadRequest": { - "additionalProperties": false, - "description": "CloudQuery Plugin UI Asset Upload Request", - "required": [ - "name" - ], - "properties": { - "name": { - "type": "string", - "description": "The path and name of the asset", - "example": "scripts/main.js" - }, - "content_type": { - "type": "string", - "description": "Content-type of the asset", - "example": "application/json" - } - }, - "title": "CloudQuery Plugin UI Asset Upload Request", - "type": "object" - }, - "PluginUIAsset": { - "additionalProperties": false, - "description": "CloudQuery Plugin UI Asset", - "required": [ - "name", - "upload_url" - ], - "properties": { - "name": { - "type": "string", - "description": "The path and name of the asset" - }, - "upload_url": { - "type": "string", - "description": "URL to upload the asset to", - "x-go-name": "UploadURL" - } - }, - "title": "CloudQuery Plugin UI Asset", - "type": "object" - }, "AlertState": { "type": "string", "enum": [ @@ -17554,12 +12825,17 @@ "triggered" ] }, + "QueryTag": { + "description": "A saved query tag.", + "type": "string" + }, "AlertSeverity": { "type": "string", "enum": [ "low", "medium", - "high" + "high", + "critical" ] }, "NotificationDestinationID": { @@ -17577,6 +12853,7 @@ "id", "name", "enabled", + "type", "url", "created_at", "updated_at" @@ -17592,6 +12869,14 @@ "enabled": { "type": "boolean" }, + "type": { + "type": "string", + "enum": [ + "webhook", + "slack" + ], + "description": "Type of notification destination" + }, "url": { "type": "string", "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXX", @@ -17723,561 +13008,760 @@ "items": { "$ref": "#/components/schemas/NotificationDestinationID" }, - "description": "List of notification destinations to send alerts to", - "x-go-type-skip-optional-pointer": true, - "allowEmptyValue": true, - "explode": true + "description": "List of notification destinations to send alerts to", + "x-go-type-skip-optional-pointer": true, + "allowEmptyValue": true, + "explode": true + } + } + }, + "NotificationDestinationTestResponse": { + "title": "Notification Destination Test Response", + "type": "object", + "description": "Notification Destination Test Response", + "additionalProperties": false, + "required": [ + "is_success", + "http_status", + "http_status_code", + "http_body", + "http_headers" + ], + "properties": { + "is_success": { + "type": "boolean", + "description": "Indicates if the test was successful" + }, + "http_status_code": { + "type": "integer", + "description": "HTTP status code returned by the notification destination", + "x-go-name": "HTTPStatusCode" + }, + "http_status": { + "type": "string", + "description": "HTTP status message returned by the notification destination", + "x-go-name": "HTTPStatus" + }, + "http_body": { + "type": "string", + "description": "Body of the HTTP response from the notification destination", + "x-go-name": "HTTPBody" + }, + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "Headers returned by the notification destination", + "x-go-name": "HTTPHeaders" + } + } + }, + "AlertTestResponse": { + "title": "Alert Test Response", + "type": "object", + "description": "Alert Test Response", + "additionalProperties": false, + "required": [ + "destination_id", + "response" + ], + "properties": { + "destination_id": { + "type": "string", + "description": "The ID of the notification destination.", + "x-go-name": "DestinationID" + }, + "error": { + "type": "string", + "description": "An error message if the test failed, otherwise null." + }, + "response": { + "$ref": "#/components/schemas/NotificationDestinationTestResponse" + } + } + }, + "PolicyStatus": { + "description": "Policy status", + "type": "string", + "enum": [ + "paused", + "active" + ], + "x-go-name": "PolicyStatus" + }, + "PolicySeverity": { + "description": "Policy severity", + "type": "string", + "enum": [ + "low", + "medium", + "high", + "critical" + ], + "x-go-name": "PolicySeverity" + }, + "PolicyDomain": { + "description": "Policy domain", + "type": "string", + "enum": [ + "finops", + "security", + "compliance", + "governance", + "operations" + ], + "x-go-name": "PolicyDomain" + }, + "PolicyGroupID": { + "title": "Policy Group ID", + "type": "string", + "format": "uuid", + "x-go-name": "PolicyGroupID" + }, + "PolicyID": { + "description": "The unique ID for the policy.", + "type": "string", + "format": "uuid", + "x-go-name": "PolicyID" + }, + "PolicyGroup": { + "title": "Policy Group", + "type": "object", + "description": "Policy Group", + "additionalProperties": false, + "required": [ + "id", + "name", + "description", + "created_at", + "updated_at" + ], + "properties": { + "id": { + "type": "string", + "format": "uuid" + }, + "name": { + "type": "string", + "example": "Security Policies" + }, + "description": { + "type": "string", + "example": "Group containing all security-related policies" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + } + } + }, + "Policy": { + "title": "Policy", + "type": "object", + "description": "Policy", + "additionalProperties": false, + "required": [ + "id", + "name", + "domain", + "severity", + "description", + "status", + "team_name", + "query_id", + "query", + "created_by", + "created_at", + "updated_at" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/PolicyID" + }, + "name": { + "type": "string", + "example": "Unencrypted S3 buckets" + }, + "domain": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "severity": { + "$ref": "#/components/schemas/PolicySeverity" + }, + "description": { + "type": "string", + "example": "Policy to detect unencrypted S3 buckets" + }, + "status": { + "$ref": "#/components/schemas/PolicyStatus" + }, + "team_name": { + "type": "string", + "example": "my-team" + }, + "query_id": { + "$ref": "#/components/schemas/QueryID" + }, + "query": { + "type": "string", + "description": "The SQL query string for the policy", + "example": "SELECT * FROM aws_s3_buckets WHERE server_side_encryption_configuration IS NULL" + }, + "created_by": { + "type": "string", + "format": "uuid", + "x-go-name": "CreatedByUserID" + }, + "updated_by": { + "type": "string", + "format": "uuid", + "nullable": true, + "x-go-name": "UpdatedByUserID" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "violation_count": { + "type": "integer", + "nullable": true, + "description": "Number of violations from the last evaluation", + "example": 5 + }, + "run_at": { + "type": "string", + "format": "date-time", + "nullable": true, + "description": "Timestamp of the last evaluation run", + "example": "2017-07-14T16:53:42Z" + }, + "notification_destinations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/NotificationDestinationListItem" + }, + "description": "List of notification destinations configured for the policy's alert", + "example": [] + }, + "policy_groups": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroup" + }, + "description": "List of policy groups this policy belongs to", + "example": [] } } }, - "NotificationDestinationTestResponse": { - "title": "Notification Destination Test Response", + "PolicyCreate": { + "title": "Policy Create", "type": "object", - "description": "Notification Destination Test Response", + "description": "Create a policy (implicitly creates a query and an enabled alert)", "additionalProperties": false, "required": [ - "is_success", - "http_status", - "http_status_code", - "http_body", - "http_headers" + "name", + "domain", + "severity", + "query" ], "properties": { - "is_success": { - "type": "boolean", - "description": "Indicates if the test was successful" + "name": { + "type": "string", + "example": "Unencrypted S3 buckets" }, - "http_status_code": { - "type": "integer", - "description": "HTTP status code returned by the notification destination", - "x-go-name": "HTTPStatusCode" + "domain": { + "$ref": "#/components/schemas/PolicyDomain" }, - "http_status": { + "severity": { + "$ref": "#/components/schemas/PolicySeverity" + }, + "description": { "type": "string", - "description": "HTTP status message returned by the notification destination", - "x-go-name": "HTTPStatus" + "default": "", + "example": "Policy to detect unencrypted S3 buckets" }, - "http_body": { + "query": { "type": "string", - "description": "Body of the HTTP response from the notification destination", - "x-go-name": "HTTPBody" + "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" + "notification_destination_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" }, - "description": "Headers returned by the notification destination", - "x-go-name": "HTTPHeaders" + "nullable": true, + "description": "Notification destination IDs to send alerts to" + }, + "policy_group_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" + }, + "nullable": true, + "description": "Policy group IDs to add this policy to" } } }, - "AlertTestResponse": { - "title": "Alert Test Response", + "PolicyUpdate": { + "title": "Policy Update", "type": "object", - "description": "Alert Test Response", + "description": "Update a policy", "additionalProperties": false, - "required": [ - "destination_id", - "response" - ], "properties": { - "destination_id": { - "type": "string", - "description": "The ID of the notification destination.", - "x-go-name": "DestinationID" + "name": { + "type": "string" }, - "error": { + "domain": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "severity": { + "$ref": "#/components/schemas/PolicySeverity" + }, + "description": { + "type": "string" + }, + "query": { "type": "string", - "description": "An error message if the test failed, otherwise null." + "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" }, - "response": { - "$ref": "#/components/schemas/NotificationDestinationTestResponse" - } - } - }, - "APIKeyName": { - "description": "Name of the API key", - "type": "string", - "example": "cli-api-key", - "maxLength": 255, - "minLength": 1, - "pattern": "^(?:[a-zA-Z0-9][a-zA-Z0-9- ]*)?[a-zA-Z0-9]$", - "x-pattern-message": "can contain only letters, numbers, spaces, and hyphens, starting and ending with a letter or number" - }, - "APIKeyID": { - "description": "ID of the API key", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "APIKeyID" - }, - "APIKeyRole": { - "type": "string", - "enum": [ - "admin:write", - "admin:read", - "general:read", - "general:write", - "ci", - "schema-only" - ] - }, - "APIKeyTeamRole": { - "type": "object", - "required": [ - "role" - ], - "properties": { - "team": { - "$ref": "#/components/schemas/TeamName" + "notification_destination_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" + }, + "nullable": true, + "description": "Notification destination IDs to send alerts to" }, - "role": { - "$ref": "#/components/schemas/APIKeyRole" + "policy_group_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" + }, + "nullable": true, + "description": "Policy group IDs to set for this policy" } } }, - "APIKey": { - "description": "API Key to interact with CloudQuery Cloud under specific team", + "PolicyViolation": { + "title": "Policy Violation", "type": "object", + "description": "Policy violation resource information", + "additionalProperties": false, "required": [ - "id", + "cloud", + "resource_type_label", + "_cq_account_name", "name", - "expires_at", - "expired", - "roles" + "region", + "_cq_platform_id" ], "properties": { - "name": { - "$ref": "#/components/schemas/APIKeyName" - }, - "created_by": { + "cloud": { "type": "string", - "example": "user@example.com", - "description": "email of the user that created the API key" - }, - "id": { - "$ref": "#/components/schemas/APIKeyID" + "example": "aws" }, - "key": { + "resource_type_label": { "type": "string", - "description": "API key. Will be shown only in the response when creating the key.", - "example": "1234567890abcdef1234567890abcdef" + "example": "EC2 Instance" }, - "created_at": { + "_cq_account_name": { "type": "string", - "format": "date-time", - "example": "2017-07-14T16:53:42Z" + "example": "my-account" }, - "expires_at": { + "name": { "type": "string", - "description": "Timestamp at which API key will stop working", - "format": "date-time", - "example": "2017-07-14T16:53:42Z" + "example": "my-resource" }, - "last_access_at": { + "region": { "type": "string", - "format": "date-time", - "example": "2017-07-14T16:53:42Z", - "description": "Timestamp at which API key was last used - accurate to the day only." - }, - "expired": { - "type": "boolean", - "description": "Whether the API key has expired or not", - "example": false + "example": "us-east-1" }, - "roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/APIKeyTeamRole" - } + "_cq_platform_id": { + "type": "string", + "example": "aws_ec2_instances_12345678-1234-1234-1234-123456789abc" } } }, - "ConnectorStatus": { - "description": "The status of the connector", - "type": "string", - "enum": [ - "created", - "authenticated", - "failed", - "revoked" - ] - }, - "Connector": { - "description": "Connector definition", + "PolicyEvaluationLog": { + "title": "Policy Evaluation Log", "type": "object", + "description": "Policy evaluation log entry", + "additionalProperties": false, "required": [ "id", - "type", - "created_at", - "name", - "status" + "policy_id", + "violation_count", + "run_at" ], "properties": { "id": { "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "description": "unique ID of the connector", - "x-go-name": "ID" - }, - "type": { - "description": "Type of the connector", - "type": "string" + "format": "uuid" }, - "name": { - "type": "string", - "description": "Name of the connector" + "policy_id": { + "$ref": "#/components/schemas/PolicyID" }, - "status": { - "$ref": "#/components/schemas/ConnectorStatus", - "description": "Status of the connector" + "violation_count": { + "type": "integer", + "example": 5 }, - "created_at": { + "run_at": { "example": "2017-07-14T16:53:42Z", "format": "date-time", - "type": "string", - "description": "Time the connector was created" + "type": "string" } } }, - "ConnectorCreate": { - "description": "Connector creation request", + "PolicyMetrics": { + "title": "Policy Metrics", "type": "object", + "description": "Policy metrics summary", + "additionalProperties": false, "required": [ - "type", - "name" + "total_active_violations", + "high_severity_violations", + "violations_this_week" ], "properties": { - "type": { - "description": "Type of the connector", - "type": "string" + "total_active_violations": { + "type": "integer", + "description": "Total violations from active policies", + "example": 28 }, - "name": { - "type": "string", - "description": "Name of the connector" + "high_severity_violations": { + "type": "integer", + "description": "Total violations from high or critical severity policies", + "example": 10 + }, + "violations_this_week": { + "type": "integer", + "description": "Total violations from evaluations in the last 7 days", + "example": 7 } } }, - "ConnectorID": { - "description": "ID of the Connector", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "ConnectorID" - }, - "ConnectorUpdate": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "description": "Name of the connector" - } - }, - "type": "object" - }, - "SyncEnvCreate": { + "ViolationsByDomainItem": { + "title": "Violations By Domain Item", "type": "object", - "description": "Environment variable. Environment variables are assumed to be secret.", + "description": "Violation count for a specific domain", + "additionalProperties": false, "required": [ - "name" + "domain", + "violation_count" ], "properties": { - "name": { - "type": "string", - "description": "Name of the environment variable" + "domain": { + "$ref": "#/components/schemas/PolicyDomain" }, - "value": { - "type": "string", - "description": "Value of the environment variable" + "violation_count": { + "type": "integer", + "description": "Number of violations for this domain", + "example": 15 } } }, - "ConnectorAuthRequestAWS": { + "ViolationsByDomain": { + "title": "Violations By Domain", "type": "object", - "description": "AWS connector authentication request to start the authentication process", + "description": "Violations grouped by domain", "additionalProperties": false, "required": [ - "plugin_team", - "plugin_kind", - "plugin_name" + "items", + "total_violations" ], "properties": { - "plugin_team": { - "type": "string", - "description": "Team that owns the plugin we are authenticating the connector for", - "example": "cloudquery" - }, - "plugin_kind": { - "type": "string", - "description": "Kind of the plugin", - "example": "source" - }, - "plugin_name": { - "type": "string", - "description": "Name of the plugin", - "example": "aws" - }, - "plugin_version": { - "type": "string", - "description": "Version of the plugin", - "example": "v27.1.0" - }, - "spec": { - "type": "object", - "additionalProperties": true, - "format": "Plugin parameters, specific to each plugin" - }, - "env": { - "description": "Environment variables used in the spec.", - "type": "array", - "items": { - "$ref": "#/components/schemas/SyncEnvCreate" - } - }, - "tables": { - "type": "array", - "description": "Tables to authenticate, setting from the outer spec", - "items": { - "type": "string", - "example": "aws_s3_buckets" - } - }, - "skip_tables": { + "items": { "type": "array", - "description": "Tables to skip authentication, setting from the outer spec", "items": { - "type": "string", - "example": "aws_s3_buckets" + "$ref": "#/components/schemas/ViolationsByDomainItem" } }, - "skip_dependent_tables": { - "type": "boolean", - "description": "Whether to skip dependent tables, setting from the outer spec" + "total_violations": { + "type": "integer", + "description": "Total violations across all domains", + "example": 28 } } }, - "ConnectorAuthResponseAWS": { + "ViolationsHistoryItem": { + "title": "Violations History Item", + "type": "object", + "description": "Violation count for a specific date", "additionalProperties": false, "required": [ - "redirect_url", - "role_template_url", - "suggested_external_id", - "suggested_policy_arns" + "date", + "violation_count" ], "properties": { - "redirect_url": { - "type": "string", - "description": "URL to redirect the user to, to authenticate", - "x-go-name": "RedirectURL" - }, - "role_template_url": { - "type": "string", - "description": "URL to the role template, to present to the user", - "x-go-name": "RoleTemplateURL" - }, - "suggested_external_id": { + "date": { "type": "string", - "description": "External ID suggested to enter into the role definition", - "x-go-name": "SuggestedExternalID" + "format": "date", + "description": "Date of the violations", + "example": "2026-01-06" }, - "suggested_policy_arns": { - "type": "array", - "items": { - "type": "string" - }, - "description": "List of AWS policy ARNs suggested to grant inside the role definition", - "x-go-name": "SuggestedPolicyARNs" + "violation_count": { + "type": "integer", + "description": "Number of violations on this date", + "example": 3 } - }, - "type": "object", - "description": "AWS connector authentication response to start the authentication process" + } }, - "ConnectorAuthFinishRequestAWS": { + "ViolationsHistoryMetadata": { + "title": "Violations History Metadata", + "type": "object", + "description": "Metadata for violations history query", "additionalProperties": false, "required": [ - "role_arn" + "interval", + "start_date", + "end_date" ], "properties": { - "role_arn": { + "interval": { "type": "string", - "description": "ARN of role created by the user", - "x-go-name": "RoleARN" + "description": "Interval in days used for grouping", + "example": "30" }, - "external_id": { + "start_date": { "type": "string", - "description": "External ID in the role definition. Optional. If not provided the previously suggested external ID will be used. Empty string will remove the external ID.", - "x-go-name": "ExternalID" + "format": "date", + "description": "Start date of the query range", + "example": "2025-05-01" + }, + "end_date": { + "type": "string", + "format": "date", + "description": "End date of the query range", + "example": "2026-12-01" } - }, - "type": "object", - "description": "AWS connector authentication request, filled in after the user has authenticated through AWS" + } }, - "ConnectorAuthRequestGCP": { + "ViolationsHistory": { + "title": "Violations History", "type": "object", - "description": "GCP connector authentication request to start the authentication process", + "description": "Violations history over time", "additionalProperties": false, "required": [ - "plugin_team", - "plugin_kind", - "plugin_name" + "items", + "metadata" ], "properties": { - "plugin_team": { - "type": "string", - "description": "Team that owns the plugin we are authenticating the connector for", - "example": "cloudquery" - }, - "plugin_kind": { - "type": "string", - "description": "Kind of the plugin", - "example": "source" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ViolationsHistoryItem" + } }, - "plugin_name": { - "type": "string", - "description": "Name of the plugin", - "example": "aws" + "metadata": { + "$ref": "#/components/schemas/ViolationsHistoryMetadata" } } }, - "ConnectorAuthResponseGCP": { + "PolicyGroupWithCounts": { + "title": "Policy Group With Counts", + "type": "object", + "description": "Policy Group with policy count and violation counts by severity", "additionalProperties": false, "required": [ - "service_account" + "id", + "name", + "description", + "policy_count", + "violation_count_low", + "violation_count_medium", + "violation_count_high", + "violation_count_critical", + "created_at", + "updated_at" ], - "properties": { - "service_account": { - "type": "string", - "description": "CloudQuery GCP Service Account to grant access to" + "allOf": [ + { + "$ref": "#/components/schemas/PolicyGroup" + }, + { + "type": "object", + "properties": { + "policy_count": { + "type": "integer", + "description": "Number of policies in this group", + "example": 5, + "default": 0 + }, + "violation_count_low": { + "type": "integer", + "description": "Total violations from low severity policies in this group", + "example": 10, + "default": 0 + }, + "violation_count_medium": { + "type": "integer", + "description": "Total violations from medium severity policies in this group", + "example": 25, + "default": 0 + }, + "violation_count_high": { + "type": "integer", + "description": "Total violations from high severity policies in this group", + "example": 15, + "default": 0 + }, + "violation_count_critical": { + "type": "integer", + "description": "Total violations from critical severity policies in this group", + "example": 3, + "default": 0 + } + } } - }, - "type": "object", - "description": "GCP connector authentication response to start the authentication process" + ] }, - "ConnectorAuthRequestOAuth": { + "PolicyGroupCreate": { + "title": "Policy Group Create", "type": "object", - "description": "OAuth connector authentication request to start the authentication process", + "description": "Create a policy group", "additionalProperties": false, "required": [ - "plugin_team", - "plugin_kind", - "plugin_name", - "base_url" + "name" ], "properties": { - "plugin_team": { - "type": "string", - "description": "Team that owns the plugin we are authenticating the connector for", - "example": "cloudquery" - }, - "plugin_kind": { - "type": "string", - "description": "Kind of the plugin", - "example": "source" - }, - "plugin_name": { - "type": "string", - "description": "Name of the plugin", - "example": "googleanalytics" - }, - "plugin_version": { + "name": { "type": "string", - "description": "Version of the plugin", - "example": "v3.0.0" + "example": "Security Policies" }, - "base_url": { + "description": { "type": "string", - "description": "Base of the URL the callback url will be constructed from", - "example": "https://cloud.cloudquery.io/oauth", - "x-go-name": "BaseURL" - }, - "spec": { - "type": "object", - "additionalProperties": true, - "format": "Plugin parameters, specific to each plugin" - }, - "env": { - "description": "Environment variables used in the spec.", - "type": "array", - "items": { - "$ref": "#/components/schemas/SyncEnvCreate" - } + "default": "", + "example": "Group containing all security-related policies" }, - "tables": { + "policy_ids": { "type": "array", - "description": "Tables to authenticate, setting from the outer spec", "items": { "type": "string", - "example": "github_organizations" - } + "format": "uuid" + }, + "nullable": true, + "description": "Optional array of policy IDs to add to this group" + } + } + }, + "PolicyGroupUpdate": { + "title": "Policy Group Update", + "type": "object", + "description": "Update a policy group", + "additionalProperties": false, + "properties": { + "name": { + "type": "string" }, - "skip_tables": { + "description": { + "type": "string" + }, + "policy_ids": { "type": "array", - "description": "Tables to skip authentication, setting from the outer spec", "items": { "type": "string", - "example": "github_organizations" - } - }, - "skip_dependent_tables": { - "type": "boolean", - "description": "Whether to skip dependent tables, setting from the outer spec" - }, - "flavor": { - "type": "string", - "description": "Override default flavor" + "format": "uuid" + }, + "nullable": true, + "description": "Policy IDs to set for this group" } } }, - "ConnectorAuthResponseOAuth": { - "additionalProperties": false, - "required": [ - "redirect_url" - ], - "properties": { - "redirect_url": { - "type": "string", - "description": "URL to redirect the user to, to authenticate", - "x-go-name": "RedirectURL" - } - }, - "type": "object", - "description": "OAuth connector authentication response to start the authentication process" + "APIKeyName": { + "description": "Name of the API key", + "type": "string", + "example": "cli-api-key", + "maxLength": 255, + "minLength": 1, + "pattern": "^(?:[a-zA-Z0-9][a-zA-Z0-9- ]*)?[a-zA-Z0-9]$", + "x-pattern-message": "can contain only letters, numbers, spaces, and hyphens, starting and ending with a letter or number" }, - "ConnectorAuthFinishRequestOAuth": { - "additionalProperties": false, + "APIKeyID": { + "description": "ID of the API key", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "APIKeyID" + }, + "APIKey": { + "description": "API Key to interact with CloudQuery Platform", + "type": "object", "required": [ - "return_url", - "base_url" + "id", + "name", + "expires_at", + "expired", + "roles" ], "properties": { - "return_url": { + "name": { + "$ref": "#/components/schemas/APIKeyName" + }, + "created_by": { "type": "string", - "description": "URL the user was redirected to (including new parameter values) after the OAuth flow is complete", - "x-go-name": "ReturnURL" + "example": "user@example.com", + "description": "email of the user that created the API key" }, - "base_url": { + "id": { + "$ref": "#/components/schemas/APIKeyID" + }, + "key": { "type": "string", - "description": "Base of the URL the callback url was constructed from", - "example": "https://cloud.cloudquery.io/oauth", - "x-go-name": "BaseURL" + "description": "API key. Will be shown only in the response when creating the key.", + "example": "1234567890abcdef1234567890abcdef" }, - "spec": { - "type": "object", - "additionalProperties": true, - "format": "Plugin parameters, specific to each plugin" + "created_at": { + "type": "string", + "format": "date-time", + "example": "2017-07-14T16:53:42Z" }, - "env": { - "description": "Environment variables used in the spec.", + "expires_at": { + "type": "string", + "description": "Timestamp at which API key will stop working", + "format": "date-time", + "example": "2017-07-14T16:53:42Z" + }, + "last_access_at": { + "type": "string", + "format": "date-time", + "example": "2017-07-14T16:53:42Z", + "description": "Timestamp at which API key was last used - accurate to the day only." + }, + "expired": { + "type": "boolean", + "description": "Whether the API key has expired or not", + "example": false + }, + "roles": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncEnvCreate" + "$ref": "#/components/schemas/Role" } } - }, - "type": "object", - "description": "OAuth connector authentication request, filled in after the user has authenticated through OAuth" + } + }, + "RoleID": { + "description": "The unique ID for the role.", + "type": "string", + "format": "uuid", + "x-go-name": "RoleID" }, "ConversationCreate": { "type": "object", @@ -18441,14 +13925,10 @@ "enum": [ "id", "description", - "table_name", "column_name", "label", - "column_type", - "value_type", "value_expr", "created_by", - "team_name", "created_at", "updated_at" ] @@ -18468,22 +13948,18 @@ "format": "uuid", "x-go-name": "CustomColumnID" }, - "CustomColumnColumnType": { + "CustomColumnColumnName": { "type": "string", - "enum": [ - "String", - "Integer", - "Float", - "Boolean", - "DateTime" - ] + "description": "The name for the custom column.", + "pattern": "^[a-zA-Z_][a-zA-Z0-9_]*$", + "example": "tags_v1_region", + "x-pattern-message": "Letters, numbers, and underscores only. Must start with a letter.", + "minLength": 1, + "maxLength": 63 }, - "CustomColumnValueType": { + "CustomColumnValueExpr": { "type": "string", - "enum": [ - "expression", - "external" - ] + "description": "The SQL expression for the custom column." }, "CustomColumn": { "title": "Custom Column", @@ -18492,13 +13968,11 @@ "additionalProperties": false, "required": [ "id", - "table_name", "column_name", "label", - "value_type", + "value_expr", "created_by", - "created_at", - "team_name" + "created_at" ], "properties": { "id": { @@ -18507,29 +13981,15 @@ "description": { "type": "string" }, - "table_name": { - "type": "string", - "example": "cloud_assets", - "description": "Table this column applies to." - }, "column_name": { - "type": "string", - "example": "environment" + "$ref": "#/components/schemas/CustomColumnColumnName" }, "label": { "type": "string", "example": "Environment name" }, - "column_type": { - "description": "Data type of the column. Only needed for value_type=external.", - "$ref": "#/components/schemas/CustomColumnColumnType" - }, - "value_type": { - "$ref": "#/components/schemas/CustomColumnValueType" - }, "value_expr": { - "description": "Value expression.\nFor value_type=expression, this is the actual SQL query.\nFor value_type=external this is the default value.\n", - "type": "string" + "$ref": "#/components/schemas/CustomColumnValueExpr" }, "created_by": { "$ref": "#/components/schemas/CreatedBy" @@ -18538,9 +13998,6 @@ "example": "2017-07-14T16:53:42Z", "format": "date-time", "type": "string" - }, - "team_name": { - "$ref": "#/components/schemas/TeamName" } } }, @@ -18550,93 +14007,23 @@ "description": "Create or update a custom column", "additionalProperties": false, "required": [ - "table_name", "column_name", "label", - "value_type" - ], - "properties": { - "description": { - "type": "string" - }, - "table_name": { - "type": "string", - "example": "cloud_assets", - "description": "Table this column applies to." - }, - "column_name": { - "type": "string", - "example": "environment" - }, - "label": { - "type": "string", - "example": "Environment name" - }, - "column_type": { - "description": "Data type of the column. Only needed for value_type=external.", - "$ref": "#/components/schemas/CustomColumnColumnType" - }, - "value_type": { - "$ref": "#/components/schemas/CustomColumnValueType" - }, - "value_expr": { - "description": "Value expression.\nFor value_type=expression, this is the actual SQL query.\nFor value_type=external this is the default value.\n", - "type": "string" - } - } - }, - "CustomColumnDataImport": { - "title": "Custom Column Data Import", - "type": "object", - "description": "Import data into the specified custom column", - "additionalProperties": false, - "required": [ - "data" - ], - "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "title": "Filter selecting assets, and value which should be assigned to matches.", - "description": "Asset Filter and corresponding value assignment", - "additionalProperties": true - } - } - } - }, - "CustomColumnDataImportAccepted": { - "type": "object", - "required": [ - "id", - "created_at" - ], - "properties": { - "created_at": { - "description": "The time the data import was created", - "type": "string", - "format": "date-time", - "example": "2020-01-01T00:00:00Z" - } - } - }, - "CustomColumnDataValues": { - "title": "Custom Column Data Values", - "type": "object", - "description": "Edit one or more values within the specified custom column", - "additionalProperties": false, - "required": [ - "data" + "value_expr" ], "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "title": "The cq_id of the row and the value to set.", - "description": "CQ_ID and corresponding value assignment", - "additionalProperties": true - } + "description": { + "type": "string" + }, + "column_name": { + "$ref": "#/components/schemas/CustomColumnColumnName" + }, + "label": { + "type": "string", + "example": "Environment name" + }, + "value_expr": { + "$ref": "#/components/schemas/CustomColumnValueExpr" } } }, @@ -18736,146 +14123,120 @@ } } }, - "ContentType": { - "description": "The HTTP Content-Type of the image or asset", - "type": "string", - "example": "image/png", - "enum": [ - "image/jpeg", - "image/png", - "image/webp" - ] - }, - "TeamImageCreate": { + "NotificationDetail": { + "title": "Notification Detail", "type": "object", - "title": "Create Team Image Request", + "description": "A notification instance for a triggered alert, including one notification destination. Each notification destination for an alert will result in a separate notification item.", "additionalProperties": false, "required": [ - "name", - "checksum", - "content_type" + "id", + "query_id", + "policy_id", + "message", + "severity", + "state", + "total_violations", + "created_at", + "updated_at" ], "properties": { - "name": { + "id": { "type": "string", - "minLength": 1, - "maxLength": 64, - "description": "Name of image" + "format": "uuid", + "description": "Unique identifier for the alert", + "x-go-name": "ID" }, - "checksum": { + "query_id": { "type": "string", - "minLength": 40, - "maxLength": 40, - "pattern": "^[a-f0-9]+$", - "description": "SHA1 checksum of image", - "x-pattern-message": "can contain only lowercase hexadecimal characters" + "format": "uuid", + "description": "Reference to the associated query", + "x-go-name": "QueryID" }, - "content_type": { - "$ref": "#/components/schemas/ContentType" - } - } - }, - "TeamImage": { - "required": [ - "url", - "name", - "checksum", - "required_headers" - ], - "properties": { - "name": { + "policy_id": { "type": "string", - "description": "Name of image" + "format": "uuid", + "description": "Reference to the associated policy", + "x-go-name": "PolicyID" }, - "checksum": { + "message": { "type": "string", - "description": "SHA1 checksum of image" + "description": "Alert message content" }, - "url": { - "type": "string", - "description": "URL to download image", - "x-go-name": "URL" + "severity": { + "$ref": "#/components/schemas/AlertSeverity" }, - "upload_url": { - "type": "string", - "description": "URL to upload image", - "x-go-name": "UploadURL" + "state": { + "$ref": "#/components/schemas/AlertState" }, - "required_headers": { - "type": "object", - "additionalProperties": { - "type": "array", - "items": { - "type": "string" - } - }, - "description": "Required HTTP headers to include for the upload" - } - } - }, - "Email": { - "type": "string", - "example": "user@example.com", - "format": "email" - }, - "Invitation": { - "additionalProperties": false, - "required": [ - "role", - "email", - "team_name", - "created_at" - ], - "properties": { - "team_name": { - "$ref": "#/components/schemas/TeamName" + "total_violations": { + "type": "integer", + "format": "int64", + "description": "Number of violations that triggered the alert" }, - "email": { - "$ref": "#/components/schemas/Email" + "last_evaluated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last evaluated" }, - "role": { + "triggered_at": { "type": "string", - "example": "admin" + "format": "date-time", + "description": "Timestamp when the alert was triggered" }, "created_at": { - "example": "2017-07-14T16:53:42Z", + "type": "string", "format": "date-time", - "type": "string" - } - } - }, - "MembershipWithTeam": { - "additionalProperties": false, - "properties": { - "roles": { - "type": "array", - "items": { - "type": "string", - "example": "admin:read" - } + "description": "Timestamp when the alert was created" + }, + "updated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last updated" }, - "team": { - "$ref": "#/components/schemas/Team" + "notification_destination": { + "$ref": "#/components/schemas/NotificationDestinationListItem", + "description": "The notification destination for this notification item (null if no destinations configured)", + "nullable": true } - }, - "required": [ - "roles", - "team" - ], - "title": "CloudQuery Team Membership", - "type": "object" + } }, "NotificationDestinationData": { "title": "Notification Destination Data", "type": "object", "description": "Notification Destination Data", - "required": [ - "url" - ], "properties": { + "type": { + "type": "string", + "enum": [ + "webhook", + "slack" + ], + "default": "webhook", + "description": "Type of notification destination" + }, + "slack_connection_id": { + "type": "string", + "format": "uuid", + "description": "Slack connection ID (required for slack type)", + "x-go-name": "SlackConnectionID" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs to send notifications to (required for slack type)", + "x-go-name": "SlackChannels" + }, + "custom_message": { + "type": "string", + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", + "x-go-name": "CustomMessage" + }, "url": { "type": "string", "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "description": "Webhook URL (required for webhook type, must not be set for slack type)", "x-go-name": "URL" }, "http_headers": { @@ -18883,12 +14244,14 @@ "additionalProperties": { "type": "string" }, + "description": "HTTP headers (required for webhook type, must not be set for slack type)", "x-go-name": "HTTPHeaders", "x-go-type-skip-optional-pointer": true }, "http_body": { "type": "string", - "example": "{\"text\": \"Alert: {{alert.name}}\"}", + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", "x-go-name": "HTTPBody" } } @@ -18928,38 +14291,199 @@ "id", "name", "enabled", + "type", "url", "created_at", "updated_at" ], "properties": { "id": { - "$ref": "#/components/schemas/NotificationDestinationID" - }, - "name": { + "$ref": "#/components/schemas/NotificationDestinationID" + }, + "name": { + "type": "string", + "example": "Send to Slack" + }, + "enabled": { + "type": "boolean" + }, + "type": { + "type": "string", + "enum": [ + "webhook", + "slack" + ], + "description": "Type of notification destination" + }, + "url": { + "type": "string", + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "x-go-name": "URL" + }, + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "x-go-name": "HTTPHeaders", + "x-go-type-skip-optional-pointer": true + }, + "http_body": { + "type": "string", + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", + "x-go-name": "HTTPBody" + }, + "slack_connection_id": { + "type": "string", + "format": "uuid", + "nullable": true, + "description": "Slack connection ID (only for slack type)", + "x-go-name": "SlackConnectionID" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs (only for slack type)", + "x-go-name": "SlackChannels" + }, + "custom_message": { + "type": "string", + "nullable": true, + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type)", + "x-go-name": "CustomMessage" + }, + "last_notification_error_timestamp": { + "type": "string", + "format": "date-time", + "nullable": true, + "description": "Timestamp of the last notification error", + "x-go-name": "LastNotificationErrorTimestamp" + }, + "last_notification_error_code": { + "type": "string", + "nullable": true, + "description": "Error code of the last notification error", + "x-go-name": "LastNotificationErrorCode" + }, + "last_notification_error_message": { + "type": "string", + "nullable": true, + "description": "Error message of the last notification error", + "x-go-name": "LastNotificationErrorMessage" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + } + } + }, + "NotificationDestinationUpdate": { + "title": "Update Notification Destination", + "type": "object", + "description": "Update Notification Destination", + "additionalProperties": false, + "properties": { + "name": { + "type": "string", + "example": "Send to Slack" + }, + "enabled": { + "type": "boolean" + }, + "url": { + "type": "string", + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "x-go-name": "URL" + }, + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "x-go-name": "HTTPHeaders" + }, + "http_body": { + "type": "string", + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", + "x-go-name": "HTTPBody" + }, + "custom_message": { + "type": "string", + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", + "x-go-name": "CustomMessage" + }, + "slack_connection_id": { + "type": "string", + "format": "uuid", + "description": "Slack connection ID (only for slack type, must not be set for webhook)", + "x-go-name": "SlackConnectionID" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs to send notifications to (only for slack type, must not be set for webhook)", + "x-go-name": "SlackChannels" + } + } + }, + "SlackConnectionCreate": { + "title": "Create Slack Connection", + "type": "object", + "description": "Create Slack Connection", + "additionalProperties": false, + "required": [ + "code" + ], + "properties": { + "code": { + "type": "string", + "description": "OAuth code from Slack authorization" + }, + "redirect_uri": { + "type": "string", + "description": "Redirect URI that was used when obtaining the OAuth code (required by Slack when exchanging the code)" + } + } + }, + "SlackConnection": { + "title": "Slack Connection", + "type": "object", + "description": "Slack Connection", + "additionalProperties": false, + "required": [ + "id", + "slack_workspace_id", + "team_name", + "created_at", + "updated_at" + ], + "properties": { + "id": { "type": "string", - "example": "Send to Slack" - }, - "enabled": { - "type": "boolean" + "format": "uuid", + "description": "Slack connection ID" }, - "url": { + "slack_workspace_id": { "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", - "x-go-name": "URL" - }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "x-go-name": "HTTPHeaders", - "x-go-type-skip-optional-pointer": true + "description": "Slack workspace (team) ID", + "x-go-name": "SlackWorkspaceID" }, - "http_body": { + "team_name": { "type": "string", - "example": "{\"text\": \"Alert: {{alert.name}}\"}", - "x-go-name": "HTTPBody" + "description": "Slack workspace (team) name", + "x-go-name": "TeamName" }, "created_at": { "example": "2017-07-14T16:53:42Z", @@ -18973,35 +14497,33 @@ } } }, - "NotificationDestinationUpdate": { - "title": "Update Notification Destination", + "SlackChannel": { + "title": "Slack Channel", "type": "object", - "description": "Update Notification Destination", + "description": "Slack Channel", "additionalProperties": false, + "required": [ + "id", + "name" + ], "properties": { - "name": { + "id": { "type": "string", - "example": "Send to Slack" - }, - "enabled": { - "type": "boolean" + "description": "Channel ID" }, - "url": { + "name": { "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", - "x-go-name": "URL" + "description": "Channel name" }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "x-go-name": "HTTPHeaders" + "is_private": { + "type": "boolean", + "description": "Whether the channel is private", + "x-go-name": "IsPrivate" }, - "http_body": { - "type": "string", - "example": "{\"text\": \"Alert: {{alert.name}}\"}", - "x-go-name": "HTTPBody" + "is_archived": { + "type": "boolean", + "description": "Whether the channel is archived", + "x-go-name": "IsArchived" } } }, @@ -19342,377 +14864,98 @@ "propertyName": "status", "mapping": { "started": "#/components/schemas/StartedNotification", - "revoked": "#/components/schemas/RevokedNotification", - "failed": "#/components/schemas/FailedNotification", - "deployed": "#/components/schemas/DeployedNotification", - "completed": "#/components/schemas/CompletedNotification", - "completed_account": "#/components/schemas/CompletedSingleAccountNotification" - } - } - }, - "OnboardingAWSAccounts": { - "type": "object", - "description": "AWS OpenID onboarding account structure", - "additionalProperties": false, - "required": [ - "id", - "type" - ], - "properties": { - "id": { - "type": "string", - "description": "ID of the account or OU", - "x-go-name": "ID" - }, - "arn": { - "type": "string", - "description": "ARN of the account or OU", - "x-go-name": "ARN" - }, - "type": { - "type": "string", - "description": "Type of the account", - "enum": [ - "OU", - "account", - "root" - ] - }, - "name": { - "type": "string", - "description": "Display name of the account or OU" - }, - "children": { - "type": "array", - "description": "Children accounts and OUs of the target account", - "items": { - "$ref": "#/components/schemas/OnboardingAWSAccounts" - } - } - } - }, - "OrganizationalUnitID": { - "description": "ID of an organizational unit in AWS", - "type": "string", - "example": "ou-7f3s-j8zfa1ao", - "pattern": "^ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}$", - "x-pattern-message": "must start with \"ou-\" followed by 4 to 32 lowercase letters or digits, then a second \"-\" dash, and finally 8 to 32 additional lowercase letters or digits", - "x-go-name": "OrganizationalUnitID" - }, - "OnboardingAWSProvision": { - "type": "object", - "description": "Stackset provisioning configuration", - "required": [ - "notify_url", - "organizational_units" - ], - "properties": { - "notify_url": { - "type": "string", - "description": "URL that should be used for provisioning notifications (including scheme, hostname, and path)" - }, - "organizational_units": { - "type": "array", - "description": "OUs to provision roles into", - "items": { - "type": "string", - "pattern": "^(r-[0-9a-z]{4,32}|ou-[a-z0-9]{4,32}-[a-z0-9]{8,32})$", - "example": "r-xvfz", - "x-pattern-message": "must start with either \"r-\" followed by 4 to 32 lowercase letters or digits, or \"ou-\" followed by 4 to 32 lowercase letters or digits, a hyphen, and then 8 to 32 lowercase letters or digits, with no additional characters before or after." - } - }, - "skip_accounts": { - "type": "array", - "description": "Account IDs to skip onboarding", - "items": { - "description": "ID of an account in AWS", - "type": "string", - "example": "615713231484", - "pattern": "^\\d{12}$", - "x-pattern-message": "account ID must be exactly 12 digits" - } - } - } - }, - "PlatformPolicySortBy": { - "title": "PlatformPolicySortBy", - "type": "string", - "enum": [ - "id", - "name", - "description", - "status", - "filter_id", - "evaluated_resources", - "rule_violations", - "created_by", - "created_at", - "updated_at" - ] - }, - "PlatformPolicySortDirection": { - "title": "CustomColumnSortDirection", - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - }, - "PlatformPolicy": { - "type": "object", - "required": [ - "id", - "name", - "description", - "status", - "framework_ids", - "resource_categories" - ], - "properties": { - "id": { - "type": "string", - "format": "uuid", - "x-go-name": "ID" - }, - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "status": { - "type": "string", - "enum": [ - "paused", - "active" - ] - }, - "framework_ids": { - "type": "array", - "items": { - "type": "string", - "format": "uuid" - }, - "x-go-name": "FrameworkIDs" - }, - "filter_id": { - "type": "string", - "x-go-name": "FilterID" - }, - "evaluated_resources": { - "type": "integer" - }, - "rule_violations": { - "type": "integer" - }, - "created_by": { - "type": "string", - "description": "Deprecated: Use created_by2 instead" - }, - "created_by2": { - "$ref": "#/components/schemas/CreatedBy" - }, - "updated_by": { - "$ref": "#/components/schemas/CreatedBy" - }, - "created_at": { - "type": "string", - "format": "date-time" - }, - "updated_at": { - "type": "string", - "format": "date-time" - } - } - }, - "PlatformCreateOrUpdatePolicy": { - "type": "object", - "required": [ - "name", - "description", - "framework_ids", - "status" - ], - "properties": { - "name": { - "type": "string" - }, - "description": { - "type": "string" - }, - "framework_ids": { - "type": "array", - "items": { - "type": "string", - "format": "uuid" - }, - "x-go-name": "FrameworkIDs" - }, - "filter_id": { - "type": "string", - "x-go-name": "FilterID" - }, - "status": { - "type": "string", - "enum": [ - "paused", - "active" - ] - } - } - }, - "PlatformPolicyFramework": { - "type": "object", - "properties": { - "id": { - "type": "string", - "format": "uuid", - "x-go-name": "ID" - }, - "label": { - "type": "string" - }, - "description": { - "type": "string" + "revoked": "#/components/schemas/RevokedNotification", + "failed": "#/components/schemas/FailedNotification", + "deployed": "#/components/schemas/DeployedNotification", + "completed": "#/components/schemas/CompletedNotification", + "completed_account": "#/components/schemas/CompletedSingleAccountNotification" } - }, - "required": [ - "id", - "label" - ] - }, - "PlatformPolicyFrameworkSortBy": { - "title": "PlatformPolicyFrameworkSortBy", - "type": "string", - "enum": [ - "id", - "label", - "description" - ] - }, - "PlatformPolicyRuleSortBy": { - "title": "PlatformPolicyRuleSortBy", - "type": "string", - "enum": [ - "id", - "framework_id", - "name", - "description", - "risk", - "category", - "violations", - "version" - ] + } }, - "PlatformPolicyRule": { + "OnboardingAWSAccounts": { "type": "object", + "description": "AWS OpenID onboarding account structure", + "additionalProperties": false, + "required": [ + "id", + "type" + ], "properties": { "id": { "type": "string", - "format": "uuid", + "description": "ID of the account or OU", "x-go-name": "ID" }, - "framework_id": { + "arn": { "type": "string", - "format": "uuid", - "x-go-name": "FrameworkID" - }, - "framework_name": { - "type": "string" - }, - "name": { - "type": "string" + "description": "ARN of the account or OU", + "x-go-name": "ARN" }, - "risk": { + "type": { "type": "string", + "description": "Type of the account", "enum": [ - "critical", - "high", - "medium", - "low" + "OU", + "account", + "root" ] }, - "category": { - "type": "string" - }, - "violations": { - "type": "integer" - }, - "description": { - "type": "string" - }, - "remediation": { - "type": "string" - }, - "learn_more_link": { - "type": "string" - } - } - }, - "PlatformPolicyRuleDetailSortBy": { - "title": "PlatformPolicyRuleDetailSortBy", - "type": "string", - "enum": [ - "name", - "cloud", - "account", - "region", - "tags" - ] - }, - "PlatformPolicyRuleDetail": { - "type": "object", - "properties": { "name": { - "type": "string" - }, - "account": { - "type": "string" - }, - "cloud": { - "type": "string" - }, - "region": { - "type": "string" + "type": "string", + "description": "Display name of the account or OU" }, - "tags": { + "children": { "type": "array", + "description": "Children accounts and OUs of the target account", "items": { - "type": "string" + "$ref": "#/components/schemas/OnboardingAWSAccounts" } } } }, - "PlatformPolicyViolationHistory": { + "OrganizationalUnitID": { + "description": "ID of an organizational unit in AWS", + "type": "string", + "example": "ou-7f3s-j8zfa1ao", + "pattern": "^ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}$", + "x-pattern-message": "must start with \"ou-\" followed by 4 to 32 lowercase letters or digits, then a second \"-\" dash, and finally 8 to 32 additional lowercase letters or digits", + "x-go-name": "OrganizationalUnitID" + }, + "OnboardingAWSProvision": { "type": "object", + "description": "Stackset provisioning configuration", "required": [ - "id", - "rule_violations", - "created_at" + "notify_url", + "organizational_units" ], "properties": { - "id": { + "notify_url": { "type": "string", - "format": "uuid", - "x-go-name": "ID" + "description": "URL that should be used for provisioning notifications (including scheme, hostname, and path)" }, - "rule_violations": { - "type": "integer", - "description": "Number of rule violations logged." + "organizational_units": { + "type": "array", + "description": "OUs to provision roles into", + "items": { + "type": "string", + "pattern": "^(r-[0-9a-z]{4,32}|ou-[a-z0-9]{4,32}-[a-z0-9]{8,32})$", + "example": "r-xvfz", + "x-pattern-message": "must start with either \"r-\" followed by 4 to 32 lowercase letters or digits, or \"ou-\" followed by 4 to 32 lowercase letters or digits, a hyphen, and then 8 to 32 lowercase letters or digits, with no additional characters before or after." + } }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string", - "description": "Time the rule violations were logged." + "skip_accounts": { + "type": "array", + "description": "Account IDs to skip onboarding", + "items": { + "description": "ID of an account in AWS", + "type": "string", + "example": "615713231484", + "pattern": "^\\d{12}$", + "x-pattern-message": "account ID must be exactly 12 digits" + } } } }, - "QueryTag": { - "description": "A saved query tag.", - "type": "string" - }, "QueryExpression": { "title": "QueryExpression", "type": "string", @@ -20095,7 +15338,7 @@ "default": true, "x-omitempty": false, "x-go-type-skip-optional-pointer": true, - "description": "Whether the filter is visible to all users in the team, or only to the user who created it" + "description": "Whether the filter is visible to all users, or only to the user who created it" }, "tags": { "type": "array", @@ -20329,6 +15572,23 @@ ], "default": "safe" }, + "SyncEnvCreate": { + "type": "object", + "description": "Environment variable. Environment variables are assumed to be secret.", + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of the environment variable" + }, + "value": { + "type": "string", + "description": "Value of the environment variable" + } + } + }, "SyncDestinationTestConnectionCreate": { "title": "Sync Destination Test Connection creation definition", "type": "object", @@ -20371,10 +15631,6 @@ "items": { "$ref": "#/components/schemas/SyncEnvCreate" } - }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the destination." } } }, @@ -20561,10 +15817,6 @@ "last_update_source": { "$ref": "#/components/schemas/SyncLastUpdateSource" }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the destination." - }, "transformers": { "type": "array", "items": { @@ -20828,7 +16080,8 @@ "enum": [ "error", "oom_killed", - "partial_success" + "partial_success", + "ingestion_failed" ] }, "ListSyncLastRun": { @@ -20996,10 +16249,6 @@ "$ref": "#/components/schemas/SyncEnvCreate" } }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the destination." - }, "onboarding_id": { "$ref": "#/components/schemas/OnboardingID", "description": "ID of the onboarding that will be used to authenticate the source." @@ -21061,6 +16310,14 @@ "example": "12345678-1234-1234-1234-1234567890ab", "x-go-name": "SyncSourceTestConnectionID" }, + "SyncDestinationName": { + "type": "string", + "example": "my-destination-definition", + "description": "Descriptive, unique name for the destination", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores", + "x-go-name": "SyncDestinationNameField" + }, "PromoteSyncSourceTestConnection": { "title": "Sync Source definition for creating a new source", "description": "Sync Source Definition", @@ -21097,6 +16354,17 @@ "overwrite_source": { "type": "boolean", "description": "Set this to allow overwriting an existing sync source. Defaults to true to preserve compatibility." + }, + "destination_names": { + "type": "array", + "description": "List of sync destination names associated with this source", + "items": { + "$ref": "#/components/schemas/SyncDestinationName" + }, + "minItems": 0, + "default": [ + "cloudquery" + ] } } }, @@ -21159,10 +16427,6 @@ "last_update_source": { "$ref": "#/components/schemas/SyncLastUpdateSource" }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the source." - }, "onboarding_id": { "$ref": "#/components/schemas/OnboardingID", "description": "ID of the onboarding that will be used to authenticate the source." @@ -21256,10 +16520,6 @@ "$ref": "#/components/schemas/SyncEnvCreate" } }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the destination." - }, "onboarding_id": { "$ref": "#/components/schemas/OnboardingID", "description": "ID of the onboarding that will be used to authenticate the source." @@ -21341,45 +16601,213 @@ "description": "Version of the plugin", "example": "v1.2.3" }, - "tables": { - "type": "array", - "description": "Tables to sync. Wildcards are supported. Note that child tables are excluded by default, and need to be explicitly specified.", - "items": { - "type": "string" - } + "tables": { + "type": "array", + "description": "Tables to sync. Wildcards are supported. Note that child tables are excluded by default, and need to be explicitly specified.", + "items": { + "type": "string" + } + }, + "skip_tables": { + "type": "array", + "description": "Tables matched by `tables` that should be skipped. Wildcards are supported.", + "items": { + "type": "string" + } + }, + "spec": { + "type": "object", + "additionalProperties": true, + "format": "Plugin parameters, specific to each plugin" + }, + "env": { + "description": "Environment variables for the plugin. All environment variables will be stored as secrets.", + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncEnv" + } + }, + "last_update_source": { + "$ref": "#/components/schemas/SyncLastUpdateSource" + }, + "onboarding_id": { + "$ref": "#/components/schemas/OnboardingID", + "description": "ID of the onboarding that will be used to authenticate the source." + } + } + }, + "SyncRunWorkerPhase": { + "description": "Phase of the worker in the sync run", + "type": "string", + "enum": [ + "Pending", + "Running", + "Succeeded", + "Failed", + "Unknown" + ] + }, + "SyncRunWorkerStatus": { + "description": "The worker information for a sync run", + "type": "object", + "required": [ + "phase" + ], + "properties": { + "phase": { + "$ref": "#/components/schemas/SyncRunWorkerPhase", + "description": "Phase that the worker is in" + }, + "reason": { + "type": "string", + "description": "The reason for the status of the worker" + } + } + }, + "SyncRun": { + "description": "Managed Sync Run definition", + "type": "object", + "required": [ + "created_at", + "sync_name", + "id", + "status", + "total_rows", + "warnings", + "errors", + "migrate", + "ingested" + ], + "properties": { + "sync_name": { + "type": "string", + "description": "Name of the sync" + }, + "id": { + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "description": "unique ID of the run", + "x-go-name": "ID" + }, + "status": { + "$ref": "#/components/schemas/SyncRunStatus", + "description": "Status of the sync run" + }, + "status_reason": { + "$ref": "#/components/schemas/SyncRunStatusReason", + "description": "Reason for the status of the sync run" }, - "skip_tables": { + "workers": { "type": "array", - "description": "Tables matched by `tables` that should be skipped. Wildcards are supported.", "items": { - "type": "string" - } + "$ref": "#/components/schemas/SyncRunWorkerStatus" + }, + "description": "Information about the workers used in the sync run" }, - "spec": { - "type": "object", - "additionalProperties": true, - "format": "Plugin parameters, specific to each plugin" + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string", + "description": "Time the sync run was created" }, - "env": { - "description": "Environment variables for the plugin. All environment variables will be stored as secrets.", - "type": "array", - "items": { - "$ref": "#/components/schemas/SyncEnv" - } + "completed_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string", + "description": "Time the sync run was completed" }, - "last_update_source": { - "$ref": "#/components/schemas/SyncLastUpdateSource" + "total_rows": { + "type": "integer", + "format": "int64", + "description": "Total number of rows in the sync" }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the source." + "warnings": { + "type": "integer", + "format": "int64", + "description": "Number of warnings encountered during the sync" }, - "onboarding_id": { - "$ref": "#/components/schemas/OnboardingID", - "description": "ID of the onboarding that will be used to authenticate the source." + "errors": { + "type": "integer", + "format": "int64", + "description": "Number of errors encountered during the sync" + }, + "migration": { + "type": "boolean", + "description": "Whether the sync run is a migration" + }, + "ingested": { + "type": "boolean", + "description": "Whether the sync run's data has been ingested" } } }, + "SyncDestinationV2": { + "allOf": [ + { + "$ref": "#/components/schemas/SyncDestinationCreate" + }, + { + "type": "object", + "required": [ + "name", + "display_name", + "path", + "version", + "write_mode", + "migrate_mode", + "spec", + "env", + "created_at", + "updated_at", + "last_update_source", + "draft", + "transformers", + "disabled" + ], + "properties": { + "created_at": { + "type": "string", + "format": "date-time", + "example": "2023-07-14T16:53:42Z", + "description": "Time when the source was created" + }, + "updated_at": { + "type": "string", + "format": "date-time", + "example": "2023-07-14T16:53:42Z", + "description": "Time when the source was last updated" + }, + "env": { + "description": "Environment variables for the plugin.", + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncEnv" + } + }, + "draft": { + "type": "boolean", + "description": "If a sync destination is in draft, it cannot be used in syncs. To get it out of draft, 'promote' it using a successful test connection ID." + }, + "previous_version": { + "type": "string", + "description": "Previous version of the plugin during a version upgrade", + "example": "v1.2.2" + }, + "disabled": { + "type": "boolean", + "description": "If true, the sync destination is disabled and cannot be used in syncs." + }, + "last_run": { + "$ref": "#/components/schemas/SyncRun" + }, + "plugin": { + "$ref": "#/components/schemas/Plugin" + } + } + } + ] + }, "SyncIntegrationV2": { "type": "object", "description": "An integration definition", @@ -21402,6 +16830,13 @@ "plugin": { "$ref": "#/components/schemas/Plugin" }, + "destinations": { + "type": "array", + "description": "List of sync destinations associated with this integration", + "items": { + "$ref": "#/components/schemas/SyncDestinationV2" + } + }, "schedule": { "type": "string", "description": "Cron schedule for the integration" @@ -21411,17 +16846,6 @@ "description": "Whether the integration is disabled", "default": false }, - "cpu": { - "type": "string", - "description": "CPU quota for the integration", - "default": "1", - "x-go-name": "CPU" - }, - "memory": { - "type": "string", - "description": "Memory quota for the integration", - "default": "2Gi" - }, "created_at": { "type": "string", "format": "date-time", @@ -21492,7 +16916,8 @@ "description": "Create a new sync integration", "required": [ "name", - "source" + "source", + "destination_names" ], "properties": { "name": { @@ -21516,16 +16941,16 @@ "description": "Whether the integration is disabled", "default": false }, - "cpu": { - "type": "string", - "description": "CPU quota for the integration", - "default": "1", - "x-go-name": "CPU" - }, - "memory": { - "type": "string", - "description": "Memory quota for the integration", - "default": "2Gi" + "destination_names": { + "type": "array", + "description": "List of sync destination names associated with this integration", + "items": { + "$ref": "#/components/schemas/SyncDestinationName" + }, + "minItems": 0, + "default": [ + "cloudquery" + ] } } }, @@ -21577,17 +17002,12 @@ "type": "boolean", "description": "Whether the integration is disabled" }, - "cpu": { - "type": "string", - "description": "CPU quota for the integration", - "x-go-name": "CPU" - }, - "memory": { - "type": "string", - "description": "Memory quota for the integration" - }, - "last_update_source": { - "$ref": "#/components/schemas/SyncLastUpdateSource" + "destination_names": { + "type": "array", + "description": "List of sync destinations associated with this integration", + "items": { + "$ref": "#/components/schemas/SyncDestinationName" + } } } }, @@ -21615,6 +17035,17 @@ }, "last_update_source": { "$ref": "#/components/schemas/SyncLastUpdateSource" + }, + "destination_names": { + "type": "array", + "description": "List of sync destination names associated with this source", + "items": { + "$ref": "#/components/schemas/SyncDestinationName" + }, + "minItems": 0, + "default": [ + "cloudquery" + ] } } }, @@ -21662,10 +17093,6 @@ }, "last_update_source": { "$ref": "#/components/schemas/SyncLastUpdateSource" - }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the transformer." } } }, @@ -21836,171 +17263,65 @@ "cpu": { "type": "string", "description": "CPU quota for the sync", - "default": "1", - "x-go-name": "CPU" - }, - "memory": { - "type": "string", - "description": "Memory quota for the sync", - "default": "2Gi" - } - } - }, - "SyncUpdate": { - "type": "object", - "description": "Managed Sync definition", - "properties": { - "display_name": { - "$ref": "#/components/schemas/DisplayName" - }, - "source": { - "type": "string", - "description": "Unique name of the source", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - }, - "destinations": { - "type": "array", - "items": { - "type": "string", - "description": "Unique name of the destination", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - }, - "minItems": 1 - }, - "schedule": { - "type": "string", - "description": "Cron schedule for the sync" - }, - "disabled": { - "type": "boolean", - "description": "Whether the sync is disabled", - "default": false - }, - "env": { - "type": "array", - "description": "Environment variables for the sync", - "items": { - "$ref": "#/components/schemas/SyncEnv" - } - }, - "cpu": { - "type": "string", - "description": "CPU quota for the sync", - "default": "1", - "x-go-name": "CPU" - }, - "memory": { - "type": "string", - "description": "Memory quota for the sync", - "default": "2Gi" - } - } - }, - "SyncRunWorkerPhase": { - "description": "Phase of the worker in the sync run", - "type": "string", - "enum": [ - "Pending", - "Running", - "Succeeded", - "Failed", - "Unknown" - ] - }, - "SyncRunWorkerStatus": { - "description": "The worker information for a sync run", - "type": "object", - "required": [ - "phase" - ], - "properties": { - "phase": { - "$ref": "#/components/schemas/SyncRunWorkerPhase", - "description": "Phase that the worker is in" + "default": "1", + "x-go-name": "CPU" }, - "reason": { + "memory": { "type": "string", - "description": "The reason for the status of the worker" + "description": "Memory quota for the sync", + "default": "2Gi" } } }, - "SyncRun": { - "description": "Managed Sync Run definition", + "SyncUpdate": { "type": "object", - "required": [ - "created_at", - "sync_name", - "id", - "status", - "total_rows", - "warnings", - "errors", - "migrate", - "ingested" - ], + "description": "Managed Sync definition", "properties": { - "sync_name": { - "type": "string", - "description": "Name of the sync" + "display_name": { + "$ref": "#/components/schemas/DisplayName" }, - "id": { + "source": { "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "description": "unique ID of the run", - "x-go-name": "ID" - }, - "status": { - "$ref": "#/components/schemas/SyncRunStatus", - "description": "Status of the sync run" - }, - "status_reason": { - "$ref": "#/components/schemas/SyncRunStatusReason", - "description": "Reason for the status of the sync run" + "description": "Unique name of the source", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" }, - "workers": { + "destinations": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncRunWorkerStatus" + "type": "string", + "description": "Unique name of the destination", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" }, - "description": "Information about the workers used in the sync run" - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string", - "description": "Time the sync run was created" + "minItems": 1 }, - "completed_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", + "schedule": { "type": "string", - "description": "Time the sync run was completed" - }, - "total_rows": { - "type": "integer", - "format": "int64", - "description": "Total number of rows in the sync" + "description": "Cron schedule for the sync" }, - "warnings": { - "type": "integer", - "format": "int64", - "description": "Number of warnings encountered during the sync" + "disabled": { + "type": "boolean", + "description": "Whether the sync is disabled", + "default": false }, - "errors": { - "type": "integer", - "format": "int64", - "description": "Number of errors encountered during the sync" + "env": { + "type": "array", + "description": "Environment variables for the sync", + "items": { + "$ref": "#/components/schemas/SyncEnv" + } }, - "migration": { - "type": "boolean", - "description": "Whether the sync run is a migration" + "cpu": { + "type": "string", + "description": "CPU quota for the sync", + "default": "1", + "x-go-name": "CPU" }, - "ingested": { - "type": "boolean", - "description": "Whether the sync run's data has been ingested" + "memory": { + "type": "string", + "description": "Memory quota for the sync", + "default": "2Gi" } } }, @@ -22116,6 +17437,18 @@ } } }, + "SyncRunTableSortBy": { + "title": "TableSortBy", + "type": "string", + "enum": [ + "name", + "started_at", + "completed_at", + "runtime_seconds", + "resources", + "errors" + ] + }, "SyncRunTableStat": { "type": "object", "required": [ @@ -22168,89 +17501,132 @@ } } }, - "ConnectorCredentialsResponseAWS": { + "TableListItem": { "additionalProperties": false, - "required": [ - "access_key_id", - "secret_access_key", - "session_token", - "source", - "can_expire", - "expires" - ], "properties": { - "access_key_id": { - "type": "string" - }, - "secret_access_key": { - "type": "string" - }, - "session_token": { - "type": "string" - }, - "source": { - "type": "string" - }, - "can_expire": { - "type": "boolean" - }, - "expires": { - "type": "string", - "format": "date-time" + "name": { + "$ref": "#/components/schemas/TableName" } }, - "type": "object", - "description": "AWS connector credentials response" + "required": [ + "name" + ], + "title": "TableListItem", + "type": "object" }, - "ConnectorCredentialsResponseOAuth": { - "additionalProperties": false, + "TableDataListItem": { + "description": "Sync with its associated tables", + "type": "object", "required": [ - "access_token" + "sync_name", + "tables" ], "properties": { - "access_token": { - "type": "string" + "sync_name": { + "type": "string", + "description": "The unique name of the sync (source_name from synced_tables)", + "example": "aws-integration" }, - "expires": { + "display_name": { "type": "string", - "format": "date-time" + "description": "Human-readable display name of the sync", + "example": "AWS Integration" + }, + "plugin": { + "$ref": "#/components/schemas/SyncPluginPath", + "example": "cloudquery/aws" + }, + "tables": { + "type": "array", + "items": { + "type": "object", + "required": [ + "name", + "deletion_pending" + ], + "properties": { + "name": { + "type": "string", + "description": "The table name" + }, + "deletion_pending": { + "type": "boolean", + "description": "Whether this table's data is marked for deletion" + } + } + }, + "description": "List of tables synced by this integration with their deletion status", + "example": [ + { + "name": "aws_ec2_instances", + "deletion_pending": false + }, + { + "name": "aws_s3_buckets", + "deletion_pending": true + } + ] } }, - "type": "object", - "description": "OAuth connector credentials response" + "example": { + "sync_name": "aws-integration", + "display_name": "AWS Integration", + "plugin": "cloudquery/aws", + "tables": [ + { + "name": "aws_ec2_instances", + "deletion_pending": false + }, + { + "name": "aws_s3_buckets", + "deletion_pending": false + }, + { + "name": "aws_iam_users", + "deletion_pending": true + } + ] + } }, - "ConnectorIdentityResponseAWS": { - "additionalProperties": false, + "TableDataAction": { + "description": "Request body for performing actions on table data", + "type": "object", "required": [ - "role_arn" + "action", + "syncs" ], "properties": { - "role_arn": { + "action": { "type": "string", - "description": "Role ARN to assume", - "x-go-name": "RoleARN" - } - }, - "type": "object", - "description": "AWS connector identity response" - }, - "TableListItem": { - "additionalProperties": false, - "properties": { - "name": { - "$ref": "#/components/schemas/TableName" + "enum": [ + "delete" + ], + "description": "The action to perform on the table data" }, - "total_rows": { - "type": "integer", - "x-go-type": "uint64" + "syncs": { + "type": "object", + "description": "Map of sync names to arrays of table names", + "additionalProperties": { + "type": "array", + "items": { + "type": "string", + "description": "Table name to perform action on" + } + } } }, - "required": [ - "name", - "rows" - ], - "title": "TableListItem", - "type": "object" + "example": { + "action": "delete", + "syncs": { + "sync_name_1": [ + "table_1", + "table_2" + ], + "sync_name_2": [ + "table_3" + ] + } + } }, "TableRowID": { "description": "ID of the Resource", @@ -22426,31 +17802,6 @@ "title": "TableColumnValueListItem", "type": "object" }, - "TableRelation": { - "additionalProperties": false, - "properties": { - "table_name": { - "type": "string", - "example": "aws_ec2_images", - "x-go-name": "Table" - }, - "label": { - "type": "string", - "example": "EC2 Image" - }, - "query": { - "type": "string", - "example": "SELECT aws_ec2_images.* FROM aws_ec2_instances JOIN aws_ec2_images ON aws_ec2_instances.image_id = aws_ec2_images.image_id" - } - }, - "required": [ - "table_name", - "label", - "query" - ], - "title": "TableRelation", - "type": "object" - }, "UsageSummaryGroup": { "title": "CloudQuery Usage Summary Group", "description": "A usage summary group.", @@ -22618,84 +17969,207 @@ } } }, - "ImageURL": { + "SAMLConfig": { + "title": "SAML Configuration", + "type": "object", + "additionalProperties": false, + "required": [ + "platform_metadata_download_url", + "platform_certificate_download_url", + "platform_sso_url", + "platform_entity_id", + "enabled", + "can_enable" + ], "properties": { - "upload_url": { + "platform_sso_url": { + "type": "string", + "description": "SAML service URL.", + "format": "url", + "x-go-name": "PlatformSSOURL" + }, + "platform_entity_id": { + "type": "string", + "description": "SAML Entity ID.", + "x-go-name": "PlatformEntityID" + }, + "platform_metadata_download_url": { + "type": "string", + "description": "URL to download platform metadata.", + "format": "url", + "x-go-name": "PlatformMetadataDownloadURL" + }, + "platform_certificate_download_url": { + "type": "string", + "description": "Platform Certificate download URL", + "format": "url", + "x-go-name": "PlatformCertificateDownloadURL" + }, + "metadata_url": { + "type": "string", + "description": "Metadata URL from identity provider. Mutually exclusive with `metadata_xml`", + "format": "url", + "x-go-name": "MetadataURL" + }, + "metadata_xml": { "type": "string", - "example": "https://cloudquery.io/api/v1/upload/1234567890abcdef1234567890abcdef" + "description": "Metadata file contents from identity provider. Mutually exclusive with `metadata_url`", + "format": "url", + "x-go-name": "MetadataXML" + }, + "logout_url": { + "type": "string", + "description": "Logout URL from identity provider", + "format": "url", + "x-go-name": "LogoutURL" }, - "download_url": { + "role_group_key": { "type": "string", - "example": "https://cloudquery.io/api/v1/download/1234567890abcdef1234567890abcdef" + "description": "Role group key name", + "example": "groups" }, - "required_headers": { + "role_mappings": { "type": "object", + "description": "Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group.", "additionalProperties": { "type": "array", "items": { - "type": "string" + "$ref": "#/components/schemas/Role" } }, - "description": "Required HTTP headers to include for the upload" + "x-go-type-skip-optional-pointer": true + }, + "default_roles": { + "type": "array", + "description": "Default roles for new users who are not in any group", + "items": { + "$ref": "#/components/schemas/Role" + }, + "x-go-type-skip-optional-pointer": true, + "x-omitempty": false + }, + "disable_access_if_no_role_group": { + "type": "boolean", + "description": "Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in." + }, + "enabled": { + "type": "boolean", + "description": "Whether SAML is enabled" + }, + "can_enable": { + "type": "boolean", + "description": "Whether SAML can be enabled" } - }, - "required": [ - "upload_url", - "download_url", - "required_headers" - ] + } }, - "InvitationWithToken": { + "SAMLConfigUpdate": { + "title": "SAML Configuration Update", + "type": "object", "additionalProperties": false, - "allOf": [ - { - "$ref": "#/components/schemas/Invitation" + "properties": { + "metadata_url": { + "type": "string", + "description": "Metadata URL from identity provider. Mutually exclusive with `metadata_xml`", + "format": "url", + "x-go-name": "MetadataURL" }, - { + "metadata_xml": { + "type": "string", + "description": "Metadata file contents from identity provider. Mutually exclusive with `metadata_url`", + "format": "url", + "x-go-name": "MetadataXML" + }, + "logout_url": { + "type": "string", + "description": "Logout URL from identity provider", + "format": "url", + "x-go-name": "LogoutURL" + }, + "role_group_key": { + "type": "string", + "description": "Role group key name" + }, + "role_mappings": { "type": "object", - "properties": { - "token": { - "type": "string", - "format": "uuid", - "description": "The token used to accept the invitation" + "description": "Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group.", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RoleID" } - }, - "required": [ - "token" - ] + } + }, + "default_roles": { + "type": "array", + "description": "Default roles for new users who are not in any group", + "items": { + "$ref": "#/components/schemas/RoleID" + } + }, + "disable_access_if_no_role_group": { + "type": "boolean", + "description": "Whether to disable access if no role group is found in the SAML assertion. If true, users without a role group will not be able to log in." + }, + "enabled": { + "type": "boolean", + "description": "Whether to enable or disable SAML" } - ] + } }, - "RegistryAuthToken": { + "PlatformSettings": { "type": "object", - "description": "JWT token for the image registry", - "additionalProperties": false, + "description": "Platform settings definition", + "required": [ + "enforce_mfa" + ], "properties": { - "access_token": { - "type": "string" - }, - "token": { - "type": "string" + "enforce_mfa": { + "type": "boolean", + "description": "Whether or not to require MFA for all users", + "default": false } - }, - "required": [ - "access_token", - "token" - ] + } }, - "DockerError": { - "additionalProperties": false, - "description": "Error Returned from the Docker Authorization Handler to the Docker Registry", + "PlatformSettingsUpdate": { + "type": "object", + "description": "Platform settings partial update", + "properties": { + "enforce_mfa": { + "type": "boolean", + "description": "Whether or not to require MFA for all users", + "default": false + } + } + }, + "PlatformDataSettings": { + "type": "object", + "description": "Platform data settings definition", "required": [ - "details" + "ownership_tags" ], "properties": { - "details": { - "type": "string" + "ownership_tags": { + "type": "array", + "description": "List of tag names for asset ownership", + "items": { + "type": "string" + }, + "default": [] } - }, - "title": "Docker Error", - "type": "object" + } + }, + "PlatformDataSettingsUpdate": { + "type": "object", + "description": "Platform data settings partial update", + "properties": { + "ownership_tags": { + "type": "array", + "description": "List of tag names for asset ownership", + "items": { + "type": "string" + } + } + } }, "CreateSyncDestinationTestConnectionV2": { "title": "Sync Destination Test Connection creation definition", @@ -22739,10 +18213,6 @@ "items": { "$ref": "#/components/schemas/SyncEnvCreate" } - }, - "connector_id": { - "$ref": "#/components/schemas/ConnectorID", - "description": "ID of the connector that will be used to authenticate the destination." } } }, @@ -22798,72 +18268,6 @@ } } }, - "SyncDestinationV2": { - "allOf": [ - { - "$ref": "#/components/schemas/SyncDestinationCreate" - }, - { - "type": "object", - "required": [ - "name", - "display_name", - "path", - "version", - "write_mode", - "migrate_mode", - "spec", - "env", - "created_at", - "updated_at", - "last_update_source", - "draft", - "transformers", - "disabled" - ], - "properties": { - "created_at": { - "type": "string", - "format": "date-time", - "example": "2023-07-14T16:53:42Z", - "description": "Time when the source was created" - }, - "updated_at": { - "type": "string", - "format": "date-time", - "example": "2023-07-14T16:53:42Z", - "description": "Time when the source was last updated" - }, - "env": { - "description": "Environment variables for the plugin.", - "type": "array", - "items": { - "$ref": "#/components/schemas/SyncEnv" - } - }, - "draft": { - "type": "boolean", - "description": "If a sync destination is in draft, it cannot be used in syncs. To get it out of draft, 'promote' it using a successful test connection ID." - }, - "previous_version": { - "type": "string", - "description": "Previous version of the plugin during a version upgrade", - "example": "v1.2.2" - }, - "disabled": { - "type": "boolean", - "description": "If true, the sync destination is disabled and cannot be used in syncs." - }, - "last_run": { - "$ref": "#/components/schemas/SyncRun" - }, - "plugin": { - "$ref": "#/components/schemas/Plugin" - } - } - } - ] - }, "CreateSyncDestinationV2": { "title": "Sync Destination definition for creating a new source", "description": "Sync Destination Definition", @@ -23054,6 +18458,20 @@ } } } + }, + "Team": { + "additionalProperties": false, + "description": "CloudQuery Team", + "properties": { + "name": { + "$ref": "#/components/schemas/TeamName" + } + }, + "required": [ + "name" + ], + "title": "Team", + "type": "object" } }, "responses": { @@ -23117,16 +18535,6 @@ }, "description": "Service unavailable" }, - "UnprocessableEntity": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FieldError" - } - } - }, - "description": "UnprocessableEntity" - }, "TooManyRequests": { "content": { "application/json": { @@ -23137,17 +18545,17 @@ }, "description": "Too Many Requests" }, - "MethodNotAllowed": { + "UnprocessableEntity": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/BasicError" + "$ref": "#/components/schemas/FieldError" } } }, - "description": "Method not allowed" + "description": "UnprocessableEntity" }, - "Conflict": { + "MethodNotAllowed": { "content": { "application/json": { "schema": { @@ -23155,17 +18563,7 @@ } } }, - "description": "Conflict" - }, - "DockerError": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DockerError" - } - } - }, - "description": "Error Returned from the Docker Authorization Handler to the Docker Registry" + "description": "Method not allowed" } } } From 04b830178496dbb5fc4937a932f08750ba222e88 Mon Sep 17 00:00:00 2001 From: Kemal Hadimli Date: Mon, 16 Feb 2026 13:28:37 +0000 Subject: [PATCH 2/4] update import path --- go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.mod b/go.mod index af7573a..0bd5a8d 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/cloudquery/cloudquery-platform-api-go +module github.com/cloudquery/cloudquery-platform-api-go/v2 go 1.25.5 From e31d70b903330d984651ba67891c9610ff021874 Mon Sep 17 00:00:00 2001 From: Kemal Hadimli Date: Mon, 16 Feb 2026 14:03:01 +0000 Subject: [PATCH 3/4] update api --- client.gen.go | 12 ++++++++++-- spec.json | 11 +++++++++-- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/client.gen.go b/client.gen.go index cf18fd5..d706f94 100644 --- a/client.gen.go +++ b/client.gen.go @@ -23465,7 +23465,11 @@ type GetPlatformInfoResponse struct { Body []byte HTTPResponse *http.Response JSON200 *struct { - PublicIps *[]string `json:"public_ips,omitempty"` + // PublicIPs List of public IPs for the platform + PublicIPs *[]string `json:"public_ips,omitempty"` + + // Version Version of the platform + Version string `json:"version"` } JSON401 *RequiresAuthentication JSON500 *InternalError @@ -32490,7 +32494,11 @@ func ParseGetPlatformInfoResponse(rsp *http.Response) (*GetPlatformInfoResponse, switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - PublicIps *[]string `json:"public_ips,omitempty"` + // PublicIPs List of public IPs for the platform + PublicIPs *[]string `json:"public_ips,omitempty"` + + // Version Version of the platform + Version string `json:"version"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err diff --git a/spec.json b/spec.json index 30c635b..e69ac15 100644 --- a/spec.json +++ b/spec.json @@ -396,14 +396,21 @@ "application/json": { "schema": { "required": [ - "items" + "items", + "version" ], "properties": { "public_ips": { "type": "array", + "description": "List of public IPs for the platform", "items": { "type": "string" - } + }, + "x-go-name": "PublicIPs" + }, + "version": { + "type": "string", + "description": "Version of the platform" } } } From 22efab623af1ad3a021b6f784a303dc7be86ad6b Mon Sep 17 00:00:00 2001 From: Kemal Hadimli Date: Thu, 19 Mar 2026 14:36:04 +0000 Subject: [PATCH 4/4] update --- client.gen.go | 14249 +++++++++++++++++++++++++++++++----------------- spec.json | 13987 +++++++++++++++++++++++++++-------------------- 2 files changed, 17282 insertions(+), 10954 deletions(-) diff --git a/client.gen.go b/client.gen.go index d706f94..be73662 100644 --- a/client.gen.go +++ b/client.gen.go @@ -92,6 +92,14 @@ const ( CustomColumnSortDirectionDesc CustomColumnSortDirection = "desc" ) +// Defines values for InsightSeverity. +const ( + InsightSeverityCritical InsightSeverity = "Critical" + InsightSeverityHigh InsightSeverity = "High" + InsightSeverityLow InsightSeverity = "Low" + InsightSeverityMedium InsightSeverity = "Medium" +) + // Defines values for NotificationDestinationType. const ( NotificationDestinationTypeSlack NotificationDestinationType = "slack" @@ -460,6 +468,48 @@ const ( VersionSortByCreatedAt VersionSortBy = "created_at" ) +// Defines values for ListPlatformInsightsParamsSortBy. +const ( + ListPlatformInsightsParamsSortByAccount ListPlatformInsightsParamsSortBy = "account" + ListPlatformInsightsParamsSortByAccountsCount ListPlatformInsightsParamsSortBy = "accounts_count" + ListPlatformInsightsParamsSortByCreatedAt ListPlatformInsightsParamsSortBy = "created_at" + ListPlatformInsightsParamsSortByDetectedAt ListPlatformInsightsParamsSortBy = "detected_at" + ListPlatformInsightsParamsSortByInsightCategory ListPlatformInsightsParamsSortBy = "insight_category" + ListPlatformInsightsParamsSortByResourceTypes ListPlatformInsightsParamsSortBy = "resource_types" + ListPlatformInsightsParamsSortByResourcesCount ListPlatformInsightsParamsSortBy = "resources_count" + ListPlatformInsightsParamsSortBySeverity ListPlatformInsightsParamsSortBy = "severity" + ListPlatformInsightsParamsSortBySource ListPlatformInsightsParamsSortBy = "source" + ListPlatformInsightsParamsSortBySourceCategory ListPlatformInsightsParamsSortBy = "source_category" + ListPlatformInsightsParamsSortByTitle ListPlatformInsightsParamsSortBy = "title" +) + +// Defines values for ListPlatformInsightsParamsSortDir. +const ( + ListPlatformInsightsParamsSortDirAsc ListPlatformInsightsParamsSortDir = "asc" + ListPlatformInsightsParamsSortDirDesc ListPlatformInsightsParamsSortDir = "desc" +) + +// Defines values for GetPlatformAssetInsightsParamsSortBy. +const ( + GetPlatformAssetInsightsParamsSortByAccount GetPlatformAssetInsightsParamsSortBy = "account" + GetPlatformAssetInsightsParamsSortByAccountsCount GetPlatformAssetInsightsParamsSortBy = "accounts_count" + GetPlatformAssetInsightsParamsSortByCreatedAt GetPlatformAssetInsightsParamsSortBy = "created_at" + GetPlatformAssetInsightsParamsSortByDetectedAt GetPlatformAssetInsightsParamsSortBy = "detected_at" + GetPlatformAssetInsightsParamsSortByInsightCategory GetPlatformAssetInsightsParamsSortBy = "insight_category" + GetPlatformAssetInsightsParamsSortByResourceTypes GetPlatformAssetInsightsParamsSortBy = "resource_types" + GetPlatformAssetInsightsParamsSortByResourcesCount GetPlatformAssetInsightsParamsSortBy = "resources_count" + GetPlatformAssetInsightsParamsSortBySeverity GetPlatformAssetInsightsParamsSortBy = "severity" + GetPlatformAssetInsightsParamsSortBySource GetPlatformAssetInsightsParamsSortBy = "source" + GetPlatformAssetInsightsParamsSortBySourceCategory GetPlatformAssetInsightsParamsSortBy = "source_category" + GetPlatformAssetInsightsParamsSortByTitle GetPlatformAssetInsightsParamsSortBy = "title" +) + +// Defines values for GetPlatformAssetInsightsParamsSortDir. +const ( + GetPlatformAssetInsightsParamsSortDirAsc GetPlatformAssetInsightsParamsSortDir = "asc" + GetPlatformAssetInsightsParamsSortDirDesc GetPlatformAssetInsightsParamsSortDir = "desc" +) + // Defines values for ListPluginsParamsSortBy. const ( ListPluginsParamsSortByCreatedAt ListPluginsParamsSortBy = "created_at" @@ -895,7 +945,7 @@ type CreateSyncDestinationTestConnectionV2 struct { SyncGroupID *string `json:"sync_group_id,omitempty"` // Version Version of the plugin - Version string `json:"version"` + Version *string `json:"version,omitempty"` // WriteMode Write mode for the destination WriteMode *SyncDestinationWriteMode `json:"write_mode,omitempty"` @@ -979,6 +1029,17 @@ type CustomColumnSortDirection string // CustomColumnValueExpr The SQL expression for the custom column. type CustomColumnValueExpr = string +// DeployedCURNotification defines model for DeployedCURNotification. +type DeployedCURNotification struct { + CurReportName string `json:"cur_report_name"` + MainRoleArn string `json:"main_role_arn"` + S3BucketName string `json:"s3_bucket_name"` + S3ReportPrefix string `json:"s3_report_prefix"` + StackId string `json:"stack_id"` + Status interface{} `json:"status"` + SyncRoleArn string `json:"sync_role_arn"` +} + // DeployedNotification defines model for DeployedNotification. type DeployedNotification struct { DeploymentMode string `json:"deployment_mode"` @@ -1059,6 +1120,71 @@ type FilterUpdate struct { Tags *[]FilterTag `json:"tags,omitempty"` } +// Insight Security or compliance insight summary +type Insight struct { + // AccountsCount Number of accounts affected + AccountsCount int64 `json:"accounts_count"` + + // CreatedAt When the insight record was created + CreatedAt time.Time `json:"created_at"` + + // DetectedAt When the insight was first detected + DetectedAt time.Time `json:"detected_at"` + + // Evidence Detailed evidence (description) of the insight (Markdown) + Evidence *string `json:"evidence,omitempty"` + + // InsightID Unique identifier for the insight + InsightID InsightID `json:"id"` + + // InsightCategory Category (e.g. Security, Cost Optimization) + InsightCategory string `json:"insight_category"` + + // LastSyncedAt When the insight was last synced + LastSyncedAt time.Time `json:"last_synced_at"` + + // Mitigation Mitigation steps for the insight (Markdown) + Mitigation *string `json:"mitigation,omitempty"` + + // ResourceTypes Resource types affected + ResourceTypes string `json:"resource_types"` + + // ResourcesCount Number of resources affected + ResourcesCount int64 `json:"resources_count"` + + // InsightSeverity Insight severity level + InsightSeverity InsightSeverity `json:"severity"` + + // Source Source (e.g. Platform, Wiz, Lacework) + Source string `json:"source"` + + // SourceCategory Source category (e.g. Platform, Third Party, Custom) + SourceCategory string `json:"source_category"` + Subcategory *string `json:"subcategory"` + + // Tags Tags associated with the insight + Tags *[]string `json:"tags,omitempty"` + + // Title Title of the insight + Title string `json:"title"` +} + +// InsightID Unique identifier for the insight +type InsightID = string + +// InsightSeverity Insight severity level +type InsightSeverity string + +// InsightsListMetadata defines model for InsightsListMetadata. +type InsightsListMetadata struct { + LastPage *int `json:"last_page,omitempty"` + PageSize int `json:"page_size"` + ResourceCount *int `json:"resource_count,omitempty"` + ResourceTypes *int `json:"resource_types,omitempty"` + TimeMs *int `json:"time_ms,omitempty"` + TotalCount *int `json:"total_count,omitempty"` +} + // ListMetadata defines model for ListMetadata. type ListMetadata struct { LastPage *int `json:"last_page,omitempty"` @@ -1307,6 +1433,9 @@ type NotificationDestinationListItem struct { NotificationDestinationID NotificationDestinationID `json:"id"` Name string `json:"name"` + // SlackChannels List of Slack channel names (only for slack type) + SlackChannels *[]string `json:"slack_channels,omitempty"` + // Type Type of notification destination Type NotificationDestinationListItemType `json:"type"` UpdatedAt time.Time `json:"updated_at"` @@ -1442,6 +1571,76 @@ type OnboardingAWSAccounts struct { // OnboardingAWSAccountsType Type of the account type OnboardingAWSAccountsType string +// OnboardingAWSCUR AWS CUR onboarding +type OnboardingAWSCUR struct { + // Audience OpenID audience claim for the trust relationship + Audience string `json:"audience"` + CreatedAt time.Time `json:"created_at"` + + // CURReportName Name of the CUR report + CURReportName *string `json:"cur_report_name,omitempty"` + + // FailureReason Error details if the onboarding failed + FailureReason *string `json:"failure_reason,omitempty"` + + // OnboardingID ID of the cloud provider onboarding session + OnboardingID OnboardingID `json:"id"` + + // IssuerURL URL of the OpenID server to use when setting up a trust relationship + IssuerURL string `json:"issuer_url"` + + // S3BucketName Name of the S3 bucket containing CUR reports + S3BucketName *string `json:"s3_bucket_name,omitempty"` + + // S3ReportPrefix Prefix path for CUR reports in the S3 bucket + S3ReportPrefix *string `json:"s3_report_prefix,omitempty"` + + // OnboardingStage Stage of the onboarding process + OnboardingStage string `json:"stage"` + + // Subject OpenID subject claim for the trust relationship + Subject string `json:"subject"` + + // SyncRoleARN Role used to access the S3 bucket with CUR reports + SyncRoleARN *string `json:"sync_role_arn,omitempty"` + UpdatedAt time.Time `json:"updated_at"` +} + +// OnboardingAWSCURCreateResponse AWS CUR onboarding create response +type OnboardingAWSCURCreateResponse struct { + // Audience OpenID audience claim for the trust relationship + Audience string `json:"audience"` + + // OnboardingID ID of the cloud provider onboarding session + OnboardingID OnboardingID `json:"id"` + + // IssuerURL URL of the OpenID server to use when setting up a trust relationship + IssuerURL string `json:"issuer_url"` + + // NotifyPath Path of the notify endpoint to use for status updates + NotifyPath string `json:"notify_path"` + + // NotifyToken An authentication token that should be used for notifications + NotifyToken string `json:"notify_token"` + + // Region AWS region where the CUR stack must be deployed. Always 'us-east-1' because AWS Cost and Usage Reports are only available in that region. + Region string `json:"region"` + + // StackName Stack name that should be used + StackName *string `json:"stack_name,omitempty"` + + // Subject OpenID subject claim for the trust relationship + Subject string `json:"subject"` + + // TemplateURL URL of the CloudFormation template to use for the CUR setup + TemplateURL string `json:"template_url"` +} + +// OnboardingAWSCURNotification defines model for OnboardingAWSCURNotification. +type OnboardingAWSCURNotification struct { + union json.RawMessage +} + // OnboardingAWSCreateResponse AWS OpenID onboarding type OnboardingAWSCreateResponse struct { // Audience OpenID audience claim for the trust realshionship @@ -1507,6 +1706,75 @@ type PlatformDataSettingsUpdate struct { OwnershipTags *[]string `json:"ownership_tags,omitempty"` } +// PlatformInsightFilter Saved insight filter details +type PlatformInsightFilter struct { + Accounts *[]string `json:"accounts,omitempty"` + Clouds *[]string `json:"clouds,omitempty"` + CreatedAt time.Time `json:"created_at"` + Description *string `json:"description,omitempty"` + GroupBy *[]string `json:"group_by,omitempty"` + Id openapi_types.UUID `json:"id"` + InsightCategory *[]string `json:"insight_category,omitempty"` + Name string `json:"name"` + + // OwnershipTags Ownership tag filters keyed by tag name + OwnershipTags *map[string][]string `json:"ownership_tags,omitempty"` + Regions *[]string `json:"regions,omitempty"` + ResourceTypes *[]string `json:"resource_types,omitempty"` + Search *string `json:"search,omitempty"` + Severities *[]InsightSeverity `json:"severities,omitempty"` + Source *[]string `json:"source,omitempty"` + SourceCategory *[]string `json:"source_category,omitempty"` + Tags *[]string `json:"tags,omitempty"` + UpdatedAt time.Time `json:"updated_at"` + + // UserID ID of the User + UserID *UserID `json:"user_id,omitempty"` +} + +// PlatformInsightFilterCreate Definition for creating a new saved insight filter +type PlatformInsightFilterCreate struct { + Accounts *[]string `json:"accounts,omitempty"` + Clouds *[]string `json:"clouds,omitempty"` + Description *string `json:"description,omitempty"` + GroupBy *[]string `json:"group_by,omitempty"` + InsightCategory *[]string `json:"insight_category,omitempty"` + Name string `json:"name"` + + // OwnershipTags Ownership tag filters keyed by tag name + OwnershipTags *map[string][]string `json:"ownership_tags,omitempty"` + Regions *[]string `json:"regions,omitempty"` + ResourceTypes *[]string `json:"resource_types,omitempty"` + Search *string `json:"search,omitempty"` + Severities *[]InsightSeverity `json:"severities,omitempty"` + Source *[]string `json:"source,omitempty"` + SourceCategory *[]string `json:"source_category,omitempty"` + Tags *[]string `json:"tags,omitempty"` +} + +// InsightFilterID The unique ID for the insight filter +type InsightFilterID = openapi_types.UUID + +// PlatformInsightFilterUpdate Definition for updating an existing saved insight filter +type PlatformInsightFilterUpdate struct { + Accounts *[]string `json:"accounts,omitempty"` + Clouds *[]string `json:"clouds,omitempty"` + Description *string `json:"description,omitempty"` + GroupBy *[]string `json:"group_by,omitempty"` + InsightCategory *[]string `json:"insight_category,omitempty"` + Name *string `json:"name,omitempty"` + + // OwnershipTags Ownership tag filters keyed by tag name + OwnershipTags *map[string][]string `json:"ownership_tags,omitempty"` + Regions *[]string `json:"regions,omitempty"` + ResourceTypes *[]string `json:"resource_types,omitempty"` + Search *string `json:"search,omitempty"` + Severities *[]InsightSeverity `json:"severities,omitempty"` + Source *[]string `json:"source,omitempty"` + SourceCategory *[]string `json:"source_category,omitempty"` + Tags *[]string `json:"tags,omitempty"` +} + // PlatformSettings Platform settings definition type PlatformSettings struct { // EnforceMfa Whether or not to require MFA for all users @@ -2004,6 +2272,9 @@ type PolicyViolation struct { Name string `json:"name"` Region string `json:"region"` ResourceTypeLabel string `json:"resource_type_label"` + + // Tags Tags associated with the resource (e.g. for insights) + Tags *[]string `json:"tags,omitempty"` } // PromoteSyncDestinationTestConnection Sync Destination Definition @@ -2052,9 +2323,12 @@ type Query struct { Alert *Alert `json:"alert,omitempty"` // AlertConfigured Indicates if the query has an alert configured - AlertConfigured bool `json:"alert_configured"` - CreatedAt time.Time `json:"created_at"` - Description *string `json:"description,omitempty"` + AlertConfigured bool `json:"alert_configured"` + + // Columns Columns returned by this query + Columns []string `json:"columns,omitempty"` + CreatedAt time.Time `json:"created_at"` + Description *string `json:"description,omitempty"` // QueryID The unique ID for the query. QueryID QueryID `json:"id"` @@ -2091,9 +2365,12 @@ type QueryDetail struct { Alert *AlertDetail `json:"alert,omitempty"` // AlertConfigured Indicates if the query has an alert configured. When this is set, the alert field will be populated with the alert details. - AlertConfigured bool `json:"alert_configured"` - CreatedAt time.Time `json:"created_at"` - Description *string `json:"description,omitempty"` + AlertConfigured bool `json:"alert_configured"` + + // Columns Columns returned by this query + Columns []string `json:"columns,omitempty"` + CreatedAt time.Time `json:"created_at"` + Description *string `json:"description,omitempty"` // QueryID The unique ID for the query. QueryID QueryID `json:"id"` @@ -2195,6 +2472,36 @@ type RBACRoleUpdate struct { Permissions *[]RBACPermissionID `json:"permissions,omitempty"` } +// RelationColumnDef defines model for RelationColumnDef. +type RelationColumnDef struct { + // Field Column field name in the query result. + Field string `json:"field"` + + // Hidden Whether the column is present for navigation but not displayed. + Hidden *bool `json:"hidden,omitempty"` + + // Label Display label for the column. + Label string `json:"label"` + + // Type Column render type (e.g. text, tags, boolean, json, code). + Type *string `json:"type,omitempty"` +} + +// RelationDef defines model for RelationDef. +type RelationDef struct { + // Columns Column definitions for the relation view. + Columns []RelationColumnDef `json:"columns"` + + // ResourceType Target CloudQuery table name. + ResourceType string `json:"resource_type"` + + // SqlQuery ClickHouse SQL template with {{field_name}} placeholders. + SqlQuery string `json:"sql_query"` + + // Title Display title for the relation tab/section. + Title string `json:"title"` +} + // Report defines model for Report. type Report struct { // Content YAML body @@ -2296,6 +2603,12 @@ type SAMLConfig struct { // CanEnable Whether SAML can be enabled CanEnable bool `json:"can_enable"` + // CertificateExpiresAt Expiration time of the current SAML certificate + CertificateExpiresAt *time.Time `json:"certificate_expires_at,omitempty"` + + // CertificateFingerprint Fingerprint of the current SAML certificate + CertificateFingerprint *string `json:"certificate_fingerprint,omitempty"` + // DefaultRoles Default roles for new users who are not in any group DefaultRoles []Role `json:"default_roles"` @@ -2331,6 +2644,12 @@ type SAMLConfig struct { // RoleMappings Mapping from IdP group names to roles. Each key is a potential IdP group value for the specified role_group_key, and each value is an array of roles to assign to users in that group. RoleMappings map[string][]Role `json:"role_mappings,omitempty"` + + // RolloverCertificateExpiresAt Expiration time of the SAML certificate that will be used after rollover + RolloverCertificateExpiresAt *time.Time `json:"rollover_certificate_expires_at,omitempty"` + + // RolloverCertificateFingerprint Fingerprint of the SAML certificate that will be used after rollover + RolloverCertificateFingerprint *string `json:"rollover_certificate_fingerprint,omitempty"` } // SAMLConfigUpdate defines model for SAMLConfigUpdate. @@ -2870,7 +3189,7 @@ type SyncIntegrationTestConnectionCreateV2 struct { Spec *map[string]interface{} `json:"spec,omitempty"` // Version Version of the plugin - Version string `json:"version"` + Version *string `json:"version,omitempty"` } // SyncIntegrationTestConnectionV2 defines model for SyncIntegrationTestConnectionV2. @@ -3459,8 +3778,8 @@ type TableDataAction struct { // Action The action to perform on the table data Action TableDataActionAction `json:"action"` - // Syncs Map of sync names to arrays of table names - Syncs map[string][]string `json:"syncs"` + // Sources Map of source names to arrays of table names + Sources map[string][]string `json:"sources"` } // TableDataActionAction The action to perform on the table data @@ -3468,14 +3787,14 @@ type TableDataActionAction string // TableDataListItem Sync with its associated tables type TableDataListItem struct { - // DisplayName Human-readable display name of the sync + // DisplayName Human-readable display name of the source DisplayName *string `json:"display_name,omitempty"` // Plugin Plugin path in CloudQuery registry Plugin *SyncPluginPath `json:"plugin,omitempty"` - // SyncName The unique name of the sync (source_name from synced_tables) - SyncName string `json:"sync_name"` + // SourceName The unique name of the source (source_name from synced_tables) + SourceName string `json:"source_name"` // Tables List of tables synced by this integration with their deletion status Tables []struct { @@ -3718,6 +4037,9 @@ type AlertMessageFilter = string // AlertStates defines model for alert_states. type AlertStates = []AlertState +// AssetID ID of the Resource +type AssetID = TableRowID + // ColumnName The name of a table column. type ColumnName = string @@ -3754,6 +4076,9 @@ type IncludeFips = bool // IncludePrereleases defines model for include_prereleases. type IncludePrereleases = bool +// InsightColumnName defines model for insight_column_name. +type InsightColumnName = string + // MigrationFilter Filter by migration type MigrationFilter = bool @@ -3778,6 +4103,9 @@ type PluginSortBy string // PluginTeam The unique name for the team. type PluginTeam = TeamName +// QueryColumnFilter defines model for query_column_filter. +type QueryColumnFilter = []string + // QueryFilter Filter by query type QueryFilter = string @@ -3895,6 +4223,9 @@ type VersionSortBy string // BadRequest defines model for BadRequest. type BadRequest = FieldError +// Conflict defines model for Conflict. +type Conflict = FieldError + // Forbidden defines model for Forbidden. type Forbidden = FieldError @@ -3991,6 +4322,18 @@ type ListAuditLogsParams struct { Search *string `form:"search,omitempty" json:"search,omitempty"` } +// DeleteSAMLRolloverCertificateJSONBody defines parameters for DeleteSAMLRolloverCertificate. +type DeleteSAMLRolloverCertificateJSONBody struct { + // Fingerprint The fingerprint of the rollover certificate to delete + Fingerprint string `json:"fingerprint"` +} + +// PromoteSAMLRolloverCertificateJSONBody defines parameters for PromoteSAMLRolloverCertificate. +type PromoteSAMLRolloverCertificateJSONBody struct { + // Fingerprint The fingerprint of the rollover certificate to promote + Fingerprint string `json:"fingerprint"` +} + // ListAllCustomColumnsParams defines parameters for ListAllCustomColumns. type ListAllCustomColumnsParams struct { // PerPage The number of results per page (max 1000). @@ -4032,6 +4375,180 @@ type ListFilterTagsParams struct { Page *Page `form:"page,omitempty" json:"page,omitempty"` } +// ListPlatformInsightsParams defines parameters for ListPlatformInsights. +type ListPlatformInsightsParams struct { + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Search Search in title, evidence (description), mitigation, or related fields + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // Severities Filter by severities (any match) + Severities *[]InsightSeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // Cloud Filter by cloud + Cloud *string `form:"cloud,omitempty" json:"cloud,omitempty"` + + // Account Filter by account + Account *string `form:"account,omitempty" json:"account,omitempty"` + + // Region Filter by region + Region *string `form:"region,omitempty" json:"region,omitempty"` + + // InsightCategory Filter by insight category + InsightCategory *string `form:"insight_category,omitempty" json:"insight_category,omitempty"` + + // SourceCategory Filter by source category + SourceCategory *string `form:"source_category,omitempty" json:"source_category,omitempty"` + + // Source Filter by source + Source *string `form:"source,omitempty" json:"source,omitempty"` + + // ResourceTypes Filter by resource types + ResourceTypes *[]string `form:"resource_types,omitempty" json:"resource_types,omitempty"` + + // Tags Filter by tags (any match) + Tags *[]string `form:"tags,omitempty" json:"tags,omitempty"` + + // SortBy Field to sort by + SortBy *ListPlatformInsightsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` + + // SortDir Sort direction + SortDir *ListPlatformInsightsParamsSortDir `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` +} + +// ListPlatformInsightsParamsSortBy defines parameters for ListPlatformInsights. +type ListPlatformInsightsParamsSortBy string + +// ListPlatformInsightsParamsSortDir defines parameters for ListPlatformInsights. +type ListPlatformInsightsParamsSortDir string + +// GetPlatformAssetInsightsParams defines parameters for GetPlatformAssetInsights. +type GetPlatformAssetInsightsParams struct { + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Search Search in asset name, account, region, etc. + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // SortBy Field to sort by + SortBy *GetPlatformAssetInsightsParamsSortBy `form:"sort_by,omitempty" json:"sort_by,omitempty"` + + // SortDir Sort direction + SortDir *GetPlatformAssetInsightsParamsSortDir `form:"sort_dir,omitempty" json:"sort_dir,omitempty"` +} + +// GetPlatformAssetInsightsParamsSortBy defines parameters for GetPlatformAssetInsights. +type GetPlatformAssetInsightsParamsSortBy string + +// GetPlatformAssetInsightsParamsSortDir defines parameters for GetPlatformAssetInsights. +type GetPlatformAssetInsightsParamsSortDir string + +// GetPlatformInsightColumnDistinctValuesParams defines parameters for GetPlatformInsightColumnDistinctValues. +type GetPlatformInsightColumnDistinctValuesParams struct { + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // OwnerTag When specified, returns distinct values for this ownership tag key (e.g., "team", "department"). The column_name parameter is ignored when owner_tag is provided. + OwnerTag *string `form:"owner_tag,omitempty" json:"owner_tag,omitempty"` + + // Search Search in title, evidence (description), mitigation, or related fields + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // Severities Filter by severities (any match) + Severities *[]InsightSeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // Cloud Filter by cloud + Cloud *string `form:"cloud,omitempty" json:"cloud,omitempty"` + + // Account Filter by account + Account *string `form:"account,omitempty" json:"account,omitempty"` + + // Region Filter by region + Region *string `form:"region,omitempty" json:"region,omitempty"` + + // InsightCategory Filter by insight category + InsightCategory *string `form:"insight_category,omitempty" json:"insight_category,omitempty"` + + // SourceCategory Filter by source category + SourceCategory *string `form:"source_category,omitempty" json:"source_category,omitempty"` + + // Source Filter by source + Source *string `form:"source,omitempty" json:"source,omitempty"` + + // ResourceTypes Filter by resource types + ResourceTypes *[]string `form:"resource_types,omitempty" json:"resource_types,omitempty"` + + // Tags Filter by tags (any match) + Tags *[]string `form:"tags,omitempty" json:"tags,omitempty"` +} + +// PlatformListInsightFiltersParams defines parameters for PlatformListInsightFilters. +type PlatformListInsightFiltersParams struct { + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // SearchTerm Search in filter name or description + SearchTerm *string `form:"search_term,omitempty" json:"search_term,omitempty"` + + // InsightCategory Filter by insight category + InsightCategory *[]string `form:"insight_category,omitempty" json:"insight_category,omitempty"` + + // Severities Filter by severities (any match) + Severities *[]InsightSeverity `form:"severities,omitempty" json:"severities,omitempty"` + + // ResourceTypes Filter by resource types + ResourceTypes *[]string `form:"resource_types,omitempty" json:"resource_types,omitempty"` + + // Source Filter by source + Source *[]string `form:"source,omitempty" json:"source,omitempty"` + + // SourceCategory Filter by source category + SourceCategory *[]string `form:"source_category,omitempty" json:"source_category,omitempty"` + + // Tags Filter by tags (any match) + Tags *[]string `form:"tags,omitempty" json:"tags,omitempty"` + + // GroupBy Filter by group by fields + GroupBy *[]string `form:"group_by,omitempty" json:"group_by,omitempty"` +} + +// GetPlatformInsightAssetsParams defines parameters for GetPlatformInsightAssets. +type GetPlatformInsightAssetsParams struct { + // Page Page number of the results to fetch + Page *Page `form:"page,omitempty" json:"page,omitempty"` + + // PerPage The number of results per page (max 1000). + PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"` + + // Search Search in asset name, account, region, etc. + Search *string `form:"search,omitempty" json:"search,omitempty"` + + // Accounts Filter by account IDs + Accounts *[]string `form:"accounts,omitempty" json:"accounts,omitempty"` + + // Clouds Filter by cloud providers (e.g. aws, azure, gcp, github, backstage, digitalocean, wiz) + Clouds *[]string `form:"clouds,omitempty" json:"clouds,omitempty"` + + // Regions Filter by regions + Regions *[]string `form:"regions,omitempty" json:"regions,omitempty"` + + // ResourceType Filter by resource type + ResourceType *[]string `form:"resource_type,omitempty" json:"resource_type,omitempty"` +} + // ListNotificationsParams defines parameters for ListNotifications. type ListNotificationsParams struct { // PerPage The number of results per page (max 1000). @@ -4288,6 +4805,9 @@ type ListAllQueriesParams struct { // AlertEnabled Alert enabled AlertEnabled *AlertEnabled `form:"alert_enabled,omitempty" json:"alert_enabled,omitempty"` + + // ColumnFilter Filter queries that return all specified columns + ColumnFilter *QueryColumnFilter `form:"column_filter,omitempty" json:"column_filter,omitempty"` } // ExecuteAdHocQueryJSONBody defines parameters for ExecuteAdHocQuery. @@ -4297,7 +4817,7 @@ type ExecuteAdHocQueryJSONBody struct { // ExecuteAdHocQueryParams defines parameters for ExecuteAdHocQuery. type ExecuteAdHocQueryParams struct { - // Selects Table selects. This filters the columns that are returned in the result set. + // Selects Table selects. This filters the columns that are returned in the result set. If empty, all default columns + internal _cq_* columns are returned. To select all columns, use the `*` wildcard. Selects Selects `form:"select,omitempty" json:"select,omitempty"` // FilterMode Table filter mode. @@ -4349,7 +4869,7 @@ type ListQueryTagsParams struct { // ExecuteSavedQueryParams defines parameters for ExecuteSavedQuery. type ExecuteSavedQueryParams struct { - // Selects Table selects. This filters the columns that are returned in the result set. + // Selects Table selects. This filters the columns that are returned in the result set. If empty, all default columns + internal _cq_* columns are returned. To select all columns, use the `*` wildcard. Selects Selects `form:"select,omitempty" json:"select,omitempty"` // FilterMode Table filter mode. @@ -4857,7 +5377,7 @@ type TableColumnListValuesParamsFilterMode string // TableListRowsParams defines parameters for TableListRows. type TableListRowsParams struct { - // Selects Table selects. This filters the columns that are returned in the result set. + // Selects Table selects. This filters the columns that are returned in the result set. If empty, all default columns + internal _cq_* columns are returned. To select all columns, use the `*` wildcard. Selects Selects `form:"select,omitempty" json:"select,omitempty"` // FilterMode Table filter mode. @@ -5192,6 +5712,12 @@ type CreateAPIKeyJSONRequestBody CreateAPIKeyJSONBody // UpdateSAMLJSONRequestBody defines body for UpdateSAML for application/json ContentType. type UpdateSAMLJSONRequestBody = SAMLConfigUpdate +// DeleteSAMLRolloverCertificateJSONRequestBody defines body for DeleteSAMLRolloverCertificate for application/json ContentType. +type DeleteSAMLRolloverCertificateJSONRequestBody DeleteSAMLRolloverCertificateJSONBody + +// PromoteSAMLRolloverCertificateJSONRequestBody defines body for PromoteSAMLRolloverCertificate for application/json ContentType. +type PromoteSAMLRolloverCertificateJSONRequestBody PromoteSAMLRolloverCertificateJSONBody + // CreateConversationJSONRequestBody defines body for CreateConversation for application/json ContentType. type CreateConversationJSONRequestBody = ConversationCreate @@ -5207,6 +5733,12 @@ type UpdateCustomColumnJSONRequestBody = CustomColumnCreateOrUpdate // UpdateFilterJSONRequestBody defines body for UpdateFilter for application/json ContentType. type UpdateFilterJSONRequestBody = FilterUpdate +// PlatformCreateInsightFilterJSONRequestBody defines body for PlatformCreateInsightFilter for application/json ContentType. +type PlatformCreateInsightFilterJSONRequestBody = PlatformInsightFilterCreate + +// PlatformUpdateInsightFilterJSONRequestBody defines body for PlatformUpdateInsightFilter for application/json ContentType. +type PlatformUpdateInsightFilterJSONRequestBody = PlatformInsightFilterUpdate + // UpdateNotificationDestinationJSONRequestBody defines body for UpdateNotificationDestination for application/json ContentType. type UpdateNotificationDestinationJSONRequestBody = NotificationDestinationUpdate @@ -5216,6 +5748,9 @@ type CreateNotificationDestinationJSONRequestBody = NotificationDestinationCreat // TestUnsavedNotificationDestinationJSONRequestBody defines body for TestUnsavedNotificationDestination for application/json ContentType. type TestUnsavedNotificationDestinationJSONRequestBody = NotificationDestinationData +// NotifyAWSCUROnboardingJSONRequestBody defines body for NotifyAWSCUROnboarding for application/json ContentType. +type NotifyAWSCUROnboardingJSONRequestBody = OnboardingAWSCURNotification + // CreateAWSOnboardingJSONRequestBody defines body for CreateAWSOnboarding for application/json ContentType. type CreateAWSOnboardingJSONRequestBody CreateAWSOnboardingJSONBody @@ -5384,6 +5919,155 @@ type CreateV2SyncIntegrationJSONRequestBody = SyncIntegrationCreateV2 // UpdateV2SyncIntegrationJSONRequestBody defines body for UpdateV2SyncIntegration for application/json ContentType. type UpdateV2SyncIntegrationJSONRequestBody = SyncIntegrationUpdateV2 +// AsStartedNotification returns the union data inside the OnboardingAWSCURNotification as a StartedNotification +func (t OnboardingAWSCURNotification) AsStartedNotification() (StartedNotification, error) { + var body StartedNotification + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromStartedNotification overwrites any union data inside the OnboardingAWSCURNotification as the provided StartedNotification +func (t *OnboardingAWSCURNotification) FromStartedNotification(v StartedNotification) error { + v.Status = "started" + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeStartedNotification performs a merge with any union data inside the OnboardingAWSCURNotification, using the provided StartedNotification +func (t *OnboardingAWSCURNotification) MergeStartedNotification(v StartedNotification) error { + v.Status = "started" + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsRevokedNotification returns the union data inside the OnboardingAWSCURNotification as a RevokedNotification +func (t OnboardingAWSCURNotification) AsRevokedNotification() (RevokedNotification, error) { + var body RevokedNotification + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromRevokedNotification overwrites any union data inside the OnboardingAWSCURNotification as the provided RevokedNotification +func (t *OnboardingAWSCURNotification) FromRevokedNotification(v RevokedNotification) error { + v.Status = "revoked" + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeRevokedNotification performs a merge with any union data inside the OnboardingAWSCURNotification, using the provided RevokedNotification +func (t *OnboardingAWSCURNotification) MergeRevokedNotification(v RevokedNotification) error { + v.Status = "revoked" + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsFailedNotification returns the union data inside the OnboardingAWSCURNotification as a FailedNotification +func (t OnboardingAWSCURNotification) AsFailedNotification() (FailedNotification, error) { + var body FailedNotification + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromFailedNotification overwrites any union data inside the OnboardingAWSCURNotification as the provided FailedNotification +func (t *OnboardingAWSCURNotification) FromFailedNotification(v FailedNotification) error { + v.Status = "failed" + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeFailedNotification performs a merge with any union data inside the OnboardingAWSCURNotification, using the provided FailedNotification +func (t *OnboardingAWSCURNotification) MergeFailedNotification(v FailedNotification) error { + v.Status = "failed" + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +// AsDeployedCURNotification returns the union data inside the OnboardingAWSCURNotification as a DeployedCURNotification +func (t OnboardingAWSCURNotification) AsDeployedCURNotification() (DeployedCURNotification, error) { + var body DeployedCURNotification + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromDeployedCURNotification overwrites any union data inside the OnboardingAWSCURNotification as the provided DeployedCURNotification +func (t *OnboardingAWSCURNotification) FromDeployedCURNotification(v DeployedCURNotification) error { + v.Status = "deployed_cur" + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeDeployedCURNotification performs a merge with any union data inside the OnboardingAWSCURNotification, using the provided DeployedCURNotification +func (t *OnboardingAWSCURNotification) MergeDeployedCURNotification(v DeployedCURNotification) error { + v.Status = "deployed_cur" + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JSONMerge(t.union, b) + t.union = merged + return err +} + +func (t OnboardingAWSCURNotification) Discriminator() (string, error) { + var discriminator struct { + Discriminator string `json:"status"` + } + err := json.Unmarshal(t.union, &discriminator) + return discriminator.Discriminator, err +} + +func (t OnboardingAWSCURNotification) ValueByDiscriminator() (interface{}, error) { + discriminator, err := t.Discriminator() + if err != nil { + return nil, err + } + switch discriminator { + case "deployed_cur": + return t.AsDeployedCURNotification() + case "failed": + return t.AsFailedNotification() + case "revoked": + return t.AsRevokedNotification() + case "started": + return t.AsStartedNotification() + default: + return nil, errors.New("unknown discriminator value: " + discriminator) + } +} + +func (t OnboardingAWSCURNotification) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OnboardingAWSCURNotification) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + // AsStartedNotification returns the union data inside the OnboardingAWSNotification as a StartedNotification func (t OnboardingAWSNotification) AsStartedNotification() (StartedNotification, error) { var body StartedNotification @@ -5705,6 +6389,19 @@ type ClientInterface interface { UpdateSAML(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // DeleteSAMLRolloverCertificateWithBody request with any body + DeleteSAMLRolloverCertificateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteSAMLRolloverCertificate(ctx context.Context, body DeleteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // CreateSAMLRolloverCertificate request + CreateSAMLRolloverCertificate(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PromoteSAMLRolloverCertificateWithBody request with any body + PromoteSAMLRolloverCertificateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PromoteSAMLRolloverCertificate(ctx context.Context, body PromoteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreateConversationWithBody request with any body CreateConversationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -5760,6 +6457,40 @@ type ClientInterface interface { // HealthCheckHead request HealthCheckHead(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListPlatformInsights request + ListPlatformInsights(ctx context.Context, params *ListPlatformInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPlatformAssetInsights request + GetPlatformAssetInsights(ctx context.Context, assetID AssetID, params *GetPlatformAssetInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPlatformInsightColumnDistinctValues request + GetPlatformInsightColumnDistinctValues(ctx context.Context, insightColumnName InsightColumnName, params *GetPlatformInsightColumnDistinctValuesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PlatformListInsightFilters request + PlatformListInsightFilters(ctx context.Context, params *PlatformListInsightFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PlatformCreateInsightFilterWithBody request with any body + PlatformCreateInsightFilterWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PlatformCreateInsightFilter(ctx context.Context, body PlatformCreateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PlatformDeleteInsightFilter request + PlatformDeleteInsightFilter(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PlatformGetInsightFilterByID request + PlatformGetInsightFilterByID(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PlatformUpdateInsightFilterWithBody request with any body + PlatformUpdateInsightFilterWithBody(ctx context.Context, insightFilterID InsightFilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PlatformUpdateInsightFilter(ctx context.Context, insightFilterID InsightFilterID, body PlatformUpdateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPlatformInsight request + GetPlatformInsight(ctx context.Context, insightID InsightID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetPlatformInsightAssets request + GetPlatformInsightAssets(ctx context.Context, insightID InsightID, params *GetPlatformInsightAssetsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + // ListNotifications request ListNotifications(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -5793,6 +6524,20 @@ type ClientInterface interface { TestUnsavedNotificationDestination(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreateAWSCUROnboarding request + CreateAWSCUROnboarding(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetAWSCUROnboarding request + GetAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) + + // NotifyAWSCUROnboardingWithBody request with any body + NotifyAWSCUROnboardingWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + NotifyAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, body NotifyAWSCUROnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // VerifyAWSCUROnboarding request + VerifyAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) + // CreateAWSOnboardingWithBody request with any body CreateAWSOnboardingWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -6219,6 +6964,9 @@ type ClientInterface interface { TablesDataAction(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + // GetTablesRelations request + GetTablesRelations(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + // BatchTableSchemas request BatchTableSchemas(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*http.Response, error) @@ -6554,6 +7302,66 @@ func (c *Client) UpdateSAML(ctx context.Context, body UpdateSAMLJSONRequestBody, return c.Client.Do(req) } +func (c *Client) DeleteSAMLRolloverCertificateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSAMLRolloverCertificateRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSAMLRolloverCertificate(ctx context.Context, body DeleteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSAMLRolloverCertificateRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) CreateSAMLRolloverCertificate(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateSAMLRolloverCertificateRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PromoteSAMLRolloverCertificateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSAMLRolloverCertificateRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PromoteSAMLRolloverCertificate(ctx context.Context, body PromoteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPromoteSAMLRolloverCertificateRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) CreateConversationWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewCreateConversationRequestWithBody(c.Server, contentType, body) if err != nil { @@ -6794,6 +7602,150 @@ func (c *Client) HealthCheckHead(ctx context.Context, reqEditors ...RequestEdito return c.Client.Do(req) } +func (c *Client) ListPlatformInsights(ctx context.Context, params *ListPlatformInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewListPlatformInsightsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetPlatformAssetInsights(ctx context.Context, assetID AssetID, params *GetPlatformAssetInsightsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPlatformAssetInsightsRequest(c.Server, assetID, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetPlatformInsightColumnDistinctValues(ctx context.Context, insightColumnName InsightColumnName, params *GetPlatformInsightColumnDistinctValuesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPlatformInsightColumnDistinctValuesRequest(c.Server, insightColumnName, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformListInsightFilters(ctx context.Context, params *PlatformListInsightFiltersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformListInsightFiltersRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformCreateInsightFilterWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformCreateInsightFilterRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformCreateInsightFilter(ctx context.Context, body PlatformCreateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformCreateInsightFilterRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformDeleteInsightFilter(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformDeleteInsightFilterRequest(c.Server, insightFilterID) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformGetInsightFilterByID(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformGetInsightFilterByIDRequest(c.Server, insightFilterID) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformUpdateInsightFilterWithBody(ctx context.Context, insightFilterID InsightFilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformUpdateInsightFilterRequestWithBody(c.Server, insightFilterID, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PlatformUpdateInsightFilter(ctx context.Context, insightFilterID InsightFilterID, body PlatformUpdateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPlatformUpdateInsightFilterRequest(c.Server, insightFilterID, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetPlatformInsight(ctx context.Context, insightID InsightID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPlatformInsightRequest(c.Server, insightID) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetPlatformInsightAssets(ctx context.Context, insightID InsightID, params *GetPlatformInsightAssetsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetPlatformInsightAssetsRequest(c.Server, insightID, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) ListNotifications(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewListNotificationsRequest(c.Server, params) if err != nil { @@ -6938,6 +7890,66 @@ func (c *Client) TestUnsavedNotificationDestination(ctx context.Context, body Te return c.Client.Do(req) } +func (c *Client) CreateAWSCUROnboarding(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewCreateAWSCUROnboardingRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetAWSCUROnboardingRequest(c.Server, onboardingID) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) NotifyAWSCUROnboardingWithBody(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewNotifyAWSCUROnboardingRequestWithBody(c.Server, onboardingID, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) NotifyAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, body NotifyAWSCUROnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewNotifyAWSCUROnboardingRequest(c.Server, onboardingID, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) VerifyAWSCUROnboarding(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewVerifyAWSCUROnboardingRequest(c.Server, onboardingID) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) CreateAWSOnboardingWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewCreateAWSOnboardingRequestWithBody(c.Server, contentType, body) if err != nil { @@ -8786,6 +9798,18 @@ func (c *Client) TablesDataAction(ctx context.Context, body TablesDataActionJSON return c.Client.Do(req) } +func (c *Client) GetTablesRelations(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTablesRelationsRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + func (c *Client) BatchTableSchemas(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*http.Response, error) { req, err := NewBatchTableSchemasRequest(c.Server, params) if err != nil { @@ -10197,19 +11221,19 @@ func NewUpdateSAMLRequestWithBody(server string, contentType string, body io.Rea return req, nil } -// NewCreateConversationRequest calls the generic CreateConversation builder with application/json body -func NewCreateConversationRequest(server string, body CreateConversationJSONRequestBody) (*http.Request, error) { +// NewDeleteSAMLRolloverCertificateRequest calls the generic DeleteSAMLRolloverCertificate builder with application/json body +func NewDeleteSAMLRolloverCertificateRequest(server string, body DeleteSAMLRolloverCertificateJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateConversationRequestWithBody(server, "application/json", bodyReader) + return NewDeleteSAMLRolloverCertificateRequestWithBody(server, "application/json", bodyReader) } -// NewCreateConversationRequestWithBody generates requests for CreateConversation with any type of body -func NewCreateConversationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewDeleteSAMLRolloverCertificateRequestWithBody generates requests for DeleteSAMLRolloverCertificate with any type of body +func NewDeleteSAMLRolloverCertificateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -10217,7 +11241,7 @@ func NewCreateConversationRequestWithBody(server string, contentType string, bod return nil, err } - operationPath := fmt.Sprintf("/conversations") + operationPath := fmt.Sprintf("/auth/saml/rollover") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -10227,7 +11251,7 @@ func NewCreateConversationRequestWithBody(server string, contentType string, bod return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), body) if err != nil { return nil, err } @@ -10237,23 +11261,54 @@ func NewCreateConversationRequestWithBody(server string, contentType string, bod return req, nil } -// NewGetConversationRequest generates requests for GetConversation -func NewGetConversationRequest(server string, conversationID ConversationID) (*http.Request, error) { +// NewCreateSAMLRolloverCertificateRequest generates requests for CreateSAMLRolloverCertificate +func NewCreateSAMLRolloverCertificateRequest(server string) (*http.Request, error) { var err error - var pathParam0 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + operationPath := fmt.Sprintf("/auth/saml/rollover") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PUT", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewPromoteSAMLRolloverCertificateRequest calls the generic PromoteSAMLRolloverCertificate builder with application/json body +func NewPromoteSAMLRolloverCertificateRequest(server string, body PromoteSAMLRolloverCertificateJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPromoteSAMLRolloverCertificateRequestWithBody(server, "application/json", bodyReader) +} + +// NewPromoteSAMLRolloverCertificateRequestWithBody generates requests for PromoteSAMLRolloverCertificate with any type of body +func NewPromoteSAMLRolloverCertificateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/conversations/%s", pathParam0) + operationPath := fmt.Sprintf("/auth/saml/rollover/promote") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -10263,27 +11318,103 @@ func NewGetConversationRequest(server string, conversationID ConversationID) (*h return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewSendMessageRequest calls the generic SendMessage builder with application/json body -func NewSendMessageRequest(server string, conversationID ConversationID, body SendMessageJSONRequestBody) (*http.Request, error) { +// NewCreateConversationRequest calls the generic CreateConversation builder with application/json body +func NewCreateConversationRequest(server string, body CreateConversationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewSendMessageRequestWithBody(server, conversationID, "application/json", bodyReader) + return NewCreateConversationRequestWithBody(server, "application/json", bodyReader) } -// NewSendMessageRequestWithBody generates requests for SendMessage with any type of body -func NewSendMessageRequestWithBody(server string, conversationID ConversationID, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateConversationRequestWithBody generates requests for CreateConversation with any type of body +func NewCreateConversationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/conversations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetConversationRequest generates requests for GetConversation +func NewGetConversationRequest(server string, conversationID ConversationID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "conversation_id", runtime.ParamLocationPath, conversationID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/conversations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewSendMessageRequest calls the generic SendMessage builder with application/json body +func NewSendMessageRequest(server string, conversationID ConversationID, body SendMessageJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewSendMessageRequestWithBody(server, conversationID, "application/json", bodyReader) +} + +// NewSendMessageRequestWithBody generates requests for SendMessage with any type of body +func NewSendMessageRequestWithBody(server string, conversationID ConversationID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string @@ -10933,8 +12064,8 @@ func NewHealthCheckHeadRequest(server string) (*http.Request, error) { return req, nil } -// NewListNotificationsRequest generates requests for ListNotifications -func NewListNotificationsRequest(server string, params *ListNotificationsParams) (*http.Request, error) { +// NewListPlatformInsightsRequest generates requests for ListPlatformInsights +func NewListPlatformInsightsRequest(server string, params *ListPlatformInsightsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -10942,7 +12073,7 @@ func NewListNotificationsRequest(server string, params *ListNotificationsParams) return nil, err } - operationPath := fmt.Sprintf("/notifications") + operationPath := fmt.Sprintf("/insights") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -10955,6 +12086,22 @@ func NewListNotificationsRequest(server string, params *ListNotificationsParams) if params != nil { queryValues := queryURL.Query() + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -10971,9 +12118,9 @@ func NewListNotificationsRequest(server string, params *ListNotificationsParams) } - if params.Page != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11003,9 +12150,9 @@ func NewListNotificationsRequest(server string, params *ListNotificationsParams) } - if params.PolicyGroupIds != nil { + if params.Cloud != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "cloud", runtime.ParamLocationQuery, *params.Cloud); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11019,164 +12166,121 @@ func NewListNotificationsRequest(server string, params *ListNotificationsParams) } - queryURL.RawQuery = queryValues.Encode() - } + if params.Account != nil { - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewDeleteNotificationDestinationRequest generates requests for DeleteNotificationDestination -func NewDeleteNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetNotificationDestinationRequest generates requests for GetNotificationDestination -func NewGetNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "account", runtime.ParamLocationQuery, *params.Account); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + } - return req, nil -} + if params.Region != nil { -// NewUpdateNotificationDestinationRequest calls the generic UpdateNotificationDestination builder with application/json body -func NewUpdateNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateNotificationDestinationRequestWithBody(server, notificationDestinationId, "application/json", bodyReader) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "region", runtime.ParamLocationQuery, *params.Region); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUpdateNotificationDestinationRequestWithBody generates requests for UpdateNotificationDestination with any type of body -func NewUpdateNotificationDestinationRequestWithBody(server string, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.InsightCategory != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "insight_category", runtime.ParamLocationQuery, *params.InsightCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.SourceCategory != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source_category", runtime.ParamLocationQuery, *params.SourceCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + } - req.Header.Add("Content-Type", contentType) + if params.Source != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source", runtime.ParamLocationQuery, *params.Source); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewGetNotificationDestinationAlertsRequest generates requests for GetNotificationDestinationAlerts -func NewGetNotificationDestinationAlertsRequest(server string, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.ResourceTypes != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "resource_types", runtime.ParamLocationQuery, params.ResourceTypes); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/notifications/destination/%s/alerts", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.Tags != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tags", runtime.ParamLocationQuery, params.Tags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.PerPage != nil { + if params.SortBy != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11190,9 +12294,9 @@ func NewGetNotificationDestinationAlertsRequest(server string, notificationDesti } - if params.Page != nil { + if params.SortDir != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11217,13 +12321,13 @@ func NewGetNotificationDestinationAlertsRequest(server string, notificationDesti return req, nil } -// NewTestNotificationDestinationRequest generates requests for TestNotificationDestination -func NewTestNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { +// NewGetPlatformAssetInsightsRequest generates requests for GetPlatformAssetInsights +func NewGetPlatformAssetInsightsRequest(server string, assetID AssetID, params *GetPlatformAssetInsightsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "asset_id", runtime.ParamLocationPath, assetID) if err != nil { return nil, err } @@ -11233,7 +12337,7 @@ func NewTestNotificationDestinationRequest(server string, notificationDestinatio return nil, err } - operationPath := fmt.Sprintf("/notifications/destination/%s/test", pathParam0) + operationPath := fmt.Sprintf("/insights/assets/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11243,7 +12347,93 @@ func NewTestNotificationDestinationRequest(server string, notificationDestinatio return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortBy != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDir != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -11251,16 +12441,23 @@ func NewTestNotificationDestinationRequest(server string, notificationDestinatio return req, nil } -// NewListAllNotificationDestinationsRequest generates requests for ListAllNotificationDestinations -func NewListAllNotificationDestinationsRequest(server string, params *ListAllNotificationDestinationsParams) (*http.Request, error) { +// NewGetPlatformInsightColumnDistinctValuesRequest generates requests for GetPlatformInsightColumnDistinctValues +func NewGetPlatformInsightColumnDistinctValuesRequest(server string, insightColumnName InsightColumnName, params *GetPlatformInsightColumnDistinctValuesParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "column_name", runtime.ParamLocationPath, insightColumnName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/notifications/destinations") + operationPath := fmt.Sprintf("/insights/columns/%s/distinct-values", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11273,6 +12470,22 @@ func NewListAllNotificationDestinationsRequest(server string, params *ListAllNot if params != nil { queryValues := queryURL.Query() + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -11289,9 +12502,169 @@ func NewListAllNotificationDestinationsRequest(server string, params *ListAllNot } - if params.Page != nil { + if params.OwnerTag != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "owner_tag", runtime.ParamLocationQuery, *params.OwnerTag); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Search != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Severities != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Cloud != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "cloud", runtime.ParamLocationQuery, *params.Cloud); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Account != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "account", runtime.ParamLocationQuery, *params.Account); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Region != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "region", runtime.ParamLocationQuery, *params.Region); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.InsightCategory != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "insight_category", runtime.ParamLocationQuery, *params.InsightCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SourceCategory != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source_category", runtime.ParamLocationQuery, *params.SourceCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Source != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source", runtime.ParamLocationQuery, *params.Source); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ResourceTypes != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "resource_types", runtime.ParamLocationQuery, params.ResourceTypes); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Tags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tags", runtime.ParamLocationQuery, params.Tags); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11316,19 +12689,8 @@ func NewListAllNotificationDestinationsRequest(server string, params *ListAllNot return req, nil } -// NewCreateNotificationDestinationRequest calls the generic CreateNotificationDestination builder with application/json body -func NewCreateNotificationDestinationRequest(server string, body CreateNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateNotificationDestinationRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateNotificationDestinationRequestWithBody generates requests for CreateNotificationDestination with any type of body -func NewCreateNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewPlatformListInsightFiltersRequest generates requests for PlatformListInsightFilters +func NewPlatformListInsightFiltersRequest(server string, params *PlatformListInsightFiltersParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -11336,7 +12698,7 @@ func NewCreateNotificationDestinationRequestWithBody(server string, contentType return nil, err } - operationPath := fmt.Sprintf("/notifications/destinations") + operationPath := fmt.Sprintf("/insights/saved-filters") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11346,69 +12708,193 @@ func NewCreateNotificationDestinationRequestWithBody(server string, contentType return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.PerPage != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewTestUnsavedNotificationDestinationRequest calls the generic TestUnsavedNotificationDestination builder with application/json body -func NewTestUnsavedNotificationDestinationRequest(server string, body TestUnsavedNotificationDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewTestUnsavedNotificationDestinationRequestWithBody(server, "application/json", bodyReader) -} + } -// NewTestUnsavedNotificationDestinationRequestWithBody generates requests for TestUnsavedNotificationDestination with any type of body -func NewTestUnsavedNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error + if params.Page != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/notifications/destinations/test") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + if params.SearchTerm != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.InsightCategory != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "insight_category", runtime.ParamLocationQuery, params.InsightCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Severities != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ResourceTypes != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "resource_types", runtime.ParamLocationQuery, params.ResourceTypes); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Source != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source", runtime.ParamLocationQuery, params.Source); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SourceCategory != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "source_category", runtime.ParamLocationQuery, params.SourceCategory); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Tags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tags", runtime.ParamLocationQuery, params.Tags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.GroupBy != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBy); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewCreateAWSOnboardingRequest calls the generic CreateAWSOnboarding builder with application/json body -func NewCreateAWSOnboardingRequest(server string, body CreateAWSOnboardingJSONRequestBody) (*http.Request, error) { +// NewPlatformCreateInsightFilterRequest calls the generic PlatformCreateInsightFilter builder with application/json body +func NewPlatformCreateInsightFilterRequest(server string, body PlatformCreateInsightFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateAWSOnboardingRequestWithBody(server, "application/json", bodyReader) + return NewPlatformCreateInsightFilterRequestWithBody(server, "application/json", bodyReader) } -// NewCreateAWSOnboardingRequestWithBody generates requests for CreateAWSOnboarding with any type of body -func NewCreateAWSOnboardingRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewPlatformCreateInsightFilterRequestWithBody generates requests for PlatformCreateInsightFilter with any type of body +func NewPlatformCreateInsightFilterRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -11416,7 +12902,7 @@ func NewCreateAWSOnboardingRequestWithBody(server string, contentType string, bo return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc") + operationPath := fmt.Sprintf("/insights/saved-filters") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11436,13 +12922,13 @@ func NewCreateAWSOnboardingRequestWithBody(server string, contentType string, bo return req, nil } -// NewGetAWSOnboardingRequest generates requests for GetAWSOnboarding -func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http.Request, error) { +// NewPlatformDeleteInsightFilterRequest generates requests for PlatformDeleteInsightFilter +func NewPlatformDeleteInsightFilterRequest(server string, insightFilterID InsightFilterID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "insight_filter_id", runtime.ParamLocationPath, insightFilterID) if err != nil { return nil, err } @@ -11452,7 +12938,7 @@ func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s", pathParam0) + operationPath := fmt.Sprintf("/insights/saved-filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11462,7 +12948,7 @@ func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -11470,13 +12956,13 @@ func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http return req, nil } -// NewGetAWSAccountsInRootRequest generates requests for GetAWSAccountsInRoot -func NewGetAWSAccountsInRootRequest(server string, onboardingID OnboardingID) (*http.Request, error) { +// NewPlatformGetInsightFilterByIDRequest generates requests for PlatformGetInsightFilterByID +func NewPlatformGetInsightFilterByIDRequest(server string, insightFilterID InsightFilterID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "insight_filter_id", runtime.ParamLocationPath, insightFilterID) if err != nil { return nil, err } @@ -11486,7 +12972,7 @@ func NewGetAWSAccountsInRootRequest(server string, onboardingID OnboardingID) (* return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts", pathParam0) + operationPath := fmt.Sprintf("/insights/saved-filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11504,24 +12990,24 @@ func NewGetAWSAccountsInRootRequest(server string, onboardingID OnboardingID) (* return req, nil } -// NewProvisionOnboardingConfigurationRequest calls the generic ProvisionOnboardingConfiguration builder with application/json body -func NewProvisionOnboardingConfigurationRequest(server string, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody) (*http.Request, error) { +// NewPlatformUpdateInsightFilterRequest calls the generic PlatformUpdateInsightFilter builder with application/json body +func NewPlatformUpdateInsightFilterRequest(server string, insightFilterID InsightFilterID, body PlatformUpdateInsightFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewProvisionOnboardingConfigurationRequestWithBody(server, onboardingID, "application/json", bodyReader) + return NewPlatformUpdateInsightFilterRequestWithBody(server, insightFilterID, "application/json", bodyReader) } -// NewProvisionOnboardingConfigurationRequestWithBody generates requests for ProvisionOnboardingConfiguration with any type of body -func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { +// NewPlatformUpdateInsightFilterRequestWithBody generates requests for PlatformUpdateInsightFilter with any type of body +func NewPlatformUpdateInsightFilterRequestWithBody(server string, insightFilterID InsightFilterID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "insight_filter_id", runtime.ParamLocationPath, insightFilterID) if err != nil { return nil, err } @@ -11531,7 +13017,7 @@ func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardin return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/provision", pathParam0) + operationPath := fmt.Sprintf("/insights/saved-filters/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11541,7 +13027,7 @@ func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardin return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -11551,20 +13037,13 @@ func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardin return req, nil } -// NewGetAWSAccountsInParentRequest generates requests for GetAWSAccountsInParent -func NewGetAWSAccountsInParentRequest(server string, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID) (*http.Request, error) { +// NewGetPlatformInsightRequest generates requests for GetPlatformInsight +func NewGetPlatformInsightRequest(server string, insightID InsightID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "aws_orgunit_id", runtime.ParamLocationPath, organizationalUnitID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "insight_id", runtime.ParamLocationPath, insightID) if err != nil { return nil, err } @@ -11574,7 +13053,7 @@ func NewGetAWSAccountsInParentRequest(server string, onboardingID OnboardingID, return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/insights/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11592,24 +13071,13 @@ func NewGetAWSAccountsInParentRequest(server string, onboardingID OnboardingID, return req, nil } -// NewNotifyOnboardingRequest calls the generic NotifyOnboarding builder with application/json body -func NewNotifyOnboardingRequest(server string, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewNotifyOnboardingRequestWithBody(server, onboardingID, "application/json", bodyReader) -} - -// NewNotifyOnboardingRequestWithBody generates requests for NotifyOnboarding with any type of body -func NewNotifyOnboardingRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetPlatformInsightAssetsRequest generates requests for GetPlatformInsightAssets +func NewGetPlatformInsightAssetsRequest(server string, insightID InsightID, params *GetPlatformInsightAssetsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "insight_id", runtime.ParamLocationPath, insightID) if err != nil { return nil, err } @@ -11619,90 +13087,7 @@ func NewNotifyOnboardingRequestWithBody(server string, onboardingID OnboardingID return nil, err } - operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/notify", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewGetOpenAPIJSONRequest generates requests for GetOpenAPIJSON -func NewGetOpenAPIJSONRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/openapi.json") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetPlatformInfoRequest generates requests for GetPlatformInfo -func NewGetPlatformInfoRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/platform-info") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListPlatformVersionsRequest generates requests for ListPlatformVersions -func NewListPlatformVersionsRequest(server string, params *ListPlatformVersionsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/platform-versions") + operationPath := fmt.Sprintf("/insights/%s/assets", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11747,42 +13132,9 @@ func NewListPlatformVersionsRequest(server string, params *ListPlatformVersionsP } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListPluginsRequest generates requests for ListPlugins -func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.SortBy != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11796,9 +13148,9 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ } - if params.Page != nil { + if params.Accounts != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "accounts", runtime.ParamLocationQuery, params.Accounts); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11812,9 +13164,9 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ } - if params.PerPage != nil { + if params.Clouds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "clouds", runtime.ParamLocationQuery, params.Clouds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11828,9 +13180,9 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ } - if params.IncludeReleaseStages != nil { + if params.Regions != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_release_stages", runtime.ParamLocationQuery, params.IncludeReleaseStages); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "regions", runtime.ParamLocationQuery, params.Regions); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11844,9 +13196,9 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ } - if params.ExcludeReleaseStages != nil { + if params.ResourceType != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "exclude_release_stages", runtime.ParamLocationQuery, params.ExcludeReleaseStages); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "resource_type", runtime.ParamLocationQuery, params.ResourceType); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -11871,85 +13223,16 @@ func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Requ return req, nil } -// NewGetPluginRequest generates requests for GetPlugin -func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/plugins/%s/%s/%s", pathParam0, pathParam1, pathParam2) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewListPluginVersionsRequest generates requests for ListPluginVersions -func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams) (*http.Request, error) { +// NewListNotificationsRequest generates requests for ListNotifications +func NewListNotificationsRequest(server string, params *ListNotificationsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/notifications") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -11962,38 +13245,6 @@ func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind P if params != nil { queryValues := queryURL.Query() - if params.SortBy != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -12010,25 +13261,9 @@ func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind P } - if params.IncludeDrafts != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_drafts", runtime.ParamLocationQuery, *params.IncludeDrafts); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.IncludeFips != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_fips", runtime.ParamLocationQuery, *params.IncludeFips); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12042,9 +13277,9 @@ func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind P } - if params.IncludePrereleases != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_prereleases", runtime.ParamLocationQuery, *params.IncludePrereleases); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12058,9 +13293,9 @@ func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind P } - if params.VersionFilter != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "version_filter", runtime.ParamLocationQuery, *params.VersionFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12085,34 +13320,47 @@ func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind P return req, nil } -// NewGetPluginVersionRequest generates requests for GetPluginVersion -func NewGetPluginVersionRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName) (*http.Request, error) { +// NewDeleteNotificationDestinationRequest generates requests for DeleteNotificationDestination +func NewDeleteNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam2 string + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam3 string + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + return req, nil +} + +// NewGetNotificationDestinationRequest generates requests for GetNotificationDestination +func NewGetNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } @@ -12122,7 +13370,7 @@ func NewGetPluginVersionRequest(server string, teamName TeamName, pluginKind Plu return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12140,41 +13388,60 @@ func NewGetPluginVersionRequest(server string, teamName TeamName, pluginKind Plu return req, nil } -// NewDownloadPluginAssetRequest generates requests for DownloadPluginAsset -func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams) (*http.Request, error) { +// NewUpdateNotificationDestinationRequest calls the generic UpdateNotificationDestination builder with application/json body +func NewUpdateNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateNotificationDestinationRequestWithBody(server, notificationDestinationId, "application/json", bodyReader) +} + +// NewUpdateNotificationDestinationRequestWithBody generates requests for UpdateNotificationDestination with any type of body +func NewUpdateNotificationDestinationRequestWithBody(server string, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam2 string + operationPath := fmt.Sprintf("/notifications/destination/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } - var pathParam4 string + req.Header.Add("Content-Type", contentType) - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) + return req, nil +} + +// NewGetNotificationDestinationAlertsRequest generates requests for GetNotificationDestinationAlerts +func NewGetNotificationDestinationAlertsRequest(server string, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } @@ -12184,7 +13451,7 @@ func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) + operationPath := fmt.Sprintf("/notifications/destination/%s/alerts", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12194,67 +13461,96 @@ func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - if params != nil { + queryValues := queryURL.Query() - if params.Accept != nil { - var headerParam0 string + if params.PerPage != nil { - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } } - req.Header.Set("Accept", headerParam0) } + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err } return req, nil } -// NewListPluginVersionTablesRequest generates requests for ListPluginVersionTables -func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams) (*http.Request, error) { +// NewTestNotificationDestinationRequest generates requests for TestNotificationDestination +func NewTestNotificationDestinationRequest(server string, notificationDestinationId NotificationDestinationId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "notification_destination_id", runtime.ParamLocationPath, notificationDestinationId) if err != nil { return nil, err } - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam2 string + operationPath := fmt.Sprintf("/notifications/destination/%s/test", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewListAllNotificationDestinationsRequest generates requests for ListAllNotificationDestinations +func NewListAllNotificationDestinationsRequest(server string, params *ListAllNotificationDestinationsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) + operationPath := fmt.Sprintf("/notifications/destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12267,9 +13563,9 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK if params != nil { queryValues := queryURL.Query() - if params.Page != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12283,9 +13579,9 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK } - if params.PerPage != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -12310,51 +13606,67 @@ func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginK return req, nil } -// NewGetPluginVersionTableRequest generates requests for GetPluginVersionTable -func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) +// NewCreateNotificationDestinationRequest calls the generic CreateNotificationDestination builder with application/json body +func NewCreateNotificationDestinationRequest(server string, body CreateNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateNotificationDestinationRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string +// NewCreateNotificationDestinationRequestWithBody generates requests for CreateNotificationDestination with any type of body +func NewCreateNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam2 string + operationPath := fmt.Sprintf("/notifications/destinations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam3 string - - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } - var pathParam4 string + req.Header.Add("Content-Type", contentType) - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + return req, nil +} + +// NewTestUnsavedNotificationDestinationRequest calls the generic TestUnsavedNotificationDestination builder with application/json body +func NewTestUnsavedNotificationDestinationRequest(server string, body TestUnsavedNotificationDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewTestUnsavedNotificationDestinationRequestWithBody(server, "application/json", bodyReader) +} + +// NewTestUnsavedNotificationDestinationRequestWithBody generates requests for TestUnsavedNotificationDestination with any type of body +func NewTestUnsavedNotificationDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) + operationPath := fmt.Sprintf("/notifications/destinations/test") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12364,16 +13676,18 @@ func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKin return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListPoliciesRequest generates requests for ListPolicies -func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Request, error) { +// NewCreateAWSCUROnboardingRequest generates requests for CreateAWSCUROnboarding +func NewCreateAWSCUROnboardingRequest(server string) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12381,7 +13695,7 @@ func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Re return nil, err } - operationPath := fmt.Sprintf("/policies") + operationPath := fmt.Sprintf("/onboardings/aws/cur") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12391,154 +13705,38 @@ func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Re return nil, err } - if params != nil { - queryValues := queryURL.Query() + req, err := http.NewRequest("POST", queryURL.String(), nil) + if err != nil { + return nil, err + } - if params.PerPage != nil { + return req, nil +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// NewGetAWSCUROnboardingRequest generates requests for GetAWSCUROnboarding +func NewGetAWSCUROnboardingRequest(server string, onboardingID OnboardingID) (*http.Request, error) { + var err error - } + var pathParam0 string - if params.Page != nil { + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PolicyStatus != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "status", runtime.ParamLocationQuery, *params.PolicyStatus); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Severities != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Domain != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PolicyGroupIds != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Search != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortBy != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortDir != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - } + operationPath := fmt.Sprintf("/onboardings/aws/cur/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - queryURL.RawQuery = queryValues.Encode() + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -12549,27 +13747,34 @@ func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Re return req, nil } -// NewCreatePolicyRequest calls the generic CreatePolicy builder with application/json body -func NewCreatePolicyRequest(server string, body CreatePolicyJSONRequestBody) (*http.Request, error) { +// NewNotifyAWSCUROnboardingRequest calls the generic NotifyAWSCUROnboarding builder with application/json body +func NewNotifyAWSCUROnboardingRequest(server string, onboardingID OnboardingID, body NotifyAWSCUROnboardingJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreatePolicyRequestWithBody(server, "application/json", bodyReader) + return NewNotifyAWSCUROnboardingRequestWithBody(server, onboardingID, "application/json", bodyReader) } -// NewCreatePolicyRequestWithBody generates requests for CreatePolicy with any type of body -func NewCreatePolicyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewNotifyAWSCUROnboardingRequestWithBody generates requests for NotifyAWSCUROnboarding with any type of body +func NewNotifyAWSCUROnboardingRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies") + operationPath := fmt.Sprintf("/onboardings/aws/cur/%s/notify", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12589,16 +13794,23 @@ func NewCreatePolicyRequestWithBody(server string, contentType string, body io.R return req, nil } -// NewGetPolicyMetricsRequest generates requests for GetPolicyMetrics -func NewGetPolicyMetricsRequest(server string, params *GetPolicyMetricsParams) (*http.Request, error) { +// NewVerifyAWSCUROnboardingRequest generates requests for VerifyAWSCUROnboarding +func NewVerifyAWSCUROnboardingRequest(server string, onboardingID OnboardingID) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies/metrics") + operationPath := fmt.Sprintf("/onboardings/aws/cur/%s/verify", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12608,61 +13820,7 @@ func NewGetPolicyMetricsRequest(server string, params *GetPolicyMetricsParams) ( return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.Severities != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Domain != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PolicyGroupIds != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -12670,8 +13828,19 @@ func NewGetPolicyMetricsRequest(server string, params *GetPolicyMetricsParams) ( return req, nil } -// NewGetViolationsByDomainRequest generates requests for GetViolationsByDomain -func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomainParams) (*http.Request, error) { +// NewCreateAWSOnboardingRequest calls the generic CreateAWSOnboarding builder with application/json body +func NewCreateAWSOnboardingRequest(server string, body CreateAWSOnboardingJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateAWSOnboardingRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateAWSOnboardingRequestWithBody generates requests for CreateAWSOnboarding with any type of body +func NewCreateAWSOnboardingRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -12679,7 +13848,7 @@ func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomai return nil, err } - operationPath := fmt.Sprintf("/policies/violations-by-domain") + operationPath := fmt.Sprintf("/onboardings/aws/oidc") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12689,58 +13858,40 @@ func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomai return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.Severities != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - } + req.Header.Add("Content-Type", contentType) - if params.Domain != nil { + return req, nil +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// NewGetAWSOnboardingRequest generates requests for GetAWSOnboarding +func NewGetAWSOnboardingRequest(server string, onboardingID OnboardingID) (*http.Request, error) { + var err error - } + var pathParam0 string - if params.PolicyGroupIds != nil { + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - } + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - queryURL.RawQuery = queryValues.Encode() + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -12751,16 +13902,23 @@ func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomai return req, nil } -// NewGetViolationsHistoryRequest generates requests for GetViolationsHistory -func NewGetViolationsHistoryRequest(server string, params *GetViolationsHistoryParams) (*http.Request, error) { +// NewGetAWSAccountsInRootRequest generates requests for GetAWSAccountsInRoot +func NewGetAWSAccountsInRootRequest(server string, onboardingID OnboardingID) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies/violations-history") + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12770,92 +13928,6 @@ func NewGetViolationsHistoryRequest(server string, params *GetViolationsHistoryP return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.StartDate != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_date", runtime.ParamLocationQuery, *params.StartDate); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.EndDate != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_date", runtime.ParamLocationQuery, *params.EndDate); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Severities != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Domain != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.PolicyGroupIds != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -12864,13 +13936,24 @@ func NewGetViolationsHistoryRequest(server string, params *GetViolationsHistoryP return req, nil } -// NewDeletePolicyRequest generates requests for DeletePolicy -func NewDeletePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { +// NewProvisionOnboardingConfigurationRequest calls the generic ProvisionOnboardingConfiguration builder with application/json body +func NewProvisionOnboardingConfigurationRequest(server string, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewProvisionOnboardingConfigurationRequestWithBody(server, onboardingID, "application/json", bodyReader) +} + +// NewProvisionOnboardingConfigurationRequestWithBody generates requests for ProvisionOnboardingConfiguration with any type of body +func NewProvisionOnboardingConfigurationRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12880,7 +13963,7 @@ func NewDeletePolicyRequest(server string, policyID PolicyID) (*http.Request, er return nil, err } - operationPath := fmt.Sprintf("/policies/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/provision", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12890,21 +13973,30 @@ func NewDeletePolicyRequest(server string, policyID PolicyID) (*http.Request, er return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetPolicyRequest generates requests for GetPolicy -func NewGetPolicyRequest(server string, policyID PolicyID) (*http.Request, error) { +// NewGetAWSAccountsInParentRequest generates requests for GetAWSAccountsInParent +func NewGetAWSAccountsInParentRequest(server string, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "aws_orgunit_id", runtime.ParamLocationPath, organizationalUnitID) if err != nil { return nil, err } @@ -12914,7 +14006,7 @@ func NewGetPolicyRequest(server string, policyID PolicyID) (*http.Request, error return nil, err } - operationPath := fmt.Sprintf("/policies/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/accounts/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12932,24 +14024,24 @@ func NewGetPolicyRequest(server string, policyID PolicyID) (*http.Request, error return req, nil } -// NewUpdatePolicyRequest calls the generic UpdatePolicy builder with application/json body -func NewUpdatePolicyRequest(server string, policyID PolicyID, body UpdatePolicyJSONRequestBody) (*http.Request, error) { +// NewNotifyOnboardingRequest calls the generic NotifyOnboarding builder with application/json body +func NewNotifyOnboardingRequest(server string, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdatePolicyRequestWithBody(server, policyID, "application/json", bodyReader) + return NewNotifyOnboardingRequestWithBody(server, onboardingID, "application/json", bodyReader) } -// NewUpdatePolicyRequestWithBody generates requests for UpdatePolicy with any type of body -func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentType string, body io.Reader) (*http.Request, error) { +// NewNotifyOnboardingRequestWithBody generates requests for NotifyOnboarding with any type of body +func NewNotifyOnboardingRequestWithBody(server string, onboardingID OnboardingID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "onboarding_id", runtime.ParamLocationPath, onboardingID) if err != nil { return nil, err } @@ -12959,7 +14051,7 @@ func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentTyp return nil, err } - operationPath := fmt.Sprintf("/policies/%s", pathParam0) + operationPath := fmt.Sprintf("/onboardings/aws/oidc/%s/notify", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -12969,7 +14061,7 @@ func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentTyp return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -12979,23 +14071,16 @@ func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentTyp return req, nil } -// NewTogglePolicyRequest generates requests for TogglePolicy -func NewTogglePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { +// NewGetOpenAPIJSONRequest generates requests for GetOpenAPIJSON +func NewGetOpenAPIJSONRequest(server string) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies/%s/toggle", pathParam0) + operationPath := fmt.Sprintf("/openapi.json") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13005,7 +14090,7 @@ func NewTogglePolicyRequest(server string, policyID PolicyID) (*http.Request, er return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -13013,23 +14098,43 @@ func NewTogglePolicyRequest(server string, policyID PolicyID) (*http.Request, er return req, nil } -// NewGetPolicyViolationsRequest generates requests for GetPolicyViolations -func NewGetPolicyViolationsRequest(server string, policyID PolicyID, params *GetPolicyViolationsParams) (*http.Request, error) { +// NewGetPlatformInfoRequest generates requests for GetPlatformInfo +func NewGetPlatformInfoRequest(server string) (*http.Request, error) { var err error - var pathParam0 string + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) + operationPath := fmt.Sprintf("/platform-info") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewListPlatformVersionsRequest generates requests for ListPlatformVersions +func NewListPlatformVersionsRequest(server string, params *ListPlatformVersionsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies/%s/violations", pathParam0) + operationPath := fmt.Sprintf("/platform-versions") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13074,22 +14179,6 @@ func NewGetPolicyViolationsRequest(server string, policyID PolicyID, params *Get } - if params.Search != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - queryURL.RawQuery = queryValues.Encode() } @@ -13101,23 +14190,16 @@ func NewGetPolicyViolationsRequest(server string, policyID PolicyID, params *Get return req, nil } -// NewGetPolicyViolationsHistoryRequest generates requests for GetPolicyViolationsHistory -func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, params *GetPolicyViolationsHistoryParams) (*http.Request, error) { +// NewListPluginsRequest generates requests for ListPlugins +func NewListPluginsRequest(server string, params *ListPluginsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policies/%s/violations-history", pathParam0) + operationPath := fmt.Sprintf("/plugins") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13130,9 +14212,9 @@ func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, para if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { + if params.SortBy != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13162,9 +14244,9 @@ func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, para } - if params.StartTime != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_time", runtime.ParamLocationQuery, *params.StartTime); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13178,9 +14260,25 @@ func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, para } - if params.EndTime != nil { + if params.IncludeReleaseStages != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_time", runtime.ParamLocationQuery, *params.EndTime); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_release_stages", runtime.ParamLocationQuery, params.IncludeReleaseStages); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ExcludeReleaseStages != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "exclude_release_stages", runtime.ParamLocationQuery, params.ExcludeReleaseStages); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13205,16 +14303,85 @@ func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, para return req, nil } -// NewListPolicyGroupsRequest generates requests for ListPolicyGroups -func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) (*http.Request, error) { +// NewGetPluginRequest generates requests for GetPlugin +func NewGetPluginRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/plugins/%s/%s/%s", pathParam0, pathParam1, pathParam2) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewListPluginVersionsRequest generates requests for ListPluginVersions +func NewListPluginVersionsRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policy-groups") + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions", pathParam0, pathParam1, pathParam2) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13227,9 +14394,9 @@ func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) ( if params != nil { queryValues := queryURL.Query() - if params.Search != nil { + if params.SortBy != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13243,9 +14410,89 @@ func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) ( } - if params.Severities != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IncludeDrafts != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_drafts", runtime.ParamLocationQuery, *params.IncludeDrafts); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IncludeFips != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_fips", runtime.ParamLocationQuery, *params.IncludeFips); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IncludePrereleases != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_prereleases", runtime.ParamLocationQuery, *params.IncludePrereleases); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VersionFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "version_filter", runtime.ParamLocationQuery, *params.VersionFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13270,27 +14517,44 @@ func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) ( return req, nil } -// NewCreatePolicyGroupRequest calls the generic CreatePolicyGroup builder with application/json body -func NewCreatePolicyGroupRequest(server string, body CreatePolicyGroupJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewGetPluginVersionRequest generates requests for GetPluginVersion +func NewGetPluginVersionRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreatePolicyGroupRequestWithBody(server, "application/json", bodyReader) -} -// NewCreatePolicyGroupRequestWithBody generates requests for CreatePolicyGroup with any type of body -func NewCreatePolicyGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + + var pathParam3 string + + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + if err != nil { + return nil, err + } serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/policy-groups") + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s", pathParam0, pathParam1, pathParam2, pathParam3) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13300,23 +14564,49 @@ func NewCreatePolicyGroupRequestWithBody(server string, contentType string, body return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewDeletePolicyGroupRequest generates requests for DeletePolicyGroup -func NewDeletePolicyGroupRequest(server string, policyGroupID PolicyGroupID) (*http.Request, error) { +// NewDownloadPluginAssetRequest generates requests for DownloadPluginAsset +func NewDownloadPluginAssetRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + + var pathParam3 string + + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + if err != nil { + return nil, err + } + + var pathParam4 string + + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) if err != nil { return nil, err } @@ -13326,7 +14616,7 @@ func NewDeletePolicyGroupRequest(server string, policyGroupID PolicyGroupID) (*h return nil, err } - operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13336,21 +14626,57 @@ func NewDeletePolicyGroupRequest(server string, policyGroupID PolicyGroupID) (*h return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } + return req, nil } -// NewListPoliciesInGroupRequest generates requests for ListPoliciesInGroup -func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams) (*http.Request, error) { +// NewListPluginVersionTablesRequest generates requests for ListPluginVersionTables +func NewListPluginVersionTablesRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + + var pathParam3 string + + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) if err != nil { return nil, err } @@ -13360,7 +14686,7 @@ func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, p return nil, err } - operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables", pathParam0, pathParam1, pathParam2, pathParam3) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13373,22 +14699,6 @@ func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, p if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.Page != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { @@ -13405,25 +14715,9 @@ func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, p } - if params.SortBy != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortDir != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13448,24 +14742,41 @@ func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, p return req, nil } -// NewUpdatePolicyGroupRequest calls the generic UpdatePolicyGroup builder with application/json body -func NewUpdatePolicyGroupRequest(server string, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewGetPluginVersionTableRequest generates requests for GetPluginVersionTable +func NewGetPluginVersionTableRequest(server string, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUpdatePolicyGroupRequestWithBody(server, policyGroupID, "application/json", bodyReader) -} -// NewUpdatePolicyGroupRequestWithBody generates requests for UpdatePolicyGroup with any type of body -func NewUpdatePolicyGroupRequestWithBody(server string, policyGroupID PolicyGroupID, contentType string, body io.Reader) (*http.Request, error) { - var err error + var pathParam1 string - var pathParam0 string + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + if err != nil { + return nil, err + } + + var pathParam3 string + + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + if err != nil { + return nil, err + } + + var pathParam4 string + + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -13475,7 +14786,7 @@ func NewUpdatePolicyGroupRequestWithBody(server string, policyGroupID PolicyGrou return nil, err } - operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) + operationPath := fmt.Sprintf("/plugins/%s/%s/%s/versions/%s/tables/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13485,18 +14796,16 @@ func NewUpdatePolicyGroupRequestWithBody(server string, policyGroupID PolicyGrou return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewListAllQueriesRequest generates requests for ListAllQueries -func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*http.Request, error) { +// NewListPoliciesRequest generates requests for ListPolicies +func NewListPoliciesRequest(server string, params *ListPoliciesParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -13504,7 +14813,7 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt return nil, err } - operationPath := fmt.Sprintf("/queries") + operationPath := fmt.Sprintf("/policies") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13549,9 +14858,9 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.QueryTags != nil { + if params.PolicyStatus != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.QueryTags); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "status", runtime.ParamLocationQuery, *params.PolicyStatus); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13565,9 +14874,9 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.NameFilter != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13581,9 +14890,9 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.QueryFilter != nil { + if params.Domain != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_filter", runtime.ParamLocationQuery, *params.QueryFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13597,9 +14906,9 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.AlertConfigured != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_configured", runtime.ParamLocationQuery, *params.AlertConfigured); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13613,9 +14922,9 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.AlertMessageFilter != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_message_filter", runtime.ParamLocationQuery, *params.AlertMessageFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13629,9 +14938,25 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt } - if params.AlertEnabled != nil { + if params.SortBy != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_enabled", runtime.ParamLocationQuery, *params.AlertEnabled); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDir != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13656,19 +14981,19 @@ func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*htt return req, nil } -// NewExecuteAdHocQueryRequest calls the generic ExecuteAdHocQuery builder with application/json body -func NewExecuteAdHocQueryRequest(server string, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody) (*http.Request, error) { +// NewCreatePolicyRequest calls the generic CreatePolicy builder with application/json body +func NewCreatePolicyRequest(server string, body CreatePolicyJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewExecuteAdHocQueryRequestWithBody(server, params, "application/json", bodyReader) + return NewCreatePolicyRequestWithBody(server, "application/json", bodyReader) } -// NewExecuteAdHocQueryRequestWithBody generates requests for ExecuteAdHocQuery with any type of body -func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQueryParams, contentType string, body io.Reader) (*http.Request, error) { +// NewCreatePolicyRequestWithBody generates requests for CreatePolicy with any type of body +func NewCreatePolicyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -13676,7 +15001,36 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer return nil, err } - operationPath := fmt.Sprintf("/queries/execute") + operationPath := fmt.Sprintf("/policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetPolicyMetricsRequest generates requests for GetPolicyMetrics +func NewGetPolicyMetricsRequest(server string, params *GetPolicyMetricsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/policies/metrics") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13689,9 +15043,9 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer if params != nil { queryValues := queryURL.Query() - if params.Selects != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13705,9 +15059,9 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer } - if params.FilterMode != nil { + if params.Domain != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13721,9 +15075,9 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer } - if params.Filters != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13737,57 +15091,42 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer } - if params.FilterIDs != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - if params.SortBys != nil { + return req, nil +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// NewGetViolationsByDomainRequest generates requests for GetViolationsByDomain +func NewGetViolationsByDomainRequest(server string, params *GetViolationsByDomainParams) (*http.Request, error) { + var err error - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - if params.SortDirections != nil { + operationPath := fmt.Sprintf("/policies/violations-by-domain") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - } + if params != nil { + queryValues := queryURL.Query() - if params.GroupBys != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13801,9 +15140,9 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer } - if params.PerPage != nil { + if params.Domain != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13817,9 +15156,9 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer } - if params.Page != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13836,29 +15175,16 @@ func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQuer queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewSaveQueryRequest calls the generic SaveQuery builder with application/json body -func NewSaveQueryRequest(server string, body SaveQueryJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewSaveQueryRequestWithBody(server, "application/json", bodyReader) -} - -// NewSaveQueryRequestWithBody generates requests for SaveQuery with any type of body -func NewSaveQueryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewGetViolationsHistoryRequest generates requests for GetViolationsHistory +func NewGetViolationsHistoryRequest(server string, params *GetViolationsHistoryParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -13866,7 +15192,7 @@ func NewSaveQueryRequestWithBody(server string, contentType string, body io.Read return nil, err } - operationPath := fmt.Sprintf("/queries/save") + operationPath := fmt.Sprintf("/policies/violations-history") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13876,41 +15202,60 @@ func NewSaveQueryRequestWithBody(server string, contentType string, body io.Read return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.StartDate != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_date", runtime.ParamLocationQuery, *params.StartDate); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListQueryTagsRequest generates requests for ListQueryTags -func NewListQueryTagsRequest(server string, params *ListQueryTagsParams) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.EndDate != nil { - operationPath := fmt.Sprintf("/queries/tags") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_date", runtime.ParamLocationQuery, *params.EndDate); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + } - if params != nil { - queryValues := queryURL.Query() + if params.Severities != nil { - if params.PerPage != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + } + + if params.Domain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "domain", runtime.ParamLocationQuery, *params.Domain); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13924,9 +15269,9 @@ func NewListQueryTagsRequest(server string, params *ListQueryTagsParams) (*http. } - if params.Page != nil { + if params.PolicyGroupIds != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "policy_group_ids", runtime.ParamLocationQuery, params.PolicyGroupIds); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -13951,13 +15296,13 @@ func NewListQueryTagsRequest(server string, params *ListQueryTagsParams) (*http. return req, nil } -// NewDeleteSavedQueryRequest generates requests for DeleteSavedQuery -func NewDeleteSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { +// NewDeletePolicyRequest generates requests for DeletePolicy +func NewDeletePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -13967,7 +15312,7 @@ func NewDeleteSavedQueryRequest(server string, queryID QueryID) (*http.Request, return nil, err } - operationPath := fmt.Sprintf("/queries/%s", pathParam0) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -13985,13 +15330,13 @@ func NewDeleteSavedQueryRequest(server string, queryID QueryID) (*http.Request, return req, nil } -// NewGetSavedQueryRequest generates requests for GetSavedQuery -func NewGetSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { +// NewGetPolicyRequest generates requests for GetPolicy +func NewGetPolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14001,7 +15346,7 @@ func NewGetSavedQueryRequest(server string, queryID QueryID) (*http.Request, err return nil, err } - operationPath := fmt.Sprintf("/queries/%s", pathParam0) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14019,24 +15364,24 @@ func NewGetSavedQueryRequest(server string, queryID QueryID) (*http.Request, err return req, nil } -// NewUpdateQueryRequest calls the generic UpdateQuery builder with application/json body -func NewUpdateQueryRequest(server string, queryID QueryID, body UpdateQueryJSONRequestBody) (*http.Request, error) { +// NewUpdatePolicyRequest calls the generic UpdatePolicy builder with application/json body +func NewUpdatePolicyRequest(server string, policyID PolicyID, body UpdatePolicyJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateQueryRequestWithBody(server, queryID, "application/json", bodyReader) + return NewUpdatePolicyRequestWithBody(server, policyID, "application/json", bodyReader) } -// NewUpdateQueryRequestWithBody generates requests for UpdateQuery with any type of body -func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdatePolicyRequestWithBody generates requests for UpdatePolicy with any type of body +func NewUpdatePolicyRequestWithBody(server string, policyID PolicyID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14046,7 +15391,7 @@ func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType s return nil, err } - operationPath := fmt.Sprintf("/queries/%s", pathParam0) + operationPath := fmt.Sprintf("/policies/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14056,7 +15401,7 @@ func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType s return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } @@ -14066,13 +15411,13 @@ func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType s return req, nil } -// NewDeleteAlertRequest generates requests for DeleteAlert -func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error) { +// NewTogglePolicyRequest generates requests for TogglePolicy +func NewTogglePolicyRequest(server string, policyID PolicyID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14082,7 +15427,7 @@ func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error return nil, err } - operationPath := fmt.Sprintf("/queries/%s/alert", pathParam0) + operationPath := fmt.Sprintf("/policies/%s/toggle", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14092,7 +15437,7 @@ func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -14100,13 +15445,13 @@ func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error return req, nil } -// NewExecuteSavedQueryRequest generates requests for ExecuteSavedQuery -func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *ExecuteSavedQueryParams) (*http.Request, error) { +// NewGetPolicyViolationsRequest generates requests for GetPolicyViolations +func NewGetPolicyViolationsRequest(server string, policyID PolicyID, params *GetPolicyViolationsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) if err != nil { return nil, err } @@ -14116,7 +15461,7 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute return nil, err } - operationPath := fmt.Sprintf("/queries/%s/execute", pathParam0) + operationPath := fmt.Sprintf("/policies/%s/violations", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14129,9 +15474,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute if params != nil { queryValues := queryURL.Query() - if params.Selects != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14145,9 +15490,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.FilterMode != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14161,9 +15506,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.Filters != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14177,41 +15522,49 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.FilterIDs != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - } + return req, nil +} - if params.SortBys != nil { +// NewGetPolicyViolationsHistoryRequest generates requests for GetPolicyViolationsHistory +func NewGetPolicyViolationsHistoryRequest(server string, policyID PolicyID, params *GetPolicyViolationsHistoryParams) (*http.Request, error) { + var err error - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + var pathParam0 string - } + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_id", runtime.ParamLocationPath, policyID) + if err != nil { + return nil, err + } - if params.SortDirections != nil { + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + operationPath := fmt.Sprintf("/policies/%s/violations-history", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14225,9 +15578,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.GroupBys != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14241,9 +15594,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.PerPage != nil { + if params.StartTime != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start_time", runtime.ParamLocationQuery, *params.StartTime); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14257,9 +15610,9 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute } - if params.Page != nil { + if params.EndTime != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end_time", runtime.ParamLocationQuery, *params.EndTime); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14276,7 +15629,7 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("POST", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -14284,23 +15637,16 @@ func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *Execute return req, nil } -// NewQueryListFiltersRequest generates requests for QueryListFilters -func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryListFiltersParams) (*http.Request, error) { +// NewListPolicyGroupsRequest generates requests for ListPolicyGroups +func NewListPolicyGroupsRequest(server string, params *ListPolicyGroupsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) + operationPath := fmt.Sprintf("/policy-groups") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14313,25 +15659,9 @@ func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryLis if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { + if params.Search != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search", runtime.ParamLocationQuery, *params.Search); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14345,9 +15675,9 @@ func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryLis } - if params.FilterTags != nil { + if params.Severities != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "severities", runtime.ParamLocationQuery, params.Severities); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14372,34 +15702,27 @@ func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryLis return req, nil } -// NewQuerySaveFilterRequest calls the generic QuerySaveFilter builder with application/json body -func NewQuerySaveFilterRequest(server string, queryID QueryID, body QuerySaveFilterJSONRequestBody) (*http.Request, error) { +// NewCreatePolicyGroupRequest calls the generic CreatePolicyGroup builder with application/json body +func NewCreatePolicyGroupRequest(server string, body CreatePolicyGroupJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewQuerySaveFilterRequestWithBody(server, queryID, "application/json", bodyReader) + return NewCreatePolicyGroupRequestWithBody(server, "application/json", bodyReader) } -// NewQuerySaveFilterRequestWithBody generates requests for QuerySaveFilter with any type of body -func NewQuerySaveFilterRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { +// NewCreatePolicyGroupRequestWithBody generates requests for CreatePolicyGroup with any type of body +func NewCreatePolicyGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) + operationPath := fmt.Sprintf("/policy-groups") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14419,13 +15742,13 @@ func NewQuerySaveFilterRequestWithBody(server string, queryID QueryID, contentTy return req, nil } -// NewQueryListFilterTagsRequest generates requests for QueryListFilterTags -func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *QueryListFilterTagsParams) (*http.Request, error) { +// NewDeletePolicyGroupRequest generates requests for DeletePolicyGroup +func NewDeletePolicyGroupRequest(server string, policyGroupID PolicyGroupID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) if err != nil { return nil, err } @@ -14435,7 +15758,7 @@ func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *Query return nil, err } - operationPath := fmt.Sprintf("/queries/%s/filters/tags", pathParam0) + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14445,45 +15768,7 @@ func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *Query return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -14491,16 +15776,23 @@ func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *Query return req, nil } -// NewListAllRBACPermissionsRequest generates requests for ListAllRBACPermissions -func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissionsParams) (*http.Request, error) { +// NewListPoliciesInGroupRequest generates requests for ListPoliciesInGroup +func NewListPoliciesInGroupRequest(server string, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/rbac/permissions") + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14545,25 +15837,9 @@ func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissi } - if params.RBACPermissionSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACPermissionSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.RBACPermissionSortDirections != nil { + if params.SortBy != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACPermissionSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, *params.SortBy); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14577,9 +15853,9 @@ func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissi } - if params.SearchTerm != nil { + if params.SortDir != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, *params.SortDir); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14604,53 +15880,24 @@ func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissi return req, nil } -// NewCreateRBACPermissionRequest calls the generic CreateRBACPermission builder with application/json body -func NewCreateRBACPermissionRequest(server string, body CreateRBACPermissionJSONRequestBody) (*http.Request, error) { +// NewUpdatePolicyGroupRequest calls the generic UpdatePolicyGroup builder with application/json body +func NewUpdatePolicyGroupRequest(server string, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateRBACPermissionRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateRBACPermissionRequestWithBody generates requests for CreateRBACPermission with any type of body -func NewCreateRBACPermissionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/rbac/permissions") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil + return NewUpdatePolicyGroupRequestWithBody(server, policyGroupID, "application/json", bodyReader) } -// NewDeleteRBACPermissionRequest generates requests for DeleteRBACPermission -func NewDeleteRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { +// NewUpdatePolicyGroupRequestWithBody generates requests for UpdatePolicyGroup with any type of body +func NewUpdatePolicyGroupRequestWithBody(server string, policyGroupID PolicyGroupID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "policy_group_id", runtime.ParamLocationPath, policyGroupID) if err != nil { return nil, err } @@ -14660,7 +15907,7 @@ func NewDeleteRBACPermissionRequest(server string, rbacPermissionID RBACPermissi return nil, err } - operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) + operationPath := fmt.Sprintf("/policy-groups/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14670,105 +15917,26 @@ func NewDeleteRBACPermissionRequest(server string, rbacPermissionID RBACPermissi return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetRBACPermissionRequest generates requests for GetRBACPermission -func NewGetRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { +// NewListAllQueriesRequest generates requests for ListAllQueries +func NewListAllQueriesRequest(server string, params *ListAllQueriesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdateRBACPermissionRequest calls the generic UpdateRBACPermission builder with application/json body -func NewUpdateRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateRBACPermissionRequestWithBody(server, rbacPermissionID, "application/json", bodyReader) -} - -// NewUpdateRBACPermissionRequestWithBody generates requests for UpdateRBACPermission with any type of body -func NewUpdateRBACPermissionRequestWithBody(server string, rbacPermissionID RBACPermissionID, contentType string, body io.Reader) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewListAllRBACRolesRequest generates requests for ListAllRBACRoles -func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/rbac/roles") + operationPath := fmt.Sprintf("/queries") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -14813,9 +15981,9 @@ func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) ( } - if params.RBACRoleSortBys != nil { + if params.QueryTags != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACRoleSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.QueryTags); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14829,9 +15997,9 @@ func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) ( } - if params.RBACRoleSortDirections != nil { + if params.NameFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACRoleSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name_filter", runtime.ParamLocationQuery, *params.NameFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14845,9 +16013,9 @@ func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) ( } - if params.SearchTerm != nil { + if params.QueryFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "query_filter", runtime.ParamLocationQuery, *params.QueryFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14861,9 +16029,9 @@ func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) ( } - if params.Type != nil { + if params.AlertConfigured != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "type", runtime.ParamLocationQuery, *params.Type); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_configured", runtime.ParamLocationQuery, *params.AlertConfigured); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -14877,115 +16045,55 @@ func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) ( } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewCreateRBACRoleRequest calls the generic CreateRBACRole builder with application/json body -func NewCreateRBACRoleRequest(server string, body CreateRBACRoleJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateRBACRoleRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateRBACRoleRequestWithBody generates requests for CreateRBACRole with any type of body -func NewCreateRBACRoleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/rbac/roles") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteRBACRoleRequest generates requests for DeleteRBACRole -func NewDeleteRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.AlertMessageFilter != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_message_filter", runtime.ParamLocationQuery, *params.AlertMessageFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } + } - return req, nil -} + if params.AlertEnabled != nil { -// NewGetRBACRoleRequest generates requests for GetRBACRole -func NewGetRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { - var err error + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "alert_enabled", runtime.ParamLocationQuery, *params.AlertEnabled); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam0 string + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) - if err != nil { - return nil, err - } + if params.ColumnFilter != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "column_filter", runtime.ParamLocationQuery, params.ColumnFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -14996,34 +16104,27 @@ func NewGetRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) return req, nil } -// NewUpdateRBACRoleRequest calls the generic UpdateRBACRole builder with application/json body -func NewUpdateRBACRoleRequest(server string, roleID RoleID, body UpdateRBACRoleJSONRequestBody) (*http.Request, error) { +// NewExecuteAdHocQueryRequest calls the generic ExecuteAdHocQuery builder with application/json body +func NewExecuteAdHocQueryRequest(server string, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateRBACRoleRequestWithBody(server, roleID, "application/json", bodyReader) + return NewExecuteAdHocQueryRequestWithBody(server, params, "application/json", bodyReader) } -// NewUpdateRBACRoleRequestWithBody generates requests for UpdateRBACRole with any type of body -func NewUpdateRBACRoleRequestWithBody(server string, roleID RoleID, contentType string, body io.Reader) (*http.Request, error) { +// NewExecuteAdHocQueryRequestWithBody generates requests for ExecuteAdHocQuery with any type of body +func NewExecuteAdHocQueryRequestWithBody(server string, params *ExecuteAdHocQueryParams, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/execute") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15033,41 +16134,60 @@ func NewUpdateRBACRoleRequestWithBody(server string, roleID RoleID, contentType return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.Selects != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListReportsRequest generates requests for ListReports -func NewListReportsRequest(server string, params *ListReportsParams) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.FilterMode != nil { - operationPath := fmt.Sprintf("/reports") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + } - if params != nil { - queryValues := queryURL.Query() + if params.Filters != nil { - if params.SearchTerm != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + } + + if params.FilterIDs != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15081,9 +16201,9 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ } - if params.Visibility != nil { + if params.SortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "visibility", runtime.ParamLocationQuery, *params.Visibility); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15097,9 +16217,9 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ } - if params.PerPage != nil { + if params.SortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15113,9 +16233,9 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ } - if params.Page != nil { + if params.GroupBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15129,9 +16249,9 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ } - if params.ReportSortBys != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15145,9 +16265,9 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ } - if params.ReportSortDirections != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15164,27 +16284,29 @@ func NewListReportsRequest(server string, params *ListReportsParams) (*http.Requ queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewCreateReportRequest calls the generic CreateReport builder with application/json body -func NewCreateReportRequest(server string, body CreateReportJSONRequestBody) (*http.Request, error) { +// NewSaveQueryRequest calls the generic SaveQuery builder with application/json body +func NewSaveQueryRequest(server string, body SaveQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateReportRequestWithBody(server, "application/json", bodyReader) + return NewSaveQueryRequestWithBody(server, "application/json", bodyReader) } -// NewCreateReportRequestWithBody generates requests for CreateReport with any type of body -func NewCreateReportRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewSaveQueryRequestWithBody generates requests for SaveQuery with any type of body +func NewSaveQueryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -15192,7 +16314,7 @@ func NewCreateReportRequestWithBody(server string, contentType string, body io.R return nil, err } - operationPath := fmt.Sprintf("/reports") + operationPath := fmt.Sprintf("/queries/save") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15212,8 +16334,8 @@ func NewCreateReportRequestWithBody(server string, contentType string, body io.R return req, nil } -// NewListReportTemplatesRequest generates requests for ListReportTemplates -func NewListReportTemplatesRequest(server string, params *ListReportTemplatesParams) (*http.Request, error) { +// NewListQueryTagsRequest generates requests for ListQueryTags +func NewListQueryTagsRequest(server string, params *ListQueryTagsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -15221,7 +16343,7 @@ func NewListReportTemplatesRequest(server string, params *ListReportTemplatesPar return nil, err } - operationPath := fmt.Sprintf("/reports/templates") + operationPath := fmt.Sprintf("/queries/tags") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15234,22 +16356,6 @@ func NewListReportTemplatesRequest(server string, params *ListReportTemplatesPar if params != nil { queryValues := queryURL.Query() - if params.SearchTerm != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -15282,38 +16388,6 @@ func NewListReportTemplatesRequest(server string, params *ListReportTemplatesPar } - if params.ReportTemplateSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportTemplateSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.ReportTemplateSortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportTemplateSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - queryURL.RawQuery = queryValues.Encode() } @@ -15325,53 +16399,13 @@ func NewListReportTemplatesRequest(server string, params *ListReportTemplatesPar return req, nil } -// NewCreateReportTemplateRequest calls the generic CreateReportTemplate builder with application/json body -func NewCreateReportTemplateRequest(server string, body CreateReportTemplateJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateReportTemplateRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateReportTemplateRequestWithBody generates requests for CreateReportTemplate with any type of body -func NewCreateReportTemplateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/reports/templates") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteReportTemplateRequest generates requests for DeleteReportTemplate -func NewDeleteReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { +// NewDeleteSavedQueryRequest generates requests for DeleteSavedQuery +func NewDeleteSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15381,7 +16415,7 @@ func NewDeleteReportTemplateRequest(server string, templateId openapi_types.UUID return nil, err } - operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15399,13 +16433,13 @@ func NewDeleteReportTemplateRequest(server string, templateId openapi_types.UUID return req, nil } -// NewGetReportTemplateRequest generates requests for GetReportTemplate -func NewGetReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { +// NewGetSavedQueryRequest generates requests for GetSavedQuery +func NewGetSavedQueryRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15415,7 +16449,7 @@ func NewGetReportTemplateRequest(server string, templateId openapi_types.UUID) ( return nil, err } - operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15433,24 +16467,24 @@ func NewGetReportTemplateRequest(server string, templateId openapi_types.UUID) ( return req, nil } -// NewUpdateReportTemplateRequest calls the generic UpdateReportTemplate builder with application/json body -func NewUpdateReportTemplateRequest(server string, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody) (*http.Request, error) { +// NewUpdateQueryRequest calls the generic UpdateQuery builder with application/json body +func NewUpdateQueryRequest(server string, queryID QueryID, body UpdateQueryJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateReportTemplateRequestWithBody(server, templateId, "application/json", bodyReader) + return NewUpdateQueryRequestWithBody(server, queryID, "application/json", bodyReader) } -// NewUpdateReportTemplateRequestWithBody generates requests for UpdateReportTemplate with any type of body -func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateQueryRequestWithBody generates requests for UpdateQuery with any type of body +func NewUpdateQueryRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15460,7 +16494,7 @@ func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_ty return nil, err } - operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15470,7 +16504,7 @@ func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_ty return nil, err } - req, err := http.NewRequest("PUT", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -15480,13 +16514,13 @@ func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_ty return req, nil } -// NewDeleteReportRequest generates requests for DeleteReport -func NewDeleteReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { +// NewDeleteAlertRequest generates requests for DeleteAlert +func NewDeleteAlertRequest(server string, queryID QueryID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15496,7 +16530,7 @@ func NewDeleteReportRequest(server string, reportId openapi_types.UUID) (*http.R return nil, err } - operationPath := fmt.Sprintf("/reports/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/%s/alert", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15514,13 +16548,13 @@ func NewDeleteReportRequest(server string, reportId openapi_types.UUID) (*http.R return req, nil } -// NewGetReportRequest generates requests for GetReport -func NewGetReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { +// NewExecuteSavedQueryRequest generates requests for ExecuteSavedQuery +func NewExecuteSavedQueryRequest(server string, queryID QueryID, params *ExecuteSavedQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } @@ -15530,7 +16564,7 @@ func NewGetReportRequest(server string, reportId openapi_types.UUID) (*http.Requ return nil, err } - operationPath := fmt.Sprintf("/reports/%s", pathParam0) + operationPath := fmt.Sprintf("/queries/%s/execute", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15540,81 +16574,157 @@ func NewGetReportRequest(server string, reportId openapi_types.UUID) (*http.Requ return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - return req, nil -} + if params.Selects != nil { -// NewUpdateReportRequest calls the generic UpdateReport builder with application/json body -func NewUpdateReportRequest(server string, reportId openapi_types.UUID, body UpdateReportJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateReportRequestWithBody(server, reportId, "application/json", bodyReader) -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUpdateReportRequestWithBody generates requests for UpdateReport with any type of body -func NewUpdateReportRequestWithBody(server string, reportId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.FilterMode != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/reports/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.Filters != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - req, err := http.NewRequest("PUT", queryURL.String(), body) - if err != nil { - return nil, err - } + } - req.Header.Add("Content-Type", contentType) + if params.FilterIDs != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewGetSettingsRequest generates requests for GetSettings -func NewGetSettingsRequest(server string) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.SortBys != nil { - operationPath := fmt.Sprintf("/settings") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + } + + if params.SortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.GroupBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -15622,27 +16732,23 @@ func NewGetSettingsRequest(server string) (*http.Request, error) { return req, nil } -// NewUpdateSettingsRequest calls the generic UpdateSettings builder with application/json body -func NewUpdateSettingsRequest(server string, body UpdateSettingsJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewQueryListFiltersRequest generates requests for QueryListFilters +func NewQueryListFiltersRequest(server string, queryID QueryID, params *QueryListFiltersParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUpdateSettingsRequestWithBody(server, "application/json", bodyReader) -} - -// NewUpdateSettingsRequestWithBody generates requests for UpdateSettings with any type of body -func NewUpdateSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/settings") + operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15652,33 +16758,58 @@ func NewUpdateSettingsRequestWithBody(server string, contentType string, body io return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.PerPage != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewGetDataSettingsRequest generates requests for GetDataSettings -func NewGetDataSettingsRequest(server string) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.Page != nil { - operationPath := fmt.Sprintf("/settings/data") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + } + + if params.FilterTags != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -15689,27 +16820,34 @@ func NewGetDataSettingsRequest(server string) (*http.Request, error) { return req, nil } -// NewUpdateDataSettingsRequest calls the generic UpdateDataSettings builder with application/json body -func NewUpdateDataSettingsRequest(server string, body UpdateDataSettingsJSONRequestBody) (*http.Request, error) { +// NewQuerySaveFilterRequest calls the generic QuerySaveFilter builder with application/json body +func NewQuerySaveFilterRequest(server string, queryID QueryID, body QuerySaveFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateDataSettingsRequestWithBody(server, "application/json", bodyReader) + return NewQuerySaveFilterRequestWithBody(server, queryID, "application/json", bodyReader) } -// NewUpdateDataSettingsRequestWithBody generates requests for UpdateDataSettings with any type of body -func NewUpdateDataSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewQuerySaveFilterRequestWithBody generates requests for QuerySaveFilter with any type of body +func NewQuerySaveFilterRequestWithBody(server string, queryID QueryID, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/settings/data") + operationPath := fmt.Sprintf("/queries/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15719,7 +16857,7 @@ func NewUpdateDataSettingsRequestWithBody(server string, contentType string, bod return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -15729,27 +16867,23 @@ func NewUpdateDataSettingsRequestWithBody(server string, contentType string, bod return req, nil } -// NewCreateSlackConnectionRequest calls the generic CreateSlackConnection builder with application/json body -func NewCreateSlackConnectionRequest(server string, body CreateSlackConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewQueryListFilterTagsRequest generates requests for QueryListFilterTags +func NewQueryListFilterTagsRequest(server string, queryID QueryID, params *QueryListFilterTagsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "query_id", runtime.ParamLocationPath, queryID) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateSlackConnectionRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateSlackConnectionRequestWithBody generates requests for CreateSlackConnection with any type of body -func NewCreateSlackConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/slack") + operationPath := fmt.Sprintf("/queries/%s/filters/tags", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15759,33 +16893,62 @@ func NewCreateSlackConnectionRequestWithBody(server string, contentType string, return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.PerPage != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListSlackChannelsRequest generates requests for ListSlackChannels -func NewListSlackChannelsRequest(server string, id openapi_types.UUID, params *ListSlackChannelsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.Page != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "id", runtime.ParamLocationPath, id) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + return req, nil +} + +// NewListAllRBACPermissionsRequest generates requests for ListAllRBACPermissions +func NewListAllRBACPermissionsRequest(server string, params *ListAllRBACPermissionsParams) (*http.Request, error) { + var err error + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/slack/%s/channels", pathParam0) + operationPath := fmt.Sprintf("/rbac/permissions") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15798,9 +16961,73 @@ func NewListSlackChannelsRequest(server string, id openapi_types.UUID, params *L if params != nil { queryValues := queryURL.Query() - if params.Name != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name", runtime.ParamLocationQuery, *params.Name); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.RBACPermissionSortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACPermissionSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.RBACPermissionSortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACPermissionSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SearchTerm != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -15825,19 +17052,19 @@ func NewListSlackChannelsRequest(server string, id openapi_types.UUID, params *L return req, nil } -// NewCreateSyncDestinationTestConnectionRequest calls the generic CreateSyncDestinationTestConnection builder with application/json body -func NewCreateSyncDestinationTestConnectionRequest(server string, body CreateSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { +// NewCreateRBACPermissionRequest calls the generic CreateRBACPermission builder with application/json body +func NewCreateRBACPermissionRequest(server string, body CreateRBACPermissionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateSyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) + return NewCreateRBACPermissionRequestWithBody(server, "application/json", bodyReader) } -// NewCreateSyncDestinationTestConnectionRequestWithBody generates requests for CreateSyncDestinationTestConnection with any type of body -func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateRBACPermissionRequestWithBody generates requests for CreateRBACPermission with any type of body +func NewCreateRBACPermissionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -15845,7 +17072,7 @@ func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, conten return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections") + operationPath := fmt.Sprintf("/rbac/permissions") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15865,13 +17092,13 @@ func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, conten return req, nil } -// NewGetSyncDestinationTestConnectionRequest generates requests for GetSyncDestinationTestConnection -func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID) (*http.Request, error) { +// NewDeleteRBACPermissionRequest generates requests for DeleteRBACPermission +func NewDeleteRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -15881,7 +17108,7 @@ func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTe return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15891,7 +17118,7 @@ func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTe return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -15899,24 +17126,13 @@ func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTe return req, nil } -// NewUpdateSyncTestConnectionForSyncDestinationRequest calls the generic UpdateSyncTestConnectionForSyncDestination builder with application/json body -func NewUpdateSyncTestConnectionForSyncDestinationRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) -} - -// NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestination with any type of body -func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetRBACPermissionRequest generates requests for GetRBACPermission +func NewGetRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -15926,7 +17142,7 @@ func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15936,23 +17152,32 @@ func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetSyncDestinationTestConnectionLogsLiveRequest generates requests for GetSyncDestinationTestConnectionLogsLive -func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams) (*http.Request, error) { +// NewUpdateRBACPermissionRequest calls the generic UpdateRBACPermission builder with application/json body +func NewUpdateRBACPermissionRequest(server string, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateRBACPermissionRequestWithBody(server, rbacPermissionID, "application/json", bodyReader) +} + +// NewUpdateRBACPermissionRequestWithBody generates requests for UpdateRBACPermission with any type of body +func NewUpdateRBACPermissionRequestWithBody(server string, rbacPermissionID RBACPermissionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "permission_id", runtime.ParamLocationPath, rbacPermissionID) if err != nil { return nil, err } @@ -15962,7 +17187,7 @@ func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, syncDesti return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/live", pathParam0) + operationPath := fmt.Sprintf("/rbac/permissions/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -15972,46 +17197,26 @@ func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, syncDesti return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } + req.Header.Add("Content-Type", contentType) return req, nil } -// NewGetSyncDestinationTestConnectionLogsQueryRequest generates requests for GetSyncDestinationTestConnectionLogsQuery -func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams) (*http.Request, error) { +// NewListAllRBACRolesRequest generates requests for ListAllRBACRoles +func NewListAllRBACRolesRequest(server string, params *ListAllRBACRolesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/query", pathParam0) + operationPath := fmt.Sprintf("/rbac/roles") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16024,9 +17229,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDest if params != nil { queryValues := queryURL.Query() - if params.Filters != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16040,9 +17245,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDest } - if params.PerPage != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16056,9 +17261,9 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDest } - if params.Page != nil { + if params.RBACRoleSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.RBACRoleSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16072,9 +17277,41 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDest } - if params.Download != nil { + if params.RBACRoleSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.RBACRoleSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SearchTerm != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Type != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "type", runtime.ParamLocationQuery, *params.Type); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16096,42 +17333,135 @@ func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDest return nil, err } - if params != nil { + return req, nil +} - if params.Accept != nil { - var headerParam0 string +// NewCreateRBACRoleRequest calls the generic CreateRBACRole builder with application/json body +func NewCreateRBACRoleRequest(server string, body CreateRBACRoleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateRBACRoleRequestWithBody(server, "application/json", bodyReader) +} - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +// NewCreateRBACRoleRequestWithBody generates requests for CreateRBACRole with any type of body +func NewCreateRBACRoleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - req.Header.Set("Accept", headerParam0) - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/rbac/roles") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewPromoteSyncDestinationTestConnectionRequest calls the generic PromoteSyncDestinationTestConnection builder with application/json body -func NewPromoteSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { +// NewDeleteRBACRoleRequest generates requests for DeleteRBACRole +func NewDeleteRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetRBACRoleRequest generates requests for GetRBACRole +func NewGetRBACRoleRequest(server string, roleID RoleID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateRBACRoleRequest calls the generic UpdateRBACRole builder with application/json body +func NewUpdateRBACRoleRequest(server string, roleID RoleID, body UpdateRBACRoleJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewPromoteSyncDestinationTestConnectionRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) + return NewUpdateRBACRoleRequestWithBody(server, roleID, "application/json", bodyReader) } -// NewPromoteSyncDestinationTestConnectionRequestWithBody generates requests for PromoteSyncDestinationTestConnection with any type of body -func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateRBACRoleRequestWithBody generates requests for UpdateRBACRole with any type of body +func NewUpdateRBACRoleRequestWithBody(server string, roleID RoleID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "role_id", runtime.ParamLocationPath, roleID) if err != nil { return nil, err } @@ -16141,7 +17471,7 @@ func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncD return nil, err } - operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/promote", pathParam0) + operationPath := fmt.Sprintf("/rbac/roles/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16151,7 +17481,7 @@ func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncD return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -16161,8 +17491,8 @@ func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncD return req, nil } -// NewListSyncDestinationsRequest generates requests for ListSyncDestinations -func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsParams) (*http.Request, error) { +// NewListReportsRequest generates requests for ListReports +func NewListReportsRequest(server string, params *ListReportsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -16170,7 +17500,7 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP return nil, err } - operationPath := fmt.Sprintf("/sync-destinations") + operationPath := fmt.Sprintf("/reports") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16183,9 +17513,9 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { + if params.SearchTerm != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16199,9 +17529,9 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP } - if params.Page != nil { + if params.Visibility != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "visibility", runtime.ParamLocationQuery, *params.Visibility); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16215,9 +17545,9 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP } - if params.Filter != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16231,9 +17561,9 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP } - if params.SyncGenericSortBys != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16247,9 +17577,9 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP } - if params.SyncSortDirections != nil { + if params.ReportSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16263,75 +17593,23 @@ func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsP } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewDeleteSyncDestinationRequest generates requests for DeleteSyncDestination -func NewDeleteSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetSyncDestinationRequest generates requests for GetSyncDestination -func NewGetSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } + if params.ReportSortDirections != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -16342,34 +17620,27 @@ func NewGetSyncDestinationRequest(server string, syncDestinationName SyncDestina return req, nil } -// NewUpdateSyncDestinationRequest calls the generic UpdateSyncDestination builder with application/json body -func NewUpdateSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody) (*http.Request, error) { +// NewCreateReportRequest calls the generic CreateReport builder with application/json body +func NewCreateReportRequest(server string, body CreateReportJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) + return NewCreateReportRequestWithBody(server, "application/json", bodyReader) } -// NewUpdateSyncDestinationRequestWithBody generates requests for UpdateSyncDestination with any type of body -func NewUpdateSyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateReportRequestWithBody generates requests for CreateReport with any type of body +func NewCreateReportRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) + operationPath := fmt.Sprintf("/reports") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16379,7 +17650,7 @@ func NewUpdateSyncDestinationRequestWithBody(server string, syncDestinationName return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -16389,23 +17660,16 @@ func NewUpdateSyncDestinationRequestWithBody(server string, syncDestinationName return req, nil } -// NewListSyncDestinationSyncsRequest generates requests for ListSyncDestinationSyncs -func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams) (*http.Request, error) { +// NewListReportTemplatesRequest generates requests for ListReportTemplates +func NewListReportTemplatesRequest(server string, params *ListReportTemplatesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-destinations/%s/syncs", pathParam0) + operationPath := fmt.Sprintf("/reports/templates") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16418,25 +17682,9 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { + if params.SearchTerm != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "search_term", runtime.ParamLocationQuery, *params.SearchTerm); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16450,9 +17698,9 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD } - if params.SyncSortBys != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16466,9 +17714,9 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD } - if params.SyncSortDirections != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16482,9 +17730,9 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD } - if params.Filter != nil { + if params.ReportTemplateSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.ReportTemplateSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16498,9 +17746,9 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD } - if params.MigrationFilter != nil { + if params.ReportTemplateSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.ReportTemplateSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -16525,30 +17773,27 @@ func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncD return req, nil } -// NewGetTestConnectionForSyncDestinationRequest generates requests for GetTestConnectionForSyncDestination -func NewGetTestConnectionForSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) +// NewCreateReportTemplateRequest calls the generic CreateReportTemplate builder with application/json body +func NewCreateReportTemplateRequest(server string, body CreateReportTemplateJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateReportTemplateRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) - if err != nil { - return nil, err - } +// NewCreateReportTemplateRequestWithBody generates requests for CreateReportTemplate with any type of body +func NewCreateReportTemplateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-destinations/%s/test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/reports/templates") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16558,35 +17803,33 @@ func NewGetTestConnectionForSyncDestinationRequest(server string, syncDestinatio return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewCreateSyncSourceTestConnectionRequest calls the generic CreateSyncSourceTestConnection builder with application/json body -func NewCreateSyncSourceTestConnectionRequest(server string, body CreateSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewDeleteReportTemplateRequest generates requests for DeleteReportTemplate +func NewDeleteReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncSourceTestConnectionRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateSyncSourceTestConnectionRequestWithBody generates requests for CreateSyncSourceTestConnection with any type of body -func NewCreateSyncSourceTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections") + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16596,23 +17839,21 @@ func NewCreateSyncSourceTestConnectionRequestWithBody(server string, contentType return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetSyncSourceTestConnectionRequest generates requests for GetSyncSourceTestConnection -func NewGetSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID) (*http.Request, error) { +// NewGetReportTemplateRequest generates requests for GetReportTemplate +func NewGetReportTemplateRequest(server string, templateId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } @@ -16622,7 +17863,7 @@ func NewGetSyncSourceTestConnectionRequest(server string, syncSourceTestConnecti return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16640,24 +17881,24 @@ func NewGetSyncSourceTestConnectionRequest(server string, syncSourceTestConnecti return req, nil } -// NewUpdateSyncTestConnectionForSyncSourceRequest calls the generic UpdateSyncTestConnectionForSyncSource builder with application/json body -func NewUpdateSyncTestConnectionForSyncSourceRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody) (*http.Request, error) { +// NewUpdateReportTemplateRequest calls the generic UpdateReportTemplate builder with application/json body +func NewUpdateReportTemplateRequest(server string, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) + return NewUpdateReportTemplateRequestWithBody(server, templateId, "application/json", bodyReader) } -// NewUpdateSyncTestConnectionForSyncSourceRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSource with any type of body -func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateReportTemplateRequestWithBody generates requests for UpdateReportTemplate with any type of body +func NewUpdateReportTemplateRequestWithBody(server string, templateId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "template_id", runtime.ParamLocationPath, templateId) if err != nil { return nil, err } @@ -16667,7 +17908,7 @@ func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, sync return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) + operationPath := fmt.Sprintf("/reports/templates/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16677,7 +17918,7 @@ func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, sync return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("PUT", queryURL.String(), body) if err != nil { return nil, err } @@ -16687,13 +17928,13 @@ func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, sync return req, nil } -// NewGetSyncSourceTestConnectionLogsLiveRequest generates requests for GetSyncSourceTestConnectionLogsLive -func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams) (*http.Request, error) { +// NewDeleteReportRequest generates requests for DeleteReport +func NewDeleteReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) if err != nil { return nil, err } @@ -16703,7 +17944,7 @@ func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, syncSourceTest return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/live", pathParam0) + operationPath := fmt.Sprintf("/reports/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16713,36 +17954,66 @@ func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, syncSourceTest return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - if params != nil { + return req, nil +} - if params.Accept != nil { - var headerParam0 string +// NewGetReportRequest generates requests for GetReport +func NewGetReportRequest(server string, reportId openapi_types.UUID) (*http.Request, error) { + var err error - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } + var pathParam0 string - req.Header.Set("Accept", headerParam0) - } + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/reports/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err } return req, nil } -// NewGetSyncSourceTestConnectionLogsQueryRequest generates requests for GetSyncSourceTestConnectionLogsQuery -func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams) (*http.Request, error) { +// NewUpdateReportRequest calls the generic UpdateReport builder with application/json body +func NewUpdateReportRequest(server string, reportId openapi_types.UUID, body UpdateReportJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateReportRequestWithBody(server, reportId, "application/json", bodyReader) +} + +// NewUpdateReportRequestWithBody generates requests for UpdateReport with any type of body +func NewUpdateReportRequestWithBody(server string, reportId openapi_types.UUID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "report_id", runtime.ParamLocationPath, reportId) if err != nil { return nil, err } @@ -16752,7 +18023,7 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, syncSourceTes return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/query", pathParam0) + operationPath := fmt.Sprintf("/reports/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16762,127 +18033,131 @@ func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, syncSourceTes return nil, err } - if params != nil { - queryValues := queryURL.Query() + req, err := http.NewRequest("PUT", queryURL.String(), body) + if err != nil { + return nil, err + } - if params.Filters != nil { + req.Header.Add("Content-Type", contentType) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + return req, nil +} - } +// NewGetSettingsRequest generates requests for GetSettings +func NewGetSettingsRequest(server string) (*http.Request, error) { + var err error - if params.PerPage != nil { + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + operationPath := fmt.Sprintf("/settings") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - } + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - if params.Page != nil { + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + return req, nil +} - } +// NewUpdateSettingsRequest calls the generic UpdateSettings builder with application/json body +func NewUpdateSettingsRequest(server string, body UpdateSettingsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSettingsRequestWithBody(server, "application/json", bodyReader) +} - if params.Download != nil { +// NewUpdateSettingsRequestWithBody generates requests for UpdateSettings with any type of body +func NewUpdateSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - } + operationPath := fmt.Sprintf("/settings") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - queryURL.RawQuery = queryValues.Encode() + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } - if params != nil { + req.Header.Add("Content-Type", contentType) - if params.Accept != nil { - var headerParam0 string + return req, nil +} - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +// NewGetDataSettingsRequest generates requests for GetDataSettings +func NewGetDataSettingsRequest(server string) (*http.Request, error) { + var err error - req.Header.Set("Accept", headerParam0) - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/settings/data") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err } return req, nil } -// NewPromoteSyncSourceTestConnectionRequest calls the generic PromoteSyncSourceTestConnection builder with application/json body -func NewPromoteSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { +// NewUpdateDataSettingsRequest calls the generic UpdateDataSettings builder with application/json body +func NewUpdateDataSettingsRequest(server string, body UpdateDataSettingsJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewPromoteSyncSourceTestConnectionRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) + return NewUpdateDataSettingsRequestWithBody(server, "application/json", bodyReader) } -// NewPromoteSyncSourceTestConnectionRequestWithBody generates requests for PromoteSyncSourceTestConnection with any type of body -func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateDataSettingsRequestWithBody generates requests for UpdateDataSettings with any type of body +func NewUpdateDataSettingsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-source-test-connections/%s/promote", pathParam0) + operationPath := fmt.Sprintf("/settings/data") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16892,7 +18167,7 @@ func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, syncSource return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -16902,8 +18177,19 @@ func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, syncSource return req, nil } -// NewListSyncSourcesRequest generates requests for ListSyncSources -func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*http.Request, error) { +// NewCreateSlackConnectionRequest calls the generic CreateSlackConnection builder with application/json body +func NewCreateSlackConnectionRequest(server string, body CreateSlackConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateSlackConnectionRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateSlackConnectionRequestWithBody generates requests for CreateSlackConnection with any type of body +func NewCreateSlackConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -16911,7 +18197,7 @@ func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*h return nil, err } - operationPath := fmt.Sprintf("/sync-sources") + operationPath := fmt.Sprintf("/slack") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -16921,76 +18207,48 @@ func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*h return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - if params.Page != nil { + req.Header.Add("Content-Type", contentType) - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + return req, nil +} - } +// NewListSlackChannelsRequest generates requests for ListSlackChannels +func NewListSlackChannelsRequest(server string, id openapi_types.UUID, params *ListSlackChannelsParams) (*http.Request, error) { + var err error - if params.Filter != nil { + var pathParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "id", runtime.ParamLocationPath, id) + if err != nil { + return nil, err + } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - if params.SyncGenericSortBys != nil { + operationPath := fmt.Sprintf("/slack/%s/channels", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - } + if params != nil { + queryValues := queryURL.Query() - if params.SyncSortDirections != nil { + if params.Name != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "name", runtime.ParamLocationQuery, *params.Name); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17015,23 +18273,27 @@ func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*h return req, nil } -// NewDeleteSyncSourceRequest generates requests for DeleteSyncSource -func NewDeleteSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) +// NewCreateSyncDestinationTestConnectionRequest calls the generic CreateSyncDestinationTestConnection builder with application/json body +func NewCreateSyncDestinationTestConnectionRequest(server string, body CreateSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateSyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateSyncDestinationTestConnectionRequestWithBody generates requests for CreateSyncDestinationTestConnection with any type of body +func NewCreateSyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destination-test-connections") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17041,21 +18303,23 @@ func NewDeleteSyncSourceRequest(server string, syncSourceName SyncSourceName) (* return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetSyncSourceRequest generates requests for GetSyncSource -func NewGetSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { +// NewGetSyncDestinationTestConnectionRequest generates requests for GetSyncDestinationTestConnection +func NewGetSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17065,7 +18329,7 @@ func NewGetSyncSourceRequest(server string, syncSourceName SyncSourceName) (*htt return nil, err } - operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17083,24 +18347,24 @@ func NewGetSyncSourceRequest(server string, syncSourceName SyncSourceName) (*htt return req, nil } -// NewUpdateSyncSourceRequest calls the generic UpdateSyncSource builder with application/json body -func NewUpdateSyncSourceRequest(server string, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncDestinationRequest calls the generic UpdateSyncTestConnectionForSyncDestination builder with application/json body +func NewUpdateSyncTestConnectionForSyncDestinationRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncSourceRequestWithBody(server, syncSourceName, "application/json", bodyReader) + return NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) } -// NewUpdateSyncSourceRequestWithBody generates requests for UpdateSyncSource with any type of body -func NewUpdateSyncSourceRequestWithBody(server string, syncSourceName SyncSourceName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestination with any type of body +func NewUpdateSyncTestConnectionForSyncDestinationRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17110,7 +18374,7 @@ func NewUpdateSyncSourceRequestWithBody(server string, syncSourceName SyncSource return nil, err } - operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17130,13 +18394,13 @@ func NewUpdateSyncSourceRequestWithBody(server string, syncSourceName SyncSource return req, nil } -// NewListSyncSourceSyncsRequest generates requests for ListSyncSourceSyncs -func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams) (*http.Request, error) { +// NewGetSyncDestinationTestConnectionLogsLiveRequest generates requests for GetSyncDestinationTestConnectionLogsLive +func NewGetSyncDestinationTestConnectionLogsLiveRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17146,7 +18410,7 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, return nil, err } - operationPath := fmt.Sprintf("/sync-sources/%s/syncs", pathParam0) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/live", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17156,44 +18420,61 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, return nil, err } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + if params != nil { - queryValues := queryURL.Query() - if params.PerPage != nil { + if params.Accept != nil { + var headerParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } } + req.Header.Set("Accept", headerParam0) } - if params.Page != nil { + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + return req, nil +} - } +// NewGetSyncDestinationTestConnectionLogsQueryRequest generates requests for GetSyncDestinationTestConnectionLogsQuery +func NewGetSyncDestinationTestConnectionLogsQueryRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams) (*http.Request, error) { + var err error - if params.SyncSortBys != nil { + var pathParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/logs/query", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17207,9 +18488,9 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, } - if params.SyncSortDirections != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17223,9 +18504,9 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, } - if params.Filter != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17239,9 +18520,9 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, } - if params.MigrationFilter != nil { + if params.Download != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17263,23 +18544,42 @@ func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, return nil, err } - return req, nil -} + if params != nil { -// NewGetTestConnectionForSyncSourceRequest generates requests for GetTestConnectionForSyncSource -func NewGetTestConnectionForSyncSourceRequest(server string, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { - var err error + if params.Accept != nil { + var headerParam0 string - var pathParam0 string + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) + req.Header.Set("Accept", headerParam0) + } + + } + + return req, nil +} + +// NewPromoteSyncDestinationTestConnectionRequest calls the generic PromoteSyncDestinationTestConnection builder with application/json body +func NewPromoteSyncDestinationTestConnectionRequest(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewPromoteSyncDestinationTestConnectionRequestWithBody(server, syncDestinationTestConnectionID, "application/json", bodyReader) +} - var pathParam1 string +// NewPromoteSyncDestinationTestConnectionRequestWithBody generates requests for PromoteSyncDestinationTestConnection with any type of body +func NewPromoteSyncDestinationTestConnectionRequestWithBody(server string, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -17289,7 +18589,7 @@ func NewGetTestConnectionForSyncSourceRequest(server string, syncSourceName Sync return nil, err } - operationPath := fmt.Sprintf("/sync-sources/%s/test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-destination-test-connections/%s/promote", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17299,16 +18599,18 @@ func NewGetTestConnectionForSyncSourceRequest(server string, syncSourceName Sync return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListSyncTransformersRequest generates requests for ListSyncTransformers -func NewListSyncTransformersRequest(server string, params *ListSyncTransformersParams) (*http.Request, error) { +// NewListSyncDestinationsRequest generates requests for ListSyncDestinations +func NewListSyncDestinationsRequest(server string, params *ListSyncDestinationsParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -17316,7 +18618,7 @@ func NewListSyncTransformersRequest(server string, params *ListSyncTransformersP return nil, err } - operationPath := fmt.Sprintf("/sync-transformers") + operationPath := fmt.Sprintf("/sync-destinations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17420,13 +18722,13 @@ func NewListSyncTransformersRequest(server string, params *ListSyncTransformersP return req, nil } -// NewDeleteSyncTransformerRequest generates requests for DeleteSyncTransformer -func NewDeleteSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { +// NewDeleteSyncDestinationRequest generates requests for DeleteSyncDestination +func NewDeleteSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17436,7 +18738,7 @@ func NewDeleteSyncTransformerRequest(server string, syncTransformerName SyncTran return nil, err } - operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17454,13 +18756,13 @@ func NewDeleteSyncTransformerRequest(server string, syncTransformerName SyncTran return req, nil } -// NewGetSyncTransformerRequest generates requests for GetSyncTransformer -func NewGetSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { +// NewGetSyncDestinationRequest generates requests for GetSyncDestination +func NewGetSyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17470,7 +18772,7 @@ func NewGetSyncTransformerRequest(server string, syncTransformerName SyncTransfo return nil, err } - operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17488,24 +18790,24 @@ func NewGetSyncTransformerRequest(server string, syncTransformerName SyncTransfo return req, nil } -// NewUpdateSyncTransformerRequest calls the generic UpdateSyncTransformer builder with application/json body -func NewUpdateSyncTransformerRequest(server string, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncDestinationRequest calls the generic UpdateSyncDestination builder with application/json body +func NewUpdateSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTransformerRequestWithBody(server, syncTransformerName, "application/json", bodyReader) + return NewUpdateSyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) } -// NewUpdateSyncTransformerRequestWithBody generates requests for UpdateSyncTransformer with any type of body -func NewUpdateSyncTransformerRequestWithBody(server string, syncTransformerName SyncTransformerName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncDestinationRequestWithBody generates requests for UpdateSyncDestination with any type of body +func NewUpdateSyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17515,7 +18817,7 @@ func NewUpdateSyncTransformerRequestWithBody(server string, syncTransformerName return nil, err } - operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17535,13 +18837,13 @@ func NewUpdateSyncTransformerRequestWithBody(server string, syncTransformerName return req, nil } -// NewListSyncTransformerSyncDestinationsRequest generates requests for ListSyncTransformerSyncDestinations -func NewListSyncTransformerSyncDestinationsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams) (*http.Request, error) { +// NewListSyncDestinationSyncsRequest generates requests for ListSyncDestinationSyncs +func NewListSyncDestinationSyncsRequest(server string, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) if err != nil { return nil, err } @@ -17551,7 +18853,7 @@ func NewListSyncTransformerSyncDestinationsRequest(server string, syncTransforme return nil, err } - operationPath := fmt.Sprintf("/sync-transformers/%s/sync-destinations", pathParam0) + operationPath := fmt.Sprintf("/sync-destinations/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17596,49 +18898,41 @@ func NewListSyncTransformerSyncDestinationsRequest(server string, syncTransforme } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if params.SyncSortBys != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewListSyncTransformerSyncsRequest generates requests for ListSyncTransformerSyncs -func NewListSyncTransformerSyncsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.SyncSortDirections != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/sync-transformers/%s/syncs", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.PerPage != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17652,9 +18946,9 @@ func NewListSyncTransformerSyncsRequest(server string, syncTransformerName SyncT } - if params.Page != nil { + if params.MigrationFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17679,16 +18973,185 @@ func NewListSyncTransformerSyncsRequest(server string, syncTransformerName SyncT return req, nil } -// NewListSyncUpgradesRequest generates requests for ListSyncUpgrades -func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) (*http.Request, error) { +// NewGetTestConnectionForSyncDestinationRequest generates requests for GetTestConnectionForSyncDestination +func NewGetTestConnectionForSyncDestinationRequest(server string, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/sync-upgrades") + operationPath := fmt.Sprintf("/sync-destinations/%s/test-connections/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewCreateSyncSourceTestConnectionRequest calls the generic CreateSyncSourceTestConnection builder with application/json body +func NewCreateSyncSourceTestConnectionRequest(server string, body CreateSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateSyncSourceTestConnectionRequestWithBody(server, "application/json", bodyReader) +} + +// NewCreateSyncSourceTestConnectionRequestWithBody generates requests for CreateSyncSourceTestConnection with any type of body +func NewCreateSyncSourceTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSyncSourceTestConnectionRequest generates requests for GetSyncSourceTestConnection +func NewGetSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewUpdateSyncTestConnectionForSyncSourceRequest calls the generic UpdateSyncTestConnectionForSyncSource builder with application/json body +func NewUpdateSyncTestConnectionForSyncSourceRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) +} + +// NewUpdateSyncTestConnectionForSyncSourceRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSource with any type of body +func NewUpdateSyncTestConnectionForSyncSourceRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSyncSourceTestConnectionLogsLiveRequest generates requests for GetSyncSourceTestConnectionLogsLive +func NewGetSyncSourceTestConnectionLogsLiveRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/live", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17698,44 +19161,61 @@ func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) ( return nil, err } + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + if params != nil { - queryValues := queryURL.Query() - if params.PerPage != nil { + if params.Accept != nil { + var headerParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } } + req.Header.Set("Accept", headerParam0) } - if params.Page != nil { + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + return req, nil +} - } +// NewGetSyncSourceTestConnectionLogsQueryRequest generates requests for GetSyncSourceTestConnectionLogsQuery +func NewGetSyncSourceTestConnectionLogsQueryRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams) (*http.Request, error) { + var err error - if params.SyncUpgradesSortBys != nil { + var pathParam0 string - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncUpgradesSortBys); err != nil { + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/logs/query", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17749,9 +19229,9 @@ func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) ( } - if params.SyncSortDirections != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17765,9 +19245,9 @@ func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) ( } - if params.Path != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "path", runtime.ParamLocationQuery, *params.Path); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17781,9 +19261,9 @@ func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) ( } - if params.Kind != nil { + if params.Download != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "kind", runtime.ParamLocationQuery, *params.Kind); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17797,35 +19277,81 @@ func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) ( } - if params.PlatformVersion != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "platform_version", runtime.ParamLocationQuery, *params.PlatformVersion); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } } + req.Header.Set("Accept", headerParam0) } - queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("GET", queryURL.String(), nil) + return req, nil +} + +// NewPromoteSyncSourceTestConnectionRequest calls the generic PromoteSyncSourceTestConnection builder with application/json body +func NewPromoteSyncSourceTestConnectionRequest(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPromoteSyncSourceTestConnectionRequestWithBody(server, syncSourceTestConnectionID, "application/json", bodyReader) +} + +// NewPromoteSyncSourceTestConnectionRequestWithBody generates requests for PromoteSyncSourceTestConnection with any type of body +func NewPromoteSyncSourceTestConnectionRequestWithBody(server string, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + if err != nil { + return nil, err + } + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/sync-source-test-connections/%s/promote", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewListSyncsRequest generates requests for ListSyncs -func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, error) { +// NewListSyncSourcesRequest generates requests for ListSyncSources +func NewListSyncSourcesRequest(server string, params *ListSyncSourcesParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -17833,7 +19359,7 @@ func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, return nil, err } - operationPath := fmt.Sprintf("/syncs") + operationPath := fmt.Sprintf("/sync-sources") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -17878,25 +19404,9 @@ func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, } - if params.SyncSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17910,9 +19420,9 @@ func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, } - if params.Filter != nil { + if params.SyncGenericSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17926,9 +19436,9 @@ func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, } - if params.MigrationFilter != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -17953,53 +19463,13 @@ func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, return req, nil } -// NewCreateSyncRequest calls the generic CreateSync builder with application/json body -func NewCreateSyncRequest(server string, body CreateSyncJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateSyncRequestWithBody generates requests for CreateSync with any type of body -func NewCreateSyncRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/syncs") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteSyncRequest generates requests for DeleteSync -func NewDeleteSyncRequest(server string, syncName SyncName) (*http.Request, error) { +// NewDeleteSyncSourceRequest generates requests for DeleteSyncSource +func NewDeleteSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18009,7 +19479,7 @@ func NewDeleteSyncRequest(server string, syncName SyncName) (*http.Request, erro return nil, err } - operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18027,13 +19497,13 @@ func NewDeleteSyncRequest(server string, syncName SyncName) (*http.Request, erro return req, nil } -// NewGetSyncRequest generates requests for GetSync -func NewGetSyncRequest(server string, syncName SyncName) (*http.Request, error) { +// NewGetSyncSourceRequest generates requests for GetSyncSource +func NewGetSyncSourceRequest(server string, syncSourceName SyncSourceName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18043,7 +19513,7 @@ func NewGetSyncRequest(server string, syncName SyncName) (*http.Request, error) return nil, err } - operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18061,24 +19531,24 @@ func NewGetSyncRequest(server string, syncName SyncName) (*http.Request, error) return req, nil } -// NewUpdateSyncRequest calls the generic UpdateSync builder with application/json body -func NewUpdateSyncRequest(server string, syncName SyncName, body UpdateSyncJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncSourceRequest calls the generic UpdateSyncSource builder with application/json body +func NewUpdateSyncSourceRequest(server string, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncRequestWithBody(server, syncName, "application/json", bodyReader) + return NewUpdateSyncSourceRequestWithBody(server, syncSourceName, "application/json", bodyReader) } -// NewUpdateSyncRequestWithBody generates requests for UpdateSync with any type of body -func NewUpdateSyncRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncSourceRequestWithBody generates requests for UpdateSyncSource with any type of body +func NewUpdateSyncSourceRequestWithBody(server string, syncSourceName SyncSourceName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18088,7 +19558,7 @@ func NewUpdateSyncRequestWithBody(server string, syncName SyncName, contentType return nil, err } - operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18108,13 +19578,13 @@ func NewUpdateSyncRequestWithBody(server string, syncName SyncName, contentType return req, nil } -// NewListSyncRunsRequest generates requests for ListSyncRuns -func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRunsParams) (*http.Request, error) { +// NewListSyncSourceSyncsRequest generates requests for ListSyncSourceSyncs +func NewListSyncSourceSyncsRequest(server string, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } @@ -18124,7 +19594,7 @@ func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRu return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) + operationPath := fmt.Sprintf("/sync-sources/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18137,9 +19607,9 @@ func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRu if params != nil { queryValues := queryURL.Query() - if params.MigrationFilter != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18153,9 +19623,9 @@ func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRu } - if params.PerPage != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18169,9 +19639,9 @@ func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRu } - if params.Page != nil { + if params.SyncSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18185,82 +19655,55 @@ func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRu } - queryURL.RawQuery = queryValues.Encode() - } + if params.SyncSortDirections != nil { - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - return req, nil -} + } -// NewCreateSyncRunRequest generates requests for CreateSyncRun -func NewCreateSyncRunRequest(server string, syncName SyncName) (*http.Request, error) { - var err error + if params.Filter != nil { - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewGetSyncRunRequest generates requests for GetSyncRun -func NewGetSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - var pathParam1 string + } - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } + if params.MigrationFilter != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + queryURL.RawQuery = queryValues.Encode() } req, err := http.NewRequest("GET", queryURL.String(), nil) @@ -18271,31 +19714,20 @@ func NewGetSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId) return req, nil } -// NewUpdateSyncRunRequest calls the generic UpdateSyncRun builder with application/json body -func NewUpdateSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSyncRunRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) -} - -// NewUpdateSyncRunRequestWithBody generates requests for UpdateSyncRun with any type of body -func NewUpdateSyncRunRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { +// NewGetTestConnectionForSyncSourceRequest generates requests for GetTestConnectionForSyncSource +func NewGetTestConnectionForSyncSourceRequest(server string, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_source_name", runtime.ParamLocationPath, syncSourceName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_test_connection_id", runtime.ParamLocationPath, syncTestConnectionId) if err != nil { return nil, err } @@ -18305,7 +19737,7 @@ func NewUpdateSyncRunRequestWithBody(server string, syncName SyncName, syncRunId return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-sources/%s/test-connections/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18315,40 +19747,24 @@ func NewUpdateSyncRunRequestWithBody(server string, syncName SyncName, syncRunId return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetSyncRunLogsLiveRequest generates requests for GetSyncRunLogsLive -func NewGetSyncRunLogsLiveRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams) (*http.Request, error) { +// NewListSyncTransformersRequest generates requests for ListSyncTransformers +func NewListSyncTransformersRequest(server string, params *ListSyncTransformersParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/live", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18361,9 +19777,9 @@ func NewGetSyncRunLogsLiveRequest(server string, syncName SyncName, syncRunId Sy if params != nil { queryValues := queryURL.Query() - if params.Table != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18377,71 +19793,9 @@ func NewGetSyncRunLogsLiveRequest(server string, syncName SyncName, syncRunId Sy } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - if params != nil { - - if params.Accept != nil { - var headerParam0 string - - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } - - req.Header.Set("Accept", headerParam0) - } - - } - - return req, nil -} - -// NewGetSyncRunLogsQueryRequest generates requests for GetSyncRunLogsQuery -func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/query", pathParam0, pathParam1) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Filters != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18455,9 +19809,9 @@ func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId S } - if params.PerPage != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18471,9 +19825,9 @@ func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId S } - if params.Page != nil { + if params.SyncGenericSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18487,9 +19841,9 @@ func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId S } - if params.Download != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18511,49 +19865,50 @@ func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId S return nil, err } - if params != nil { - - if params.Accept != nil { - var headerParam0 string + return req, nil +} - headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) - if err != nil { - return nil, err - } +// NewDeleteSyncTransformerRequest generates requests for DeleteSyncTransformer +func NewDeleteSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { + var err error - req.Header.Set("Accept", headerParam0) - } + var pathParam0 string + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + if err != nil { + return nil, err } - return req, nil -} - -// NewCreateSyncRunProgressRequest calls the generic CreateSyncRunProgress builder with application/json body -func NewCreateSyncRunProgressRequest(server string, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncRunProgressRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) -} -// NewCreateSyncRunProgressRequestWithBody generates requests for CreateSyncRunProgress with any type of body -func NewCreateSyncRunProgressRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { - var err error + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - var pathParam0 string + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } - var pathParam1 string + return req, nil +} - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) +// NewGetSyncTransformerRequest generates requests for GetSyncTransformer +func NewGetSyncTransformerRequest(server string, syncTransformerName SyncTransformerName) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -18563,7 +19918,7 @@ func NewCreateSyncRunProgressRequestWithBody(server string, syncName SyncName, s return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s/progress", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18573,30 +19928,32 @@ func NewCreateSyncRunProgressRequestWithBody(server string, syncName SyncName, s return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetSyncRunStatsRequest generates requests for GetSyncRunStats -func NewGetSyncRunStatsRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) +// NewUpdateSyncTransformerRequest calls the generic UpdateSyncTransformer builder with application/json body +func NewUpdateSyncTransformerRequest(server string, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTransformerRequestWithBody(server, syncTransformerName, "application/json", bodyReader) +} - var pathParam1 string +// NewUpdateSyncTransformerRequestWithBody generates requests for UpdateSyncTransformer with any type of body +func NewUpdateSyncTransformerRequestWithBody(server string, syncTransformerName SyncTransformerName, contentType string, body io.Reader) (*http.Request, error) { + var err error - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -18606,7 +19963,7 @@ func NewGetSyncRunStatsRequest(server string, syncName SyncName, syncRunId SyncR return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s/stats", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18616,28 +19973,23 @@ func NewGetSyncRunStatsRequest(server string, syncName SyncName, syncRunId SyncR return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewGetSyncRunTablesRequest generates requests for GetSyncRunTables -func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams) (*http.Request, error) { +// NewListSyncTransformerSyncDestinationsRequest generates requests for ListSyncTransformerSyncDestinations +func NewListSyncTransformerSyncDestinationsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) if err != nil { return nil, err } @@ -18647,7 +19999,7 @@ func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId Sync return nil, err } - operationPath := fmt.Sprintf("/syncs/%s/runs/%s/tables", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/sync-transformers/%s/sync-destinations", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18692,38 +20044,6 @@ func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId Sync } - if params.SyncRunTableSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncRunTableSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - queryURL.RawQuery = queryValues.Encode() } @@ -18735,16 +20055,23 @@ func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId Sync return req, nil } -// NewListTablesRequest generates requests for ListTables -func NewListTablesRequest(server string, params *ListTablesParams) (*http.Request, error) { +// NewListSyncTransformerSyncsRequest generates requests for ListSyncTransformerSyncs +func NewListSyncTransformerSyncsRequest(server string, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_transformer_name", runtime.ParamLocationPath, syncTransformerName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/tables") + operationPath := fmt.Sprintf("/sync-transformers/%s/syncs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18800,8 +20127,8 @@ func NewListTablesRequest(server string, params *ListTablesParams) (*http.Reques return req, nil } -// NewGetTablesDataRequest generates requests for GetTablesData -func NewGetTablesDataRequest(server string, params *GetTablesDataParams) (*http.Request, error) { +// NewListSyncUpgradesRequest generates requests for ListSyncUpgrades +func NewListSyncUpgradesRequest(server string, params *ListSyncUpgradesParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -18809,7 +20136,7 @@ func NewGetTablesDataRequest(server string, params *GetTablesDataParams) (*http. return nil, err } - operationPath := fmt.Sprintf("/tables/data") + operationPath := fmt.Sprintf("/sync-upgrades") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -18854,134 +20181,25 @@ func NewGetTablesDataRequest(server string, params *GetTablesDataParams) (*http. } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTablesDataActionRequest calls the generic TablesDataAction builder with application/json body -func NewTablesDataActionRequest(server string, body TablesDataActionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewTablesDataActionRequestWithBody(server, "application/json", bodyReader) -} - -// NewTablesDataActionRequestWithBody generates requests for TablesDataAction with any type of body -func NewTablesDataActionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/tables/data") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewBatchTableSchemasRequest generates requests for BatchTableSchemas -func NewBatchTableSchemasRequest(server string, params *BatchTableSchemasParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/tables/schemas") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() + if params.SyncUpgradesSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tables", runtime.ParamLocationQuery, params.Tables); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncUpgradesSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } } } - } - - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableListColumnsRequest generates requests for TableListColumns -func NewTableListColumnsRequest(server string, tableName TableName, params *TableListColumnsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/tables/%s/columns", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - if params != nil { - queryValues := queryURL.Query() + } - if params.FilterMode != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -18995,9 +20213,9 @@ func NewTableListColumnsRequest(server string, tableName TableName, params *Tabl } - if params.Filter != nil { + if params.Path != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "path", runtime.ParamLocationQuery, *params.Path); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19011,9 +20229,9 @@ func NewTableListColumnsRequest(server string, tableName TableName, params *Tabl } - if params.Page != nil { + if params.Kind != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "kind", runtime.ParamLocationQuery, *params.Kind); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19027,9 +20245,9 @@ func NewTableListColumnsRequest(server string, tableName TableName, params *Tabl } - if params.PerPage != nil { + if params.PlatformVersion != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "platform_version", runtime.ParamLocationQuery, *params.PlatformVersion); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19054,30 +20272,16 @@ func NewTableListColumnsRequest(server string, tableName TableName, params *Tabl return req, nil } -// NewTableColumnListValuesRequest generates requests for TableColumnListValues -func NewTableColumnListValuesRequest(server string, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams) (*http.Request, error) { +// NewListSyncsRequest generates requests for ListSyncs +func NewListSyncsRequest(server string, params *ListSyncsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "column_name", runtime.ParamLocationPath, columnName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/tables/%s/columns/%s/values", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19090,54 +20294,6 @@ func NewTableColumnListValuesRequest(server string, tableName TableName, columnN if params != nil { queryValues := queryURL.Query() - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -19154,113 +20310,9 @@ func NewTableColumnListValuesRequest(server string, tableName TableName, columnN } - queryURL.RawQuery = queryValues.Encode() - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewTableListRowsRequest generates requests for TableListRows -func NewTableListRowsRequest(server string, tableName TableName, params *TableListRowsParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/tables/%s/data", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - if params != nil { - queryValues := queryURL.Query() - - if params.Selects != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Filters != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterIDs != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SortBys != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19274,9 +20326,9 @@ func NewTableListRowsRequest(server string, tableName TableName, params *TableLi } - if params.SortDirections != nil { + if params.SyncSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19290,9 +20342,9 @@ func NewTableListRowsRequest(server string, tableName TableName, params *TableLi } - if params.GroupBys != nil { + if params.SyncSortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19306,9 +20358,9 @@ func NewTableListRowsRequest(server string, tableName TableName, params *TableLi } - if params.PerPage != nil { + if params.Filter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19322,9 +20374,9 @@ func NewTableListRowsRequest(server string, tableName TableName, params *TableLi } - if params.Page != nil { + if params.MigrationFilter != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -19349,30 +20401,27 @@ func NewTableListRowsRequest(server string, tableName TableName, params *TableLi return req, nil } -// NewTableRowByIdRequest generates requests for TableRowById -func NewTableRowByIdRequest(server string, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) +// NewCreateSyncRequest calls the generic CreateSync builder with application/json body +func NewCreateSyncRequest(server string, body CreateSyncJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) if err != nil { return nil, err } + bodyReader = bytes.NewReader(buf) + return NewCreateSyncRequestWithBody(server, "application/json", bodyReader) +} - var pathParam1 string - - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_row_id", runtime.ParamLocationPath, tableRowId) - if err != nil { - return nil, err - } +// NewCreateSyncRequestWithBody generates requests for CreateSync with any type of body +func NewCreateSyncRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/tables/%s/data/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19382,61 +20431,43 @@ func NewTableRowByIdRequest(server string, tableName TableName, tableRowId Table return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.FilterMode != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - } + req.Header.Add("Content-Type", contentType) - if params.Filters != nil { + return req, nil +} - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } +// NewDeleteSyncRequest generates requests for DeleteSync +func NewDeleteSyncRequest(server string, syncName SyncName) (*http.Request, error) { + var err error - } + var pathParam0 string - if params.FilterIDs != nil { + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - } + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - queryURL.RawQuery = queryValues.Encode() + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) if err != nil { return nil, err } @@ -19444,13 +20475,13 @@ func NewTableRowByIdRequest(server string, tableName TableName, tableRowId Table return req, nil } -// NewTableListFiltersRequest generates requests for TableListFilters -func NewTableListFiltersRequest(server string, tableName TableName, params *TableListFiltersParams) (*http.Request, error) { +// NewGetSyncRequest generates requests for GetSync +func NewGetSyncRequest(server string, syncName SyncName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19460,7 +20491,7 @@ func NewTableListFiltersRequest(server string, tableName TableName, params *Tabl return nil, err } - operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19470,60 +20501,6 @@ func NewTableListFiltersRequest(server string, tableName TableName, params *Tabl return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.FilterTags != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -19532,24 +20509,24 @@ func NewTableListFiltersRequest(server string, tableName TableName, params *Tabl return req, nil } -// NewTableSaveFilterRequest calls the generic TableSaveFilter builder with application/json body -func NewTableSaveFilterRequest(server string, tableName TableName, body TableSaveFilterJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncRequest calls the generic UpdateSync builder with application/json body +func NewUpdateSyncRequest(server string, syncName SyncName, body UpdateSyncJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewTableSaveFilterRequestWithBody(server, tableName, "application/json", bodyReader) + return NewUpdateSyncRequestWithBody(server, syncName, "application/json", bodyReader) } -// NewTableSaveFilterRequestWithBody generates requests for TableSaveFilter with any type of body -func NewTableSaveFilterRequestWithBody(server string, tableName TableName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncRequestWithBody generates requests for UpdateSync with any type of body +func NewUpdateSyncRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19559,7 +20536,7 @@ func NewTableSaveFilterRequestWithBody(server string, tableName TableName, conte return nil, err } - operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) + operationPath := fmt.Sprintf("/syncs/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19569,7 +20546,7 @@ func NewTableSaveFilterRequestWithBody(server string, tableName TableName, conte return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } @@ -19579,13 +20556,13 @@ func NewTableSaveFilterRequestWithBody(server string, tableName TableName, conte return req, nil } -// NewTableListFilterTagsRequest generates requests for TableListFilterTags -func NewTableListFilterTagsRequest(server string, tableName TableName, params *TableListFilterTagsParams) (*http.Request, error) { +// NewListSyncRunsRequest generates requests for ListSyncRuns +func NewListSyncRunsRequest(server string, syncName SyncName, params *ListSyncRunsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19595,7 +20572,7 @@ func NewTableListFilterTagsRequest(server string, tableName TableName, params *T return nil, err } - operationPath := fmt.Sprintf("/tables/%s/filters/tags", pathParam0) + operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19608,6 +20585,22 @@ func NewTableListFilterTagsRequest(server string, tableName TableName, params *T if params != nil { queryValues := queryURL.Query() + if params.MigrationFilter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "migration_filter", runtime.ParamLocationQuery, *params.MigrationFilter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + if params.PerPage != nil { if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { @@ -19651,13 +20644,13 @@ func NewTableListFilterTagsRequest(server string, tableName TableName, params *T return req, nil } -// NewTableSchemaRequest generates requests for TableSchema -func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, error) { +// NewCreateSyncRunRequest generates requests for CreateSyncRun +func NewCreateSyncRunRequest(server string, syncName SyncName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } @@ -19667,7 +20660,7 @@ func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, e return nil, err } - operationPath := fmt.Sprintf("/tables/%s/schema", pathParam0) + operationPath := fmt.Sprintf("/syncs/%s/runs", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19677,7 +20670,7 @@ func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, e return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("POST", queryURL.String(), nil) if err != nil { return nil, err } @@ -19685,16 +20678,30 @@ func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, e return req, nil } -// NewListTeamsRequest generates requests for ListTeams -func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, error) { +// NewGetSyncRunRequest generates requests for GetSyncRun +func NewGetSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/teams") + operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19704,44 +20711,6 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, return nil, err } - if params != nil { - queryValues := queryURL.Query() - - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - queryURL.RawQuery = queryValues.Encode() - } - req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -19750,48 +20719,74 @@ func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, return req, nil } -// NewDownloadPluginAssetByTeamRequest generates requests for DownloadPluginAssetByTeam -func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams) (*http.Request, error) { +// NewUpdateSyncRunRequest calls the generic UpdateSyncRun builder with application/json body +func NewUpdateSyncRunRequest(server string, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncRunRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) +} + +// NewUpdateSyncRunRequestWithBody generates requests for UpdateSyncRun with any type of body +func NewUpdateSyncRunRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_team", runtime.ParamLocationPath, pluginTeam) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - var pathParam3 string + operationPath := fmt.Sprintf("/syncs/%s/runs/%s", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - pathParam3, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - var pathParam4 string + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } - pathParam4, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSyncRunLogsLiveRequest generates requests for GetSyncRunLogsLive +func NewGetSyncRunLogsLiveRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } - var pathParam5 string + var pathParam1 string - pathParam5, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19801,7 +20796,7 @@ func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, plugi return nil, err } - operationPath := fmt.Sprintf("/teams/%s/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4, pathParam5) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/live", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19811,6 +20806,28 @@ func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, plugi return nil, err } + if params != nil { + queryValues := queryURL.Query() + + if params.Table != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "table", runtime.ParamLocationQuery, *params.Table); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err @@ -19834,31 +20851,20 @@ func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, plugi return req, nil } -// NewUpdateSyncTestConnectionForSyncDestinationTeamRequest calls the generic UpdateSyncTestConnectionForSyncDestinationTeam builder with application/json body -func NewUpdateSyncTestConnectionForSyncDestinationTeamRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server, teamName, syncDestinationTestConnectionID, "application/json", bodyReader) -} - -// NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestinationTeam with any type of body -func NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewGetSyncRunLogsQueryRequest generates requests for GetSyncRunLogsQuery +func NewGetSyncRunLogsQueryRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19868,7 +20874,7 @@ func NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server str return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/logs/query", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19878,41 +20884,124 @@ func NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server str return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Download != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "download", runtime.ParamLocationQuery, *params.Download); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } return req, nil } -// NewUpdateSyncTestConnectionForSyncSourceTeamRequest calls the generic UpdateSyncTestConnectionForSyncSourceTeam builder with application/json body -func NewUpdateSyncTestConnectionForSyncSourceTeamRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody) (*http.Request, error) { +// NewCreateSyncRunProgressRequest calls the generic CreateSyncRunProgress builder with application/json body +func NewCreateSyncRunProgressRequest(server string, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server, teamName, syncSourceTestConnectionID, "application/json", bodyReader) + return NewCreateSyncRunProgressRequestWithBody(server, syncName, syncRunId, "application/json", bodyReader) } -// NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSourceTeam with any type of body -func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateSyncRunProgressRequestWithBody generates requests for CreateSyncRunProgress with any type of body +func NewCreateSyncRunProgressRequestWithBody(server string, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19922,7 +21011,7 @@ func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, return nil, err } - operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s", pathParam0, pathParam1) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/progress", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19932,7 +21021,7 @@ func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -19942,38 +21031,20 @@ func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, return req, nil } -// NewCreateSyncRunProgressTeamRequest calls the generic CreateSyncRunProgressTeam builder with application/json body -func NewCreateSyncRunProgressTeamRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateSyncRunProgressTeamRequestWithBody(server, teamName, syncName, syncRunId, "application/json", bodyReader) -} - -// NewCreateSyncRunProgressTeamRequestWithBody generates requests for CreateSyncRunProgressTeam with any type of body -func NewCreateSyncRunProgressTeamRequestWithBody(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { +// NewGetSyncRunStatsRequest generates requests for GetSyncRunStats +func NewGetSyncRunStatsRequest(server string, syncName SyncName, syncRunId SyncRunId) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) if err != nil { return nil, err } var pathParam1 string - pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - - var pathParam2 string - - pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) if err != nil { return nil, err } @@ -19983,7 +21054,7 @@ func NewCreateSyncRunProgressTeamRequestWithBody(server string, teamName TeamNam return nil, err } - operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/progress", pathParam0, pathParam1, pathParam2) + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/stats", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -19993,26 +21064,38 @@ func NewCreateSyncRunProgressTeamRequestWithBody(server string, teamName TeamNam return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewGetTeamUsageSummaryRequest generates requests for GetTeamUsageSummary -func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryParams) (*http.Request, error) { +// NewGetSyncRunTablesRequest generates requests for GetSyncRunTables +func NewGetSyncRunTablesRequest(server string, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/usage-summary") + operationPath := fmt.Sprintf("/syncs/%s/runs/%s/tables", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20025,9 +21108,9 @@ func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryPar if params != nil { queryValues := queryURL.Query() - if params.Metrics != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20041,9 +21124,9 @@ func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryPar } - if params.Start != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20057,9 +21140,9 @@ func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryPar } - if params.End != nil { + if params.SyncRunTableSortBys != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncRunTableSortBys); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20073,9 +21156,9 @@ func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryPar } - if params.AggregationPeriod != nil { + if params.SortDirections != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20100,23 +21183,16 @@ func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryPar return req, nil } -// NewGetGroupedTeamUsageSummaryRequest generates requests for GetGroupedTeamUsageSummary -func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams) (*http.Request, error) { +// NewListTablesRequest generates requests for ListTables +func NewListTablesRequest(server string, params *ListTablesParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "group_by", runtime.ParamLocationPath, groupBy) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/usage-summary/%s", pathParam0) + operationPath := fmt.Sprintf("/tables") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20129,9 +21205,9 @@ func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamU if params != nil { queryValues := queryURL.Query() - if params.Metrics != nil { + if params.PerPage != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20145,9 +21221,9 @@ func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamU } - if params.Start != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20161,9 +21237,42 @@ func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamU } - if params.End != nil { + queryURL.RawQuery = queryValues.Encode() + } - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetTablesDataRequest generates requests for GetTablesData +func NewGetTablesDataRequest(server string, params *GetTablesDataParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tables/data") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20177,9 +21286,9 @@ func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamU } - if params.AggregationPeriod != nil { + if params.Page != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20204,46 +21313,19 @@ func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamU return req, nil } -// NewGetCurrentUserRequest generates requests for GetCurrentUser -func NewGetCurrentUserRequest(server string) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("GET", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewUpdateCurrentUserRequest calls the generic UpdateCurrentUser builder with application/json body -func NewUpdateCurrentUserRequest(server string, body UpdateCurrentUserJSONRequestBody) (*http.Request, error) { +// NewTablesDataActionRequest calls the generic TablesDataAction builder with application/json body +func NewTablesDataActionRequest(server string, body TablesDataActionJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateCurrentUserRequestWithBody(server, "application/json", bodyReader) + return NewTablesDataActionRequestWithBody(server, "application/json", bodyReader) } -// NewUpdateCurrentUserRequestWithBody generates requests for UpdateCurrentUser with any type of body -func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewTablesDataActionRequestWithBody generates requests for TablesDataAction with any type of body +func NewTablesDataActionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -20251,7 +21333,7 @@ func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body return nil, err } - operationPath := fmt.Sprintf("/user") + operationPath := fmt.Sprintf("/tables/data") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20261,7 +21343,7 @@ func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + req, err := http.NewRequest("POST", queryURL.String(), body) if err != nil { return nil, err } @@ -20271,19 +21353,8 @@ func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body return req, nil } -// NewSendAnonymousEventRequest calls the generic SendAnonymousEvent builder with application/json body -func NewSendAnonymousEventRequest(server string, body SendAnonymousEventJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewSendAnonymousEventRequestWithBody(server, "application/json", bodyReader) -} - -// NewSendAnonymousEventRequestWithBody generates requests for SendAnonymousEvent with any type of body -func NewSendAnonymousEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewGetTablesRelationsRequest generates requests for GetTablesRelations +func NewGetTablesRelationsRequest(server string) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -20291,7 +21362,7 @@ func NewSendAnonymousEventRequestWithBody(server string, contentType string, bod return nil, err } - operationPath := fmt.Sprintf("/user/anon-event") + operationPath := fmt.Sprintf("/tables/relations") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20301,29 +21372,16 @@ func NewSendAnonymousEventRequestWithBody(server string, contentType string, bod return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewAuthenticateUserRequest calls the generic AuthenticateUser builder with application/json body -func NewAuthenticateUserRequest(server string, body AuthenticateUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewAuthenticateUserRequestWithBody(server, "application/json", bodyReader) -} - -// NewAuthenticateUserRequestWithBody generates requests for AuthenticateUser with any type of body -func NewAuthenticateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewBatchTableSchemasRequest generates requests for BatchTableSchemas +func NewBatchTableSchemasRequest(server string, params *BatchTableSchemasParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -20331,7 +21389,7 @@ func NewAuthenticateUserRequestWithBody(server string, contentType string, body return nil, err } - operationPath := fmt.Sprintf("/user/authenticate") + operationPath := fmt.Sprintf("/tables/schemas") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20341,37 +21399,49 @@ func NewAuthenticateUserRequestWithBody(server string, contentType string, body return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + if params != nil { + queryValues := queryURL.Query() + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tables", runtime.ParamLocationQuery, params.Tables); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - return req, nil } -// NewChangeUserPasswordRequest calls the generic ChangeUserPassword builder with application/json body -func NewChangeUserPasswordRequest(server string, body ChangeUserPasswordJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewTableListColumnsRequest generates requests for TableListColumns +func NewTableListColumnsRequest(server string, tableName TableName, params *TableListColumnsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewChangeUserPasswordRequestWithBody(server, "application/json", bodyReader) -} - -// NewChangeUserPasswordRequestWithBody generates requests for ChangeUserPassword with any type of body -func NewChangeUserPasswordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/user/change-password") + operationPath := fmt.Sprintf("/tables/%s/columns", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20381,116 +21451,188 @@ func NewChangeUserPasswordRequestWithBody(server string, contentType string, bod return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.FilterMode != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUpdateCustomerRequest calls the generic UpdateCustomer builder with application/json body -func NewUpdateCustomerRequest(server string, body UpdateCustomerJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + } + + if params.Filter != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUpdateCustomerRequestWithBody(server, "application/json", bodyReader) + + return req, nil } -// NewUpdateCustomerRequestWithBody generates requests for UpdateCustomer with any type of body -func NewUpdateCustomerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewTableColumnListValuesRequest generates requests for TableColumnListValues +func NewTableColumnListValuesRequest(server string, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams) (*http.Request, error) { var err error - serverURL, err := url.Parse(server) + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/user/customer") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + var pathParam1 string - queryURL, err := serverURL.Parse(operationPath) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "column_name", runtime.ParamLocationPath, columnName) if err != nil { return nil, err } - req, err := http.NewRequest("PATCH", queryURL.String(), body) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - - return req, nil -} + operationPath := fmt.Sprintf("/tables/%s/columns/%s/values", pathParam0, pathParam1) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } -// NewSendUserEventRequest calls the generic SendUserEvent builder with application/json body -func NewSendUserEventRequest(server string, body SendUserEventJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + queryURL, err := serverURL.Parse(operationPath) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewSendUserEventRequestWithBody(server, "application/json", bodyReader) -} -// NewSendUserEventRequestWithBody generates requests for SendUserEvent with any type of body -func NewSendUserEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error + if params != nil { + queryValues := queryURL.Query() - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.FilterMode != nil { - operationPath := fmt.Sprintf("/user/event") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params.Filter != nil { - req.Header.Add("Content-Type", contentType) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - return req, nil -} + } -// NewLogoutUserRequest generates requests for LogoutUser -func NewLogoutUserRequest(server string) (*http.Request, error) { - var err error + if params.Page != nil { - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - operationPath := fmt.Sprintf("/user/login") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -20498,27 +21640,23 @@ func NewLogoutUserRequest(server string) (*http.Request, error) { return req, nil } -// NewLoginUserRequest calls the generic LoginUser builder with application/json body -func NewLoginUserRequest(server string, body LoginUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewTableListRowsRequest generates requests for TableListRows +func NewTableListRowsRequest(server string, tableName TableName, params *TableListRowsParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewLoginUserRequestWithBody(server, "application/json", bodyReader) -} - -// NewLoginUserRequestWithBody generates requests for LoginUser with any type of body -func NewLoginUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/user/login") + operationPath := fmt.Sprintf("/tables/%s/data", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20528,36 +21666,157 @@ func NewLoginUserRequestWithBody(server string, contentType string, body io.Read return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.Selects != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "select", runtime.ParamLocationQuery, params.Selects); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewUserTOTPDeleteRequest generates requests for UserTOTPDelete -func NewUserTOTPDeleteRequest(server string) (*http.Request, error) { - var err error + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + if params.FilterMode != nil { - operationPath := fmt.Sprintf("/user/totp") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err + } + + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.FilterIDs != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.SortDirections != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.GroupBys != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "group_by", runtime.ParamLocationQuery, params.GroupBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -20565,54 +21824,30 @@ func NewUserTOTPDeleteRequest(server string) (*http.Request, error) { return req, nil } -// NewUserTOTPSetupRequest generates requests for UserTOTPSetup -func NewUserTOTPSetupRequest(server string) (*http.Request, error) { +// NewTableRowByIdRequest generates requests for TableRowById +func NewTableRowByIdRequest(server string, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams) (*http.Request, error) { var err error - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/user/totp") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + var pathParam0 string - req, err := http.NewRequest("POST", queryURL.String(), nil) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } - return req, nil -} + var pathParam1 string -// NewUserTOTPVerifyRequest calls the generic UserTOTPVerify builder with application/json body -func NewUserTOTPVerifyRequest(server string, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "table_row_id", runtime.ParamLocationPath, tableRowId) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewUserTOTPVerifyRequestWithBody(server, params, "application/json", bodyReader) -} - -// NewUserTOTPVerifyRequestWithBody generates requests for UserTOTPVerify with any type of body -func NewUserTOTPVerifyRequestWithBody(server string, params *UserTOTPVerifyParams, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/user/totp/verify") + operationPath := fmt.Sprintf("/tables/%s/data/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20622,43 +21857,85 @@ func NewUserTOTPVerifyRequestWithBody(server string, params *UserTOTPVerifyParam return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.FilterMode != nil { - if params != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_mode", runtime.ParamLocationQuery, *params.FilterMode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params.CqpSess != nil { - var cookieParam0 string + } - cookieParam0, err = runtime.StyleParamWithLocation("simple", true, "__cqp_sess", runtime.ParamLocationCookie, *params.CqpSess) - if err != nil { + if params.Filters != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, params.Filters); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } } - cookie0 := &http.Cookie{ - Name: "__cqp_sess", - Value: cookieParam0, + } + + if params.FilterIDs != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter_id", runtime.ParamLocationQuery, params.FilterIDs); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } } - req.AddCookie(cookie0) + } + + queryURL.RawQuery = queryValues.Encode() } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + return req, nil } -// NewListUsersRequest generates requests for ListUsers -func NewListUsersRequest(server string, params *ListUsersParams) (*http.Request, error) { +// NewTableListFiltersRequest generates requests for TableListFilters +func NewTableListFiltersRequest(server string, tableName TableName, params *TableListFiltersParams) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/users") + operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20703,25 +21980,9 @@ func NewListUsersRequest(server string, params *ListUsersParams) (*http.Request, } - if params.UserSearch != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "user_search", runtime.ParamLocationQuery, *params.UserSearch); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.RoleId != nil { + if params.FilterTags != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "role_id", runtime.ParamLocationQuery, *params.RoleId); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag", runtime.ParamLocationQuery, params.FilterTags); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -20746,27 +22007,34 @@ func NewListUsersRequest(server string, params *ListUsersParams) (*http.Request, return req, nil } -// NewAddUserRequest calls the generic AddUser builder with application/json body -func NewAddUserRequest(server string, body AddUserJSONRequestBody) (*http.Request, error) { +// NewTableSaveFilterRequest calls the generic TableSaveFilter builder with application/json body +func NewTableSaveFilterRequest(server string, tableName TableName, body TableSaveFilterJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewAddUserRequestWithBody(server, "application/json", bodyReader) + return NewTableSaveFilterRequestWithBody(server, tableName, "application/json", bodyReader) } -// NewAddUserRequestWithBody generates requests for AddUser with any type of body -func NewAddUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewTableSaveFilterRequestWithBody generates requests for TableSaveFilter with any type of body +func NewTableSaveFilterRequestWithBody(server string, tableName TableName, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/users") + operationPath := fmt.Sprintf("/tables/%s/filters", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20786,13 +22054,13 @@ func NewAddUserRequestWithBody(server string, contentType string, body io.Reader return req, nil } -// NewDeleteUserRequest generates requests for DeleteUser -func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { +// NewTableListFilterTagsRequest generates requests for TableListFilterTags +func NewTableListFilterTagsRequest(server string, tableName TableName, params *TableListFilterTagsParams) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -20802,7 +22070,7 @@ func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { return nil, err } - operationPath := fmt.Sprintf("/users/%s", pathParam0) + operationPath := fmt.Sprintf("/tables/%s/filters/tags", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20812,7 +22080,45 @@ func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if params != nil { + queryValues := queryURL.Query() + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -20820,13 +22126,13 @@ func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { return req, nil } -// NewGetUserRequest generates requests for GetUser -func NewGetUserRequest(server string, userID UserID) (*http.Request, error) { +// NewTableSchemaRequest generates requests for TableSchema +func NewTableSchemaRequest(server string, tableName TableName) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "table_name", runtime.ParamLocationPath, tableName) if err != nil { return nil, err } @@ -20836,7 +22142,7 @@ func NewGetUserRequest(server string, userID UserID) (*http.Request, error) { return nil, err } - operationPath := fmt.Sprintf("/users/%s", pathParam0) + operationPath := fmt.Sprintf("/tables/%s/schema", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -20854,137 +22160,16 @@ func NewGetUserRequest(server string, userID UserID) (*http.Request, error) { return req, nil } -// NewUpdateUserRequest calls the generic UpdateUser builder with application/json body -func NewUpdateUserRequest(server string, userID UserID, body UpdateUserJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewUpdateUserRequestWithBody(server, userID, "application/json", bodyReader) -} - -// NewUpdateUserRequestWithBody generates requests for UpdateUser with any type of body -func NewUpdateUserRequestWithBody(server string, userID UserID, contentType string, body io.Reader) (*http.Request, error) { +// NewListTeamsRequest generates requests for ListTeams +func NewListTeamsRequest(server string, params *ListTeamsParams) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/users/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("PATCH", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewDeleteUserTOTPRequest generates requests for DeleteUserTOTP -func NewDeleteUserTOTPRequest(server string, userID UserID) (*http.Request, error) { - var err error - - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) - if err != nil { - return nil, err - } - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/users/%s/totp", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("DELETE", queryURL.String(), nil) - if err != nil { - return nil, err - } - - return req, nil -} - -// NewCreateV2SyncDestinationTestConnectionRequest calls the generic CreateV2SyncDestinationTestConnection builder with application/json body -func NewCreateV2SyncDestinationTestConnectionRequest(server string, body CreateV2SyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) - if err != nil { - return nil, err - } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateV2SyncDestinationTestConnectionRequestWithBody generates requests for CreateV2SyncDestinationTestConnection with any type of body -func NewCreateV2SyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/sync-destination-test-connections") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } - - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } - - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } - - req.Header.Add("Content-Type", contentType) - - return req, nil -} - -// NewGetV2SyncDestinationsRequest generates requests for GetV2SyncDestinations -func NewGetV2SyncDestinationsRequest(server string, params *GetV2SyncDestinationsParams) (*http.Request, error) { - var err error - - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } - - operationPath := fmt.Sprintf("/v2/sync-destinations") + operationPath := fmt.Sprintf("/teams") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21029,54 +22214,6 @@ func NewGetV2SyncDestinationsRequest(server string, params *GetV2SyncDestination } - if params.Filter != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncGenericSortBys != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.SyncSortDirections != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - queryURL.RawQuery = queryValues.Encode() } @@ -21088,53 +22225,48 @@ func NewGetV2SyncDestinationsRequest(server string, params *GetV2SyncDestination return req, nil } -// NewCreateV2SyncDestinationRequest calls the generic CreateV2SyncDestination builder with application/json body -func NewCreateV2SyncDestinationRequest(server string, body CreateV2SyncDestinationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewDownloadPluginAssetByTeamRequest generates requests for DownloadPluginAssetByTeam +func NewDownloadPluginAssetByTeamRequest(server string, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncDestinationRequestWithBody(server, "application/json", bodyReader) -} -// NewCreateV2SyncDestinationRequestWithBody generates requests for CreateV2SyncDestination with any type of body -func NewCreateV2SyncDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error + var pathParam1 string - serverURL, err := url.Parse(server) + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "plugin_team", runtime.ParamLocationPath, pluginTeam) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/v2/sync-destinations") - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + var pathParam2 string - queryURL, err := serverURL.Parse(operationPath) + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "plugin_kind", runtime.ParamLocationPath, pluginKind) if err != nil { return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) + var pathParam3 string + + pathParam3, err = runtime.StyleParamWithLocation("simple", false, "plugin_name", runtime.ParamLocationPath, pluginName) if err != nil { return nil, err } - req.Header.Add("Content-Type", contentType) - - return req, nil -} + var pathParam4 string -// NewDeleteV2SyncDestinationRequest generates requests for DeleteV2SyncDestination -func NewDeleteV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { - var err error + pathParam4, err = runtime.StyleParamWithLocation("simple", false, "version_name", runtime.ParamLocationPath, versionName) + if err != nil { + return nil, err + } - var pathParam0 string + var pathParam5 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + pathParam5, err = runtime.StyleParamWithLocation("simple", false, "target_name", runtime.ParamLocationPath, targetName) if err != nil { return nil, err } @@ -21144,7 +22276,7 @@ func NewDeleteV2SyncDestinationRequest(server string, syncDestinationName SyncDe return nil, err } - operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + operationPath := fmt.Sprintf("/teams/%s/plugins/%s/%s/%s/versions/%s/assets/%s", pathParam0, pathParam1, pathParam2, pathParam3, pathParam4, pathParam5) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21154,21 +22286,54 @@ func NewDeleteV2SyncDestinationRequest(server string, syncDestinationName SyncDe return nil, err } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } + if params != nil { + + if params.Accept != nil { + var headerParam0 string + + headerParam0, err = runtime.StyleParamWithLocation("simple", false, "Accept", runtime.ParamLocationHeader, *params.Accept) + if err != nil { + return nil, err + } + + req.Header.Set("Accept", headerParam0) + } + + } + return req, nil } -// NewGetV2SyncDestinationRequest generates requests for GetV2SyncDestination -func NewGetV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncDestinationTeamRequest calls the generic UpdateSyncTestConnectionForSyncDestinationTeam builder with application/json body +func NewUpdateSyncTestConnectionForSyncDestinationTeamRequest(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server, teamName, syncDestinationTestConnectionID, "application/json", bodyReader) +} + +// NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncDestinationTeam with any type of body +func NewUpdateSyncTestConnectionForSyncDestinationTeamRequestWithBody(server string, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_test_connection_id", runtime.ParamLocationPath, syncDestinationTestConnectionID) if err != nil { return nil, err } @@ -21178,7 +22343,7 @@ func NewGetV2SyncDestinationRequest(server string, syncDestinationName SyncDesti return nil, err } - operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + operationPath := fmt.Sprintf("/teams/%s/sync-destination-test-connections/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21188,32 +22353,41 @@ func NewGetV2SyncDestinationRequest(server string, syncDestinationName SyncDesti return nil, err } - req, err := http.NewRequest("GET", queryURL.String(), nil) + req, err := http.NewRequest("PATCH", queryURL.String(), body) if err != nil { return nil, err } + req.Header.Add("Content-Type", contentType) + return req, nil } -// NewPatchV2SyncDestinationRequest calls the generic PatchV2SyncDestination builder with application/json body -func NewPatchV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceTeamRequest calls the generic UpdateSyncTestConnectionForSyncSourceTeam builder with application/json body +func NewUpdateSyncTestConnectionForSyncSourceTeamRequest(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewPatchV2SyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) + return NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server, teamName, syncSourceTestConnectionID, "application/json", bodyReader) } -// NewPatchV2SyncDestinationRequestWithBody generates requests for PatchV2SyncDestination with any type of body -func NewPatchV2SyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody generates requests for UpdateSyncTestConnectionForSyncSourceTeam with any type of body +func NewUpdateSyncTestConnectionForSyncSourceTeamRequestWithBody(server string, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader) (*http.Request, error) { var err error var pathParam0 string - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_source_test_connection_id", runtime.ParamLocationPath, syncSourceTestConnectionID) if err != nil { return nil, err } @@ -21223,7 +22397,7 @@ func NewPatchV2SyncDestinationRequestWithBody(server string, syncDestinationName return nil, err } - operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + operationPath := fmt.Sprintf("/teams/%s/sync-source-test-connections/%s", pathParam0, pathParam1) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21243,27 +22417,48 @@ func NewPatchV2SyncDestinationRequestWithBody(server string, syncDestinationName return req, nil } -// NewCreateV2SyncIntegrationTestConnectionRequest calls the generic CreateV2SyncIntegrationTestConnection builder with application/json body -func NewCreateV2SyncIntegrationTestConnectionRequest(server string, body CreateV2SyncIntegrationTestConnectionJSONRequestBody) (*http.Request, error) { +// NewCreateSyncRunProgressTeamRequest calls the generic CreateSyncRunProgressTeam builder with application/json body +func NewCreateSyncRunProgressTeamRequest(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server, "application/json", bodyReader) + return NewCreateSyncRunProgressTeamRequestWithBody(server, teamName, syncName, syncRunId, "application/json", bodyReader) } -// NewCreateV2SyncIntegrationTestConnectionRequestWithBody generates requests for CreateV2SyncIntegrationTestConnection with any type of body -func NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { +// NewCreateSyncRunProgressTeamRequestWithBody generates requests for CreateSyncRunProgressTeam with any type of body +func NewCreateSyncRunProgressTeamRequestWithBody(server string, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader) (*http.Request, error) { var err error + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "team_name", runtime.ParamLocationPath, teamName) + if err != nil { + return nil, err + } + + var pathParam1 string + + pathParam1, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } + + var pathParam2 string + + pathParam2, err = runtime.StyleParamWithLocation("simple", false, "sync_run_id", runtime.ParamLocationPath, syncRunId) + if err != nil { + return nil, err + } + serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/v2/sync-integration-test-connections") + operationPath := fmt.Sprintf("/teams/%s/syncs/%s/runs/%s/progress", pathParam0, pathParam1, pathParam2) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21283,8 +22478,8 @@ func NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server string, cont return req, nil } -// NewListV2SyncIntegrationsRequest generates requests for ListV2SyncIntegrations -func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrationsParams) (*http.Request, error) { +// NewGetTeamUsageSummaryRequest generates requests for GetTeamUsageSummary +func NewGetTeamUsageSummaryRequest(server string, params *GetTeamUsageSummaryParams) (*http.Request, error) { var err error serverURL, err := url.Parse(server) @@ -21292,7 +22487,7 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati return nil, err } - operationPath := fmt.Sprintf("/v2/sync-integrations") + operationPath := fmt.Sprintf("/usage-summary") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21305,25 +22500,9 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati if params != nil { queryValues := queryURL.Query() - if params.PerPage != nil { - - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { - return nil, err - } else if parsed, err := url.ParseQuery(queryFrag); err != nil { - return nil, err - } else { - for k, v := range parsed { - for _, v2 := range v { - queryValues.Add(k, v2) - } - } - } - - } - - if params.Page != nil { + if params.Metrics != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21337,9 +22516,9 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati } - if params.SyncSortBys != nil { + if params.Start != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21353,9 +22532,9 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati } - if params.SyncSortDirections != nil { + if params.End != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21369,9 +22548,9 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati } - if params.Filter != nil { + if params.AggregationPeriod != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21396,27 +22575,23 @@ func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrati return req, nil } -// NewCreateV2SyncIntegrationRequest calls the generic CreateV2SyncIntegration builder with application/json body -func NewCreateV2SyncIntegrationRequest(server string, body CreateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { - var bodyReader io.Reader - buf, err := json.Marshal(body) +// NewGetGroupedTeamUsageSummaryRequest generates requests for GetGroupedTeamUsageSummary +func NewGetGroupedTeamUsageSummaryRequest(server string, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams) (*http.Request, error) { + var err error + + var pathParam0 string + + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "group_by", runtime.ParamLocationPath, groupBy) if err != nil { return nil, err } - bodyReader = bytes.NewReader(buf) - return NewCreateV2SyncIntegrationRequestWithBody(server, "application/json", bodyReader) -} - -// NewCreateV2SyncIntegrationRequestWithBody generates requests for CreateV2SyncIntegration with any type of body -func NewCreateV2SyncIntegrationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { - var err error serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/v2/sync-integrations") + operationPath := fmt.Sprintf("/usage-summary/%s", pathParam0) if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21426,48 +22601,60 @@ func NewCreateV2SyncIntegrationRequestWithBody(server string, contentType string return nil, err } - req, err := http.NewRequest("POST", queryURL.String(), body) - if err != nil { - return nil, err - } + if params != nil { + queryValues := queryURL.Query() - req.Header.Add("Content-Type", contentType) + if params.Metrics != nil { - return req, nil -} + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "metrics", runtime.ParamLocationQuery, params.Metrics); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } -// NewDeleteV2SyncIntegrationRequest generates requests for DeleteV2SyncIntegration -func NewDeleteV2SyncIntegrationRequest(server string, syncName SyncName, params *DeleteV2SyncIntegrationParams) (*http.Request, error) { - var err error + } - var pathParam0 string + if params.Start != nil { - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "start", runtime.ParamLocationQuery, *params.Start); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - serverURL, err := url.Parse(server) - if err != nil { - return nil, err - } + } - operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) - if operationPath[0] == '/' { - operationPath = "." + operationPath - } + if params.End != nil { - queryURL, err := serverURL.Parse(operationPath) - if err != nil { - return nil, err - } + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "end", runtime.ParamLocationQuery, *params.End); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - if params != nil { - queryValues := queryURL.Query() + } - if params.DeleteData != nil { + if params.AggregationPeriod != nil { - if queryFrag, err := runtime.StyleParamWithLocation("form", true, "delete_data", runtime.ParamLocationQuery, *params.DeleteData); err != nil { + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "aggregation_period", runtime.ParamLocationQuery, *params.AggregationPeriod); err != nil { return nil, err } else if parsed, err := url.ParseQuery(queryFrag); err != nil { return nil, err @@ -21484,7 +22671,7 @@ func NewDeleteV2SyncIntegrationRequest(server string, syncName SyncName, params queryURL.RawQuery = queryValues.Encode() } - req, err := http.NewRequest("DELETE", queryURL.String(), nil) + req, err := http.NewRequest("GET", queryURL.String(), nil) if err != nil { return nil, err } @@ -21492,23 +22679,16 @@ func NewDeleteV2SyncIntegrationRequest(server string, syncName SyncName, params return req, nil } -// NewGetV2SyncIntegrationRequest generates requests for GetV2SyncIntegration -func NewGetV2SyncIntegrationRequest(server string, syncName SyncName) (*http.Request, error) { +// NewGetCurrentUserRequest generates requests for GetCurrentUser +func NewGetCurrentUserRequest(server string) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) + operationPath := fmt.Sprintf("/user") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21526,34 +22706,27 @@ func NewGetV2SyncIntegrationRequest(server string, syncName SyncName) (*http.Req return req, nil } -// NewUpdateV2SyncIntegrationRequest calls the generic UpdateV2SyncIntegration builder with application/json body -func NewUpdateV2SyncIntegrationRequest(server string, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { +// NewUpdateCurrentUserRequest calls the generic UpdateCurrentUser builder with application/json body +func NewUpdateCurrentUserRequest(server string, body UpdateCurrentUserJSONRequestBody) (*http.Request, error) { var bodyReader io.Reader buf, err := json.Marshal(body) if err != nil { return nil, err } bodyReader = bytes.NewReader(buf) - return NewUpdateV2SyncIntegrationRequestWithBody(server, syncName, "application/json", bodyReader) + return NewUpdateCurrentUserRequestWithBody(server, "application/json", bodyReader) } -// NewUpdateV2SyncIntegrationRequestWithBody generates requests for UpdateV2SyncIntegration with any type of body -func NewUpdateV2SyncIntegrationRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { +// NewUpdateCurrentUserRequestWithBody generates requests for UpdateCurrentUser with any type of body +func NewUpdateCurrentUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { var err error - var pathParam0 string - - pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) - if err != nil { - return nil, err - } - serverURL, err := url.Parse(server) if err != nil { return nil, err } - operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) + operationPath := fmt.Sprintf("/user") if operationPath[0] == '/' { operationPath = "." + operationPath } @@ -21573,857 +22746,2223 @@ func NewUpdateV2SyncIntegrationRequestWithBody(server string, syncName SyncName, return req, nil } -func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error { - for _, r := range c.RequestEditors { - if err := r(ctx, req); err != nil { - return err - } - } - for _, r := range additionalEditors { - if err := r(ctx, req); err != nil { - return err - } +// NewSendAnonymousEventRequest calls the generic SendAnonymousEvent builder with application/json body +func NewSendAnonymousEventRequest(server string, body SendAnonymousEventJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err } - return nil + bodyReader = bytes.NewReader(buf) + return NewSendAnonymousEventRequestWithBody(server, "application/json", bodyReader) } -// ClientWithResponses builds on ClientInterface to offer response payloads -type ClientWithResponses struct { - ClientInterface -} +// NewSendAnonymousEventRequestWithBody generates requests for SendAnonymousEvent with any type of body +func NewSendAnonymousEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error -// NewClientWithResponses creates a new ClientWithResponses, which wraps -// Client with return type handling -func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error) { - client, err := NewClient(server, opts...) + serverURL, err := url.Parse(server) if err != nil { return nil, err } - return &ClientWithResponses{client}, nil -} -// WithBaseURL overrides the baseURL. -func WithBaseURL(baseURL string) ClientOption { - return func(c *Client) error { - newBaseURL, err := url.Parse(baseURL) - if err != nil { - return err - } - c.Server = newBaseURL.String() - return nil - } -} - -// ClientWithResponsesInterface is the interface specification for the client with responses above. -type ClientWithResponsesInterface interface { - // IndexWithResponse request - IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) - - // ListAllAlertsWithResponse request - ListAllAlertsWithResponse(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) - - // TestUnsavedAlertWithBodyWithResponse request with any body - TestUnsavedAlertWithBodyWithResponse(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) - - TestUnsavedAlertWithResponse(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) + operationPath := fmt.Sprintf("/user/anon-event") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // ListAPIKeysWithResponse request - ListAPIKeysWithResponse(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*ListAPIKeysResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // CreateAPIKeyWithBodyWithResponse request with any body - CreateAPIKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - CreateAPIKeyWithResponse(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) + req.Header.Add("Content-Type", contentType) - // DeleteAPIKeyWithResponse request - DeleteAPIKeyWithResponse(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteAPIKeyResponse, error) + return req, nil +} - // ListAuditLogsWithResponse request - ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) +// NewAuthenticateUserRequest calls the generic AuthenticateUser builder with application/json body +func NewAuthenticateUserRequest(server string, body AuthenticateUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewAuthenticateUserRequestWithBody(server, "application/json", bodyReader) +} - // GetAuditLogWithResponse request - GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) +// NewAuthenticateUserRequestWithBody generates requests for AuthenticateUser with any type of body +func NewAuthenticateUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // GetSAMLWithResponse request - GetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSAMLResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // UpdateSAMLWithBodyWithResponse request with any body - UpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) + operationPath := fmt.Sprintf("/user/authenticate") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - UpdateSAMLWithResponse(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // CreateConversationWithBodyWithResponse request with any body - CreateConversationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - CreateConversationWithResponse(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) + req.Header.Add("Content-Type", contentType) - // GetConversationWithResponse request - GetConversationWithResponse(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) + return req, nil +} - // SendMessageWithBodyWithResponse request with any body - SendMessageWithBodyWithResponse(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) +// NewChangeUserPasswordRequest calls the generic ChangeUserPassword builder with application/json body +func NewChangeUserPasswordRequest(server string, body ChangeUserPasswordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewChangeUserPasswordRequestWithBody(server, "application/json", bodyReader) +} - SendMessageWithResponse(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) +// NewChangeUserPasswordRequestWithBody generates requests for ChangeUserPassword with any type of body +func NewChangeUserPasswordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // ListAllCustomColumnsWithResponse request - ListAllCustomColumnsWithResponse(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // SaveCustomColumnWithBodyWithResponse request with any body - SaveCustomColumnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) + operationPath := fmt.Sprintf("/user/change-password") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - SaveCustomColumnWithResponse(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // DeleteCustomColumnWithResponse request - DeleteCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // GetCustomColumnWithResponse request - GetCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) + req.Header.Add("Content-Type", contentType) - // UpdateCustomColumnWithBodyWithResponse request with any body - UpdateCustomColumnWithBodyWithResponse(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) + return req, nil +} - UpdateCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) +// NewUpdateCustomerRequest calls the generic UpdateCustomer builder with application/json body +func NewUpdateCustomerRequest(server string, body UpdateCustomerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateCustomerRequestWithBody(server, "application/json", bodyReader) +} - // ListFiltersWithResponse request - ListFiltersWithResponse(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*ListFiltersResponse, error) +// NewUpdateCustomerRequestWithBody generates requests for UpdateCustomer with any type of body +func NewUpdateCustomerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // ListFilterTagsWithResponse request - ListFilterTagsWithResponse(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*ListFilterTagsResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // DeleteFilterWithResponse request - DeleteFilterWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterResponse, error) + operationPath := fmt.Sprintf("/user/customer") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // GetFilterByIDWithResponse request - GetFilterByIDWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // UpdateFilterWithBodyWithResponse request with any body - UpdateFilterWithBodyWithResponse(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } - UpdateFilterWithResponse(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) + req.Header.Add("Content-Type", contentType) - // HealthCheckWithResponse request - HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) + return req, nil +} - // HealthCheckHeadWithResponse request - HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) +// NewSendUserEventRequest calls the generic SendUserEvent builder with application/json body +func NewSendUserEventRequest(server string, body SendUserEventJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewSendUserEventRequestWithBody(server, "application/json", bodyReader) +} - // ListNotificationsWithResponse request - ListNotificationsWithResponse(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*ListNotificationsResponse, error) +// NewSendUserEventRequestWithBody generates requests for SendUserEvent with any type of body +func NewSendUserEventRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // DeleteNotificationDestinationWithResponse request - DeleteNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // GetNotificationDestinationWithResponse request - GetNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) + operationPath := fmt.Sprintf("/user/event") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // UpdateNotificationDestinationWithBodyWithResponse request with any body - UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - UpdateNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // GetNotificationDestinationAlertsWithResponse request - GetNotificationDestinationAlertsWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) + req.Header.Add("Content-Type", contentType) - // TestNotificationDestinationWithResponse request - TestNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) + return req, nil +} - // ListAllNotificationDestinationsWithResponse request - ListAllNotificationDestinationsWithResponse(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) +// NewLogoutUserRequest generates requests for LogoutUser +func NewLogoutUserRequest(server string) (*http.Request, error) { + var err error - // CreateNotificationDestinationWithBodyWithResponse request with any body - CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - CreateNotificationDestinationWithResponse(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) + operationPath := fmt.Sprintf("/user/login") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // TestUnsavedNotificationDestinationWithBodyWithResponse request with any body - TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - TestUnsavedNotificationDestinationWithResponse(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - // CreateAWSOnboardingWithBodyWithResponse request with any body - CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) + return req, nil +} - CreateAWSOnboardingWithResponse(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) +// NewLoginUserRequest calls the generic LoginUser builder with application/json body +func NewLoginUserRequest(server string, body LoginUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewLoginUserRequestWithBody(server, "application/json", bodyReader) +} - // GetAWSOnboardingWithResponse request - GetAWSOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) +// NewLoginUserRequestWithBody generates requests for LoginUser with any type of body +func NewLoginUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // GetAWSAccountsInRootWithResponse request - GetAWSAccountsInRootWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ProvisionOnboardingConfigurationWithBodyWithResponse request with any body - ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) + operationPath := fmt.Sprintf("/user/login") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - ProvisionOnboardingConfigurationWithResponse(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetAWSAccountsInParentWithResponse request - GetAWSAccountsInParentWithResponse(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // NotifyOnboardingWithBodyWithResponse request with any body - NotifyOnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) + req.Header.Add("Content-Type", contentType) - NotifyOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) + return req, nil +} - // GetOpenAPIJSONWithResponse request - GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) +// NewUserTOTPDeleteRequest generates requests for UserTOTPDelete +func NewUserTOTPDeleteRequest(server string) (*http.Request, error) { + var err error - // GetPlatformInfoWithResponse request - GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ListPlatformVersionsWithResponse request - ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) + operationPath := fmt.Sprintf("/user/totp") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // ListPluginsWithResponse request - ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetPluginWithResponse request - GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - // ListPluginVersionsWithResponse request - ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) + return req, nil +} - // GetPluginVersionWithResponse request - GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) +// NewUserTOTPSetupRequest generates requests for UserTOTPSetup +func NewUserTOTPSetupRequest(server string) (*http.Request, error) { + var err error - // DownloadPluginAssetWithResponse request - DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ListPluginVersionTablesWithResponse request - ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) + operationPath := fmt.Sprintf("/user/totp") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // GetPluginVersionTableWithResponse request - GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // ListPoliciesWithResponse request - ListPoliciesWithResponse(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), nil) + if err != nil { + return nil, err + } - // CreatePolicyWithBodyWithResponse request with any body - CreatePolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) + return req, nil +} - CreatePolicyWithResponse(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) +// NewUserTOTPVerifyRequest calls the generic UserTOTPVerify builder with application/json body +func NewUserTOTPVerifyRequest(server string, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUserTOTPVerifyRequestWithBody(server, params, "application/json", bodyReader) +} - // GetPolicyMetricsWithResponse request - GetPolicyMetricsWithResponse(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*GetPolicyMetricsResponse, error) +// NewUserTOTPVerifyRequestWithBody generates requests for UserTOTPVerify with any type of body +func NewUserTOTPVerifyRequestWithBody(server string, params *UserTOTPVerifyParams, contentType string, body io.Reader) (*http.Request, error) { + var err error - // GetViolationsByDomainWithResponse request - GetViolationsByDomainWithResponse(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*GetViolationsByDomainResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // GetViolationsHistoryWithResponse request - GetViolationsHistoryWithResponse(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetViolationsHistoryResponse, error) + operationPath := fmt.Sprintf("/user/totp/verify") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // DeletePolicyWithResponse request - DeletePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetPolicyWithResponse request - GetPolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // UpdatePolicyWithBodyWithResponse request with any body - UpdatePolicyWithBodyWithResponse(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) + req.Header.Add("Content-Type", contentType) - UpdatePolicyWithResponse(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) + if params != nil { - // TogglePolicyWithResponse request - TogglePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) + if params.CqpSess != nil { + var cookieParam0 string - // GetPolicyViolationsWithResponse request - GetPolicyViolationsWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsResponse, error) + cookieParam0, err = runtime.StyleParamWithLocation("simple", true, "__cqp_sess", runtime.ParamLocationCookie, *params.CqpSess) + if err != nil { + return nil, err + } - // GetPolicyViolationsHistoryWithResponse request - GetPolicyViolationsHistoryWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) + cookie0 := &http.Cookie{ + Name: "__cqp_sess", + Value: cookieParam0, + } + req.AddCookie(cookie0) + } + } + return req, nil +} - // ListPolicyGroupsWithResponse request - ListPolicyGroupsWithResponse(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*ListPolicyGroupsResponse, error) +// NewListUsersRequest generates requests for ListUsers +func NewListUsersRequest(server string, params *ListUsersParams) (*http.Request, error) { + var err error - // CreatePolicyGroupWithBodyWithResponse request with any body - CreatePolicyGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - CreatePolicyGroupWithResponse(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) + operationPath := fmt.Sprintf("/users") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // DeletePolicyGroupWithResponse request - DeletePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*DeletePolicyGroupResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // ListPoliciesInGroupWithResponse request - ListPoliciesInGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*ListPoliciesInGroupResponse, error) + if params != nil { + queryValues := queryURL.Query() - // UpdatePolicyGroupWithBodyWithResponse request with any body - UpdatePolicyGroupWithBodyWithResponse(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) + if params.PerPage != nil { - UpdatePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // ListAllQueriesWithResponse request - ListAllQueriesWithResponse(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*ListAllQueriesResponse, error) + } - // ExecuteAdHocQueryWithBodyWithResponse request with any body - ExecuteAdHocQueryWithBodyWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) + if params.Page != nil { - ExecuteAdHocQueryWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // SaveQueryWithBodyWithResponse request with any body - SaveQueryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) + } - SaveQueryWithResponse(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) + if params.UserSearch != nil { - // ListQueryTagsWithResponse request - ListQueryTagsWithResponse(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*ListQueryTagsResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "user_search", runtime.ParamLocationQuery, *params.UserSearch); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // DeleteSavedQueryWithResponse request - DeleteSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryResponse, error) + } - // GetSavedQueryWithResponse request - GetSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryResponse, error) + if params.RoleId != nil { - // UpdateQueryWithBodyWithResponse request with any body - UpdateQueryWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "role_id", runtime.ParamLocationQuery, *params.RoleId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - UpdateQueryWithResponse(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) + } - // DeleteAlertWithResponse request - DeleteAlertWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) + queryURL.RawQuery = queryValues.Encode() + } - // ExecuteSavedQueryWithResponse request - ExecuteSavedQueryWithResponse(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - // QueryListFiltersWithResponse request - QueryListFiltersWithResponse(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*QueryListFiltersResponse, error) + return req, nil +} - // QuerySaveFilterWithBodyWithResponse request with any body - QuerySaveFilterWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) +// NewAddUserRequest calls the generic AddUser builder with application/json body +func NewAddUserRequest(server string, body AddUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewAddUserRequestWithBody(server, "application/json", bodyReader) +} - QuerySaveFilterWithResponse(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) +// NewAddUserRequestWithBody generates requests for AddUser with any type of body +func NewAddUserRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // QueryListFilterTagsWithResponse request - QueryListFilterTagsWithResponse(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ListAllRBACPermissionsWithResponse request - ListAllRBACPermissionsWithResponse(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) + operationPath := fmt.Sprintf("/users") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // CreateRBACPermissionWithBodyWithResponse request with any body - CreateRBACPermissionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - CreateRBACPermissionWithResponse(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // DeleteRBACPermissionWithResponse request - DeleteRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) + req.Header.Add("Content-Type", contentType) - // GetRBACPermissionWithResponse request - GetRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) + return req, nil +} - // UpdateRBACPermissionWithBodyWithResponse request with any body - UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) +// NewDeleteUserRequest generates requests for DeleteUser +func NewDeleteUserRequest(server string, userID UserID) (*http.Request, error) { + var err error - UpdateRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) + var pathParam0 string - // ListAllRBACRolesWithResponse request - ListAllRBACRolesWithResponse(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + if err != nil { + return nil, err + } - // CreateRBACRoleWithBodyWithResponse request with any body - CreateRBACRoleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - CreateRBACRoleWithResponse(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) + operationPath := fmt.Sprintf("/users/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // DeleteRBACRoleWithResponse request - DeleteRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetRBACRoleWithResponse request - GetRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - // UpdateRBACRoleWithBodyWithResponse request with any body - UpdateRBACRoleWithBodyWithResponse(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) + return req, nil +} - UpdateRBACRoleWithResponse(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) +// NewGetUserRequest generates requests for GetUser +func NewGetUserRequest(server string, userID UserID) (*http.Request, error) { + var err error - // ListReportsWithResponse request - ListReportsWithResponse(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) + var pathParam0 string - // CreateReportWithBodyWithResponse request with any body - CreateReportWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + if err != nil { + return nil, err + } - CreateReportWithResponse(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ListReportTemplatesWithResponse request - ListReportTemplatesWithResponse(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) + operationPath := fmt.Sprintf("/users/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // CreateReportTemplateWithBodyWithResponse request with any body - CreateReportTemplateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - CreateReportTemplateWithResponse(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - // DeleteReportTemplateWithResponse request - DeleteReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) + return req, nil +} - // GetReportTemplateWithResponse request - GetReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) +// NewUpdateUserRequest calls the generic UpdateUser builder with application/json body +func NewUpdateUserRequest(server string, userID UserID, body UpdateUserJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewUpdateUserRequestWithBody(server, userID, "application/json", bodyReader) +} - // UpdateReportTemplateWithBodyWithResponse request with any body - UpdateReportTemplateWithBodyWithResponse(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) +// NewUpdateUserRequestWithBody generates requests for UpdateUser with any type of body +func NewUpdateUserRequestWithBody(server string, userID UserID, contentType string, body io.Reader) (*http.Request, error) { + var err error - UpdateReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) + var pathParam0 string - // DeleteReportWithResponse request - DeleteReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + if err != nil { + return nil, err + } - // GetReportWithResponse request - GetReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // UpdateReportWithBodyWithResponse request with any body - UpdateReportWithBodyWithResponse(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) + operationPath := fmt.Sprintf("/users/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - UpdateReportWithResponse(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetSettingsWithResponse request - GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } - // UpdateSettingsWithBodyWithResponse request with any body - UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) + req.Header.Add("Content-Type", contentType) - UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) + return req, nil +} - // GetDataSettingsWithResponse request - GetDataSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataSettingsResponse, error) +// NewDeleteUserTOTPRequest generates requests for DeleteUserTOTP +func NewDeleteUserTOTPRequest(server string, userID UserID) (*http.Request, error) { + var err error - // UpdateDataSettingsWithBodyWithResponse request with any body - UpdateDataSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) + var pathParam0 string - UpdateDataSettingsWithResponse(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "user_id", runtime.ParamLocationPath, userID) + if err != nil { + return nil, err + } - // CreateSlackConnectionWithBodyWithResponse request with any body - CreateSlackConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - CreateSlackConnectionWithResponse(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) + operationPath := fmt.Sprintf("/users/%s/totp", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // ListSlackChannelsWithResponse request - ListSlackChannelsWithResponse(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*ListSlackChannelsResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // CreateSyncDestinationTestConnectionWithBodyWithResponse request with any body - CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) + return req, nil +} - // GetSyncDestinationTestConnectionWithResponse request - GetSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) +// NewCreateV2SyncDestinationTestConnectionRequest calls the generic CreateV2SyncDestinationTestConnection builder with application/json body +func NewCreateV2SyncDestinationTestConnectionRequest(server string, body CreateV2SyncDestinationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncDestinationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} - // UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) +// NewCreateV2SyncDestinationTestConnectionRequestWithBody generates requests for CreateV2SyncDestinationTestConnection with any type of body +func NewCreateV2SyncDestinationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // GetSyncDestinationTestConnectionLogsLiveWithResponse request - GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destination-test-connections") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // GetSyncDestinationTestConnectionLogsQueryWithResponse request - GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // PromoteSyncDestinationTestConnectionWithBodyWithResponse request with any body - PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) + req.Header.Add("Content-Type", contentType) - // ListSyncDestinationsWithResponse request - ListSyncDestinationsWithResponse(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) + return req, nil +} - // DeleteSyncDestinationWithResponse request - DeleteSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) +// NewGetV2SyncDestinationsRequest generates requests for GetV2SyncDestinations +func NewGetV2SyncDestinationsRequest(server string, params *GetV2SyncDestinationsParams) (*http.Request, error) { + var err error - // GetSyncDestinationWithResponse request - GetSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // UpdateSyncDestinationWithBodyWithResponse request with any body - UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destinations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - UpdateSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // ListSyncDestinationSyncsWithResponse request - ListSyncDestinationSyncsWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) + if params != nil { + queryValues := queryURL.Query() - // GetTestConnectionForSyncDestinationWithResponse request - GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) + if params.PerPage != nil { - // CreateSyncSourceTestConnectionWithBodyWithResponse request with any body - CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - CreateSyncSourceTestConnectionWithResponse(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) + } - // GetSyncSourceTestConnectionWithResponse request - GetSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) + if params.Page != nil { - // UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) + } - // GetSyncSourceTestConnectionLogsLiveWithResponse request - GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) + if params.Filter != nil { - // GetSyncSourceTestConnectionLogsQueryWithResponse request - GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // PromoteSyncSourceTestConnectionWithBodyWithResponse request with any body - PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) + } - PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) + if params.SyncGenericSortBys != nil { - // ListSyncSourcesWithResponse request - ListSyncSourcesWithResponse(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncGenericSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // DeleteSyncSourceWithResponse request - DeleteSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) + } - // GetSyncSourceWithResponse request - GetSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) + if params.SyncSortDirections != nil { - // UpdateSyncSourceWithBodyWithResponse request with any body - UpdateSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - UpdateSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) + } - // ListSyncSourceSyncsWithResponse request - ListSyncSourceSyncsWithResponse(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) + queryURL.RawQuery = queryValues.Encode() + } - // GetTestConnectionForSyncSourceWithResponse request - GetTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - // ListSyncTransformersWithResponse request - ListSyncTransformersWithResponse(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) + return req, nil +} - // DeleteSyncTransformerWithResponse request - DeleteSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) +// NewCreateV2SyncDestinationRequest calls the generic CreateV2SyncDestination builder with application/json body +func NewCreateV2SyncDestinationRequest(server string, body CreateV2SyncDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncDestinationRequestWithBody(server, "application/json", bodyReader) +} - // GetSyncTransformerWithResponse request - GetSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) +// NewCreateV2SyncDestinationRequestWithBody generates requests for CreateV2SyncDestination with any type of body +func NewCreateV2SyncDestinationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // UpdateSyncTransformerWithBodyWithResponse request with any body - UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - UpdateSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destinations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // ListSyncTransformerSyncDestinationsWithResponse request - ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // ListSyncTransformerSyncsWithResponse request - ListSyncTransformerSyncsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // ListSyncUpgradesWithResponse request - ListSyncUpgradesWithResponse(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) + req.Header.Add("Content-Type", contentType) - // ListSyncsWithResponse request - ListSyncsWithResponse(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) + return req, nil +} - // CreateSyncWithBodyWithResponse request with any body - CreateSyncWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) +// NewDeleteV2SyncDestinationRequest generates requests for DeleteV2SyncDestination +func NewDeleteV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { + var err error - CreateSyncWithResponse(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) + var pathParam0 string - // DeleteSyncWithResponse request - DeleteSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + if err != nil { + return nil, err + } - // GetSyncWithResponse request - GetSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // UpdateSyncWithBodyWithResponse request with any body - UpdateSyncWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - UpdateSyncWithResponse(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // ListSyncRunsWithResponse request - ListSyncRunsWithResponse(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - // CreateSyncRunWithResponse request - CreateSyncRunWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) + return req, nil +} - // GetSyncRunWithResponse request - GetSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) - - // UpdateSyncRunWithBodyWithResponse request with any body - UpdateSyncRunWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) +// NewGetV2SyncDestinationRequest generates requests for GetV2SyncDestination +func NewGetV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName) (*http.Request, error) { + var err error - UpdateSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) + var pathParam0 string - // GetSyncRunLogsLiveWithResponse request - GetSyncRunLogsLiveWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + if err != nil { + return nil, err + } - // GetSyncRunLogsQueryWithResponse request - GetSyncRunLogsQueryWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // CreateSyncRunProgressWithBodyWithResponse request with any body - CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - CreateSyncRunProgressWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetSyncRunStatsWithResponse request - GetSyncRunStatsWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - // GetSyncRunTablesWithResponse request - GetSyncRunTablesWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) + return req, nil +} - // ListTablesWithResponse request - ListTablesWithResponse(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*ListTablesResponse, error) +// NewPatchV2SyncDestinationRequest calls the generic PatchV2SyncDestination builder with application/json body +func NewPatchV2SyncDestinationRequest(server string, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchV2SyncDestinationRequestWithBody(server, syncDestinationName, "application/json", bodyReader) +} - // GetTablesDataWithResponse request - GetTablesDataWithResponse(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*GetTablesDataResponse, error) +// NewPatchV2SyncDestinationRequestWithBody generates requests for PatchV2SyncDestination with any type of body +func NewPatchV2SyncDestinationRequestWithBody(server string, syncDestinationName SyncDestinationName, contentType string, body io.Reader) (*http.Request, error) { + var err error - // TablesDataActionWithBodyWithResponse request with any body - TablesDataActionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) + var pathParam0 string - TablesDataActionWithResponse(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_destination_name", runtime.ParamLocationPath, syncDestinationName) + if err != nil { + return nil, err + } - // BatchTableSchemasWithResponse request - BatchTableSchemasWithResponse(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // TableListColumnsWithResponse request - TableListColumnsWithResponse(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*TableListColumnsResponse, error) + operationPath := fmt.Sprintf("/v2/sync-destinations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // TableColumnListValuesWithResponse request - TableColumnListValuesWithResponse(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // TableListRowsWithResponse request - TableListRowsWithResponse(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*TableListRowsResponse, error) + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } - // TableRowByIdWithResponse request - TableRowByIdWithResponse(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*TableRowByIdResponse, error) + req.Header.Add("Content-Type", contentType) - // TableListFiltersWithResponse request - TableListFiltersWithResponse(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*TableListFiltersResponse, error) + return req, nil +} - // TableSaveFilterWithBodyWithResponse request with any body - TableSaveFilterWithBodyWithResponse(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) +// NewCreateV2SyncIntegrationTestConnectionRequest calls the generic CreateV2SyncIntegrationTestConnection builder with application/json body +func NewCreateV2SyncIntegrationTestConnectionRequest(server string, body CreateV2SyncIntegrationTestConnectionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server, "application/json", bodyReader) +} - TableSaveFilterWithResponse(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) +// NewCreateV2SyncIntegrationTestConnectionRequestWithBody generates requests for CreateV2SyncIntegrationTestConnection with any type of body +func NewCreateV2SyncIntegrationTestConnectionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - // TableListFilterTagsWithResponse request - TableListFilterTagsWithResponse(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // TableSchemaWithResponse request - TableSchemaWithResponse(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaResponse, error) + operationPath := fmt.Sprintf("/v2/sync-integration-test-connections") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // ListTeamsWithResponse request - ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // DownloadPluginAssetByTeamWithResponse request - DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) + req.Header.Add("Content-Type", contentType) - UpdateSyncTestConnectionForSyncDestinationTeamWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) + return req, nil +} - // UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse request with any body - UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) +// NewListV2SyncIntegrationsRequest generates requests for ListV2SyncIntegrations +func NewListV2SyncIntegrationsRequest(server string, params *ListV2SyncIntegrationsParams) (*http.Request, error) { + var err error - UpdateSyncTestConnectionForSyncSourceTeamWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // CreateSyncRunProgressTeamWithBodyWithResponse request with any body - CreateSyncRunProgressTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) + operationPath := fmt.Sprintf("/v2/sync-integrations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - CreateSyncRunProgressTeamWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // GetTeamUsageSummaryWithResponse request - GetTeamUsageSummaryWithResponse(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) + if params != nil { + queryValues := queryURL.Query() - // GetGroupedTeamUsageSummaryWithResponse request - GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) + if params.PerPage != nil { - // GetCurrentUserWithResponse request - GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // UpdateCurrentUserWithBodyWithResponse request with any body - UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) + } - UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) + if params.Page != nil { - // SendAnonymousEventWithBodyWithResponse request with any body - SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) + } - // AuthenticateUserWithBodyWithResponse request with any body - AuthenticateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) + if params.SyncSortBys != nil { - AuthenticateUserWithResponse(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_by", runtime.ParamLocationQuery, params.SyncSortBys); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // ChangeUserPasswordWithBodyWithResponse request with any body - ChangeUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) + } - ChangeUserPasswordWithResponse(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) + if params.SyncSortDirections != nil { - // UpdateCustomerWithBodyWithResponse request with any body - UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "sort_dir", runtime.ParamLocationQuery, params.SyncSortDirections); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) + } - // SendUserEventWithBodyWithResponse request with any body - SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) + if params.Filter != nil { - SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "filter", runtime.ParamLocationQuery, *params.Filter); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // LogoutUserWithResponse request - LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) + } - // LoginUserWithBodyWithResponse request with any body - LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) + queryURL.RawQuery = queryValues.Encode() + } - LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - // UserTOTPDeleteWithResponse request - UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) + return req, nil +} - // UserTOTPSetupWithResponse request - UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) +// NewCreateV2SyncIntegrationRequest calls the generic CreateV2SyncIntegration builder with application/json body +func NewCreateV2SyncIntegrationRequest(server string, body CreateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewCreateV2SyncIntegrationRequestWithBody(server, "application/json", bodyReader) +} - // UserTOTPVerifyWithBodyWithResponse request with any body - UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) +// NewCreateV2SyncIntegrationRequestWithBody generates requests for CreateV2SyncIntegration with any type of body +func NewCreateV2SyncIntegrationRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error - UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // ListUsersWithResponse request - ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) + operationPath := fmt.Sprintf("/v2/sync-integrations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // AddUserWithBodyWithResponse request with any body - AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } - // DeleteUserWithResponse request - DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) + req.Header.Add("Content-Type", contentType) - // GetUserWithResponse request - GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) + return req, nil +} - // UpdateUserWithBodyWithResponse request with any body - UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) +// NewDeleteV2SyncIntegrationRequest generates requests for DeleteV2SyncIntegration +func NewDeleteV2SyncIntegrationRequest(server string, syncName SyncName, params *DeleteV2SyncIntegrationParams) (*http.Request, error) { + var err error - UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) + var pathParam0 string - // DeleteUserTOTPWithResponse request - DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } - // CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with any body - CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // GetV2SyncDestinationsWithResponse request - GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // CreateV2SyncDestinationWithBodyWithResponse request with any body - CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) + if params != nil { + queryValues := queryURL.Query() - CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) + if params.DeleteData != nil { - // DeleteV2SyncDestinationWithResponse request - DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "delete_data", runtime.ParamLocationQuery, *params.DeleteData); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } - // GetV2SyncDestinationWithResponse request - GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) + } - // PatchV2SyncDestinationWithBodyWithResponse request with any body - PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) + queryURL.RawQuery = queryValues.Encode() + } - PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) + req, err := http.NewRequest("DELETE", queryURL.String(), nil) + if err != nil { + return nil, err + } - // CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with any body - CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) + return req, nil +} - CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) +// NewGetV2SyncIntegrationRequest generates requests for GetV2SyncIntegration +func NewGetV2SyncIntegrationRequest(server string, syncName SyncName) (*http.Request, error) { + var err error - // ListV2SyncIntegrationsWithResponse request - ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) + var pathParam0 string - // CreateV2SyncIntegrationWithBodyWithResponse request with any body - CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err + } - CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } - // DeleteV2SyncIntegrationWithResponse request - DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath + } - // GetV2SyncIntegrationWithResponse request - GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } - // UpdateV2SyncIntegrationWithBodyWithResponse request with any body - UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } - UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) + return req, nil } -type IndexResponse struct { - Body []byte - HTTPResponse *http.Response - JSON400 *struct { - Errors *[]string `json:"errors,omitempty"` - FieldErrors *map[string]string `json:"field_errors,omitempty"` - Message string `json:"message"` - Status int `json:"status"` +// NewUpdateV2SyncIntegrationRequest calls the generic UpdateV2SyncIntegration builder with application/json body +func NewUpdateV2SyncIntegrationRequest(server string, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err } + bodyReader = bytes.NewReader(buf) + return NewUpdateV2SyncIntegrationRequestWithBody(server, syncName, "application/json", bodyReader) } -// Status returns HTTPResponse.Status -func (r IndexResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status - } - return http.StatusText(0) -} +// NewUpdateV2SyncIntegrationRequestWithBody generates requests for UpdateV2SyncIntegration with any type of body +func NewUpdateV2SyncIntegrationRequestWithBody(server string, syncName SyncName, contentType string, body io.Reader) (*http.Request, error) { + var err error -// StatusCode returns HTTPResponse.StatusCode -func (r IndexResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode - } - return 0 -} + var pathParam0 string -type ListAllAlertsResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - Items []AlertDetail `json:"items"` - Metadata ListMetadata `json:"metadata"` + pathParam0, err = runtime.StyleParamWithLocation("simple", false, "sync_name", runtime.ParamLocationPath, syncName) + if err != nil { + return nil, err } - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} -// Status returns HTTPResponse.Status -func (r ListAllAlertsResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status + serverURL, err := url.Parse(server) + if err != nil { + return nil, err } - return http.StatusText(0) -} -// StatusCode returns HTTPResponse.StatusCode -func (r ListAllAlertsResponse) StatusCode() int { - if r.HTTPResponse != nil { - return r.HTTPResponse.StatusCode + operationPath := fmt.Sprintf("/v2/sync-integrations/%s", pathParam0) + if operationPath[0] == '/' { + operationPath = "." + operationPath } - return 0 -} -type TestUnsavedAlertResponse struct { - Body []byte - HTTPResponse *http.Response - JSON200 *struct { - // Results Notification results for the test alert - Results []AlertTestResponse `json:"results"` + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err } - JSON400 *BadRequest - JSON401 *RequiresAuthentication - JSON403 *Forbidden - JSON404 *NotFound - JSON422 *UnprocessableEntity - JSON500 *InternalError -} -// Status returns HTTPResponse.Status -func (r TestUnsavedAlertResponse) Status() string { - if r.HTTPResponse != nil { - return r.HTTPResponse.Status + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err } - return http.StatusText(0) -} + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error { + for _, r := range c.RequestEditors { + if err := r(ctx, req); err != nil { + return err + } + } + for _, r := range additionalEditors { + if err := r(ctx, req); err != nil { + return err + } + } + return nil +} + +// ClientWithResponses builds on ClientInterface to offer response payloads +type ClientWithResponses struct { + ClientInterface +} + +// NewClientWithResponses creates a new ClientWithResponses, which wraps +// Client with return type handling +func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error) { + client, err := NewClient(server, opts...) + if err != nil { + return nil, err + } + return &ClientWithResponses{client}, nil +} + +// WithBaseURL overrides the baseURL. +func WithBaseURL(baseURL string) ClientOption { + return func(c *Client) error { + newBaseURL, err := url.Parse(baseURL) + if err != nil { + return err + } + c.Server = newBaseURL.String() + return nil + } +} + +// ClientWithResponsesInterface is the interface specification for the client with responses above. +type ClientWithResponsesInterface interface { + // IndexWithResponse request + IndexWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*IndexResponse, error) + + // ListAllAlertsWithResponse request + ListAllAlertsWithResponse(ctx context.Context, params *ListAllAlertsParams, reqEditors ...RequestEditorFn) (*ListAllAlertsResponse, error) + + // TestUnsavedAlertWithBodyWithResponse request with any body + TestUnsavedAlertWithBodyWithResponse(ctx context.Context, params *TestUnsavedAlertParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) + + TestUnsavedAlertWithResponse(ctx context.Context, params *TestUnsavedAlertParams, body TestUnsavedAlertJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedAlertResponse, error) + + // ListAPIKeysWithResponse request + ListAPIKeysWithResponse(ctx context.Context, params *ListAPIKeysParams, reqEditors ...RequestEditorFn) (*ListAPIKeysResponse, error) + + // CreateAPIKeyWithBodyWithResponse request with any body + CreateAPIKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) + + CreateAPIKeyWithResponse(ctx context.Context, body CreateAPIKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAPIKeyResponse, error) + + // DeleteAPIKeyWithResponse request + DeleteAPIKeyWithResponse(ctx context.Context, apiKeyID APIKeyID, reqEditors ...RequestEditorFn) (*DeleteAPIKeyResponse, error) + + // ListAuditLogsWithResponse request + ListAuditLogsWithResponse(ctx context.Context, params *ListAuditLogsParams, reqEditors ...RequestEditorFn) (*ListAuditLogsResponse, error) + + // GetAuditLogWithResponse request + GetAuditLogWithResponse(ctx context.Context, id openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetAuditLogResponse, error) + + // GetSAMLWithResponse request + GetSAMLWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSAMLResponse, error) + + // UpdateSAMLWithBodyWithResponse request with any body + UpdateSAMLWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) + + UpdateSAMLWithResponse(ctx context.Context, body UpdateSAMLJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSAMLResponse, error) + + // DeleteSAMLRolloverCertificateWithBodyWithResponse request with any body + DeleteSAMLRolloverCertificateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSAMLRolloverCertificateResponse, error) + + DeleteSAMLRolloverCertificateWithResponse(ctx context.Context, body DeleteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSAMLRolloverCertificateResponse, error) + + // CreateSAMLRolloverCertificateWithResponse request + CreateSAMLRolloverCertificateWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateSAMLRolloverCertificateResponse, error) + + // PromoteSAMLRolloverCertificateWithBodyWithResponse request with any body + PromoteSAMLRolloverCertificateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSAMLRolloverCertificateResponse, error) + + PromoteSAMLRolloverCertificateWithResponse(ctx context.Context, body PromoteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSAMLRolloverCertificateResponse, error) + + // CreateConversationWithBodyWithResponse request with any body + CreateConversationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) + + CreateConversationWithResponse(ctx context.Context, body CreateConversationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) + + // GetConversationWithResponse request + GetConversationWithResponse(ctx context.Context, conversationID ConversationID, reqEditors ...RequestEditorFn) (*GetConversationResponse, error) + + // SendMessageWithBodyWithResponse request with any body + SendMessageWithBodyWithResponse(ctx context.Context, conversationID ConversationID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) + + SendMessageWithResponse(ctx context.Context, conversationID ConversationID, body SendMessageJSONRequestBody, reqEditors ...RequestEditorFn) (*SendMessageResponse, error) + + // ListAllCustomColumnsWithResponse request + ListAllCustomColumnsWithResponse(ctx context.Context, params *ListAllCustomColumnsParams, reqEditors ...RequestEditorFn) (*ListAllCustomColumnsResponse, error) + + // SaveCustomColumnWithBodyWithResponse request with any body + SaveCustomColumnWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) + + SaveCustomColumnWithResponse(ctx context.Context, body SaveCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveCustomColumnResponse, error) + + // DeleteCustomColumnWithResponse request + DeleteCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*DeleteCustomColumnResponse, error) + + // GetCustomColumnWithResponse request + GetCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, reqEditors ...RequestEditorFn) (*GetCustomColumnResponse, error) + + // UpdateCustomColumnWithBodyWithResponse request with any body + UpdateCustomColumnWithBodyWithResponse(ctx context.Context, customColumnID CustomColumnID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) + + UpdateCustomColumnWithResponse(ctx context.Context, customColumnID CustomColumnID, body UpdateCustomColumnJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomColumnResponse, error) + + // ListFiltersWithResponse request + ListFiltersWithResponse(ctx context.Context, params *ListFiltersParams, reqEditors ...RequestEditorFn) (*ListFiltersResponse, error) + + // ListFilterTagsWithResponse request + ListFilterTagsWithResponse(ctx context.Context, params *ListFilterTagsParams, reqEditors ...RequestEditorFn) (*ListFilterTagsResponse, error) + + // DeleteFilterWithResponse request + DeleteFilterWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*DeleteFilterResponse, error) + + // GetFilterByIDWithResponse request + GetFilterByIDWithResponse(ctx context.Context, filterID FilterID, reqEditors ...RequestEditorFn) (*GetFilterByIDResponse, error) + + // UpdateFilterWithBodyWithResponse request with any body + UpdateFilterWithBodyWithResponse(ctx context.Context, filterID FilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) + + UpdateFilterWithResponse(ctx context.Context, filterID FilterID, body UpdateFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateFilterResponse, error) + + // HealthCheckWithResponse request + HealthCheckWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckResponse, error) + + // HealthCheckHeadWithResponse request + HealthCheckHeadWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*HealthCheckHeadResponse, error) + + // ListPlatformInsightsWithResponse request + ListPlatformInsightsWithResponse(ctx context.Context, params *ListPlatformInsightsParams, reqEditors ...RequestEditorFn) (*ListPlatformInsightsResponse, error) + + // GetPlatformAssetInsightsWithResponse request + GetPlatformAssetInsightsWithResponse(ctx context.Context, assetID AssetID, params *GetPlatformAssetInsightsParams, reqEditors ...RequestEditorFn) (*GetPlatformAssetInsightsResponse, error) + + // GetPlatformInsightColumnDistinctValuesWithResponse request + GetPlatformInsightColumnDistinctValuesWithResponse(ctx context.Context, insightColumnName InsightColumnName, params *GetPlatformInsightColumnDistinctValuesParams, reqEditors ...RequestEditorFn) (*GetPlatformInsightColumnDistinctValuesResponse, error) + + // PlatformListInsightFiltersWithResponse request + PlatformListInsightFiltersWithResponse(ctx context.Context, params *PlatformListInsightFiltersParams, reqEditors ...RequestEditorFn) (*PlatformListInsightFiltersResponse, error) + + // PlatformCreateInsightFilterWithBodyWithResponse request with any body + PlatformCreateInsightFilterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PlatformCreateInsightFilterResponse, error) + + PlatformCreateInsightFilterWithResponse(ctx context.Context, body PlatformCreateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*PlatformCreateInsightFilterResponse, error) + + // PlatformDeleteInsightFilterWithResponse request + PlatformDeleteInsightFilterWithResponse(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*PlatformDeleteInsightFilterResponse, error) + + // PlatformGetInsightFilterByIDWithResponse request + PlatformGetInsightFilterByIDWithResponse(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*PlatformGetInsightFilterByIDResponse, error) + + // PlatformUpdateInsightFilterWithBodyWithResponse request with any body + PlatformUpdateInsightFilterWithBodyWithResponse(ctx context.Context, insightFilterID InsightFilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PlatformUpdateInsightFilterResponse, error) + + PlatformUpdateInsightFilterWithResponse(ctx context.Context, insightFilterID InsightFilterID, body PlatformUpdateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*PlatformUpdateInsightFilterResponse, error) + + // GetPlatformInsightWithResponse request + GetPlatformInsightWithResponse(ctx context.Context, insightID InsightID, reqEditors ...RequestEditorFn) (*GetPlatformInsightResponse, error) + + // GetPlatformInsightAssetsWithResponse request + GetPlatformInsightAssetsWithResponse(ctx context.Context, insightID InsightID, params *GetPlatformInsightAssetsParams, reqEditors ...RequestEditorFn) (*GetPlatformInsightAssetsResponse, error) + + // ListNotificationsWithResponse request + ListNotificationsWithResponse(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*ListNotificationsResponse, error) + + // DeleteNotificationDestinationWithResponse request + DeleteNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*DeleteNotificationDestinationResponse, error) + + // GetNotificationDestinationWithResponse request + GetNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*GetNotificationDestinationResponse, error) + + // UpdateNotificationDestinationWithBodyWithResponse request with any body + UpdateNotificationDestinationWithBodyWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) + + UpdateNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, body UpdateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateNotificationDestinationResponse, error) + + // GetNotificationDestinationAlertsWithResponse request + GetNotificationDestinationAlertsWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, params *GetNotificationDestinationAlertsParams, reqEditors ...RequestEditorFn) (*GetNotificationDestinationAlertsResponse, error) + + // TestNotificationDestinationWithResponse request + TestNotificationDestinationWithResponse(ctx context.Context, notificationDestinationId NotificationDestinationId, reqEditors ...RequestEditorFn) (*TestNotificationDestinationResponse, error) + + // ListAllNotificationDestinationsWithResponse request + ListAllNotificationDestinationsWithResponse(ctx context.Context, params *ListAllNotificationDestinationsParams, reqEditors ...RequestEditorFn) (*ListAllNotificationDestinationsResponse, error) + + // CreateNotificationDestinationWithBodyWithResponse request with any body + CreateNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) + + CreateNotificationDestinationWithResponse(ctx context.Context, body CreateNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateNotificationDestinationResponse, error) + + // TestUnsavedNotificationDestinationWithBodyWithResponse request with any body + TestUnsavedNotificationDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) + + TestUnsavedNotificationDestinationWithResponse(ctx context.Context, body TestUnsavedNotificationDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*TestUnsavedNotificationDestinationResponse, error) + + // CreateAWSCUROnboardingWithResponse request + CreateAWSCUROnboardingWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateAWSCUROnboardingResponse, error) + + // GetAWSCUROnboardingWithResponse request + GetAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSCUROnboardingResponse, error) + + // NotifyAWSCUROnboardingWithBodyWithResponse request with any body + NotifyAWSCUROnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyAWSCUROnboardingResponse, error) + + NotifyAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyAWSCUROnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyAWSCUROnboardingResponse, error) + + // VerifyAWSCUROnboardingWithResponse request + VerifyAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*VerifyAWSCUROnboardingResponse, error) + + // CreateAWSOnboardingWithBodyWithResponse request with any body + CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) + + CreateAWSOnboardingWithResponse(ctx context.Context, body CreateAWSOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) + + // GetAWSOnboardingWithResponse request + GetAWSOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSOnboardingResponse, error) + + // GetAWSAccountsInRootWithResponse request + GetAWSAccountsInRootWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInRootResponse, error) + + // ProvisionOnboardingConfigurationWithBodyWithResponse request with any body + ProvisionOnboardingConfigurationWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) + + ProvisionOnboardingConfigurationWithResponse(ctx context.Context, onboardingID OnboardingID, body ProvisionOnboardingConfigurationJSONRequestBody, reqEditors ...RequestEditorFn) (*ProvisionOnboardingConfigurationResponse, error) + + // GetAWSAccountsInParentWithResponse request + GetAWSAccountsInParentWithResponse(ctx context.Context, onboardingID OnboardingID, organizationalUnitID OrganizationalUnitID, reqEditors ...RequestEditorFn) (*GetAWSAccountsInParentResponse, error) + + // NotifyOnboardingWithBodyWithResponse request with any body + NotifyOnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) + + NotifyOnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyOnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyOnboardingResponse, error) + + // GetOpenAPIJSONWithResponse request + GetOpenAPIJSONWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOpenAPIJSONResponse, error) + + // GetPlatformInfoWithResponse request + GetPlatformInfoWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetPlatformInfoResponse, error) + + // ListPlatformVersionsWithResponse request + ListPlatformVersionsWithResponse(ctx context.Context, params *ListPlatformVersionsParams, reqEditors ...RequestEditorFn) (*ListPlatformVersionsResponse, error) + + // ListPluginsWithResponse request + ListPluginsWithResponse(ctx context.Context, params *ListPluginsParams, reqEditors ...RequestEditorFn) (*ListPluginsResponse, error) + + // GetPluginWithResponse request + GetPluginWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, reqEditors ...RequestEditorFn) (*GetPluginResponse, error) + + // ListPluginVersionsWithResponse request + ListPluginVersionsWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, params *ListPluginVersionsParams, reqEditors ...RequestEditorFn) (*ListPluginVersionsResponse, error) + + // GetPluginVersionWithResponse request + GetPluginVersionWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, reqEditors ...RequestEditorFn) (*GetPluginVersionResponse, error) + + // DownloadPluginAssetWithResponse request + DownloadPluginAssetWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetResponse, error) + + // ListPluginVersionTablesWithResponse request + ListPluginVersionTablesWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, params *ListPluginVersionTablesParams, reqEditors ...RequestEditorFn) (*ListPluginVersionTablesResponse, error) + + // GetPluginVersionTableWithResponse request + GetPluginVersionTableWithResponse(ctx context.Context, teamName TeamName, pluginKind PluginKind, pluginName PluginName, versionName VersionName, tableName string, reqEditors ...RequestEditorFn) (*GetPluginVersionTableResponse, error) + + // ListPoliciesWithResponse request + ListPoliciesWithResponse(ctx context.Context, params *ListPoliciesParams, reqEditors ...RequestEditorFn) (*ListPoliciesResponse, error) + + // CreatePolicyWithBodyWithResponse request with any body + CreatePolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) + + CreatePolicyWithResponse(ctx context.Context, body CreatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyResponse, error) + + // GetPolicyMetricsWithResponse request + GetPolicyMetricsWithResponse(ctx context.Context, params *GetPolicyMetricsParams, reqEditors ...RequestEditorFn) (*GetPolicyMetricsResponse, error) + + // GetViolationsByDomainWithResponse request + GetViolationsByDomainWithResponse(ctx context.Context, params *GetViolationsByDomainParams, reqEditors ...RequestEditorFn) (*GetViolationsByDomainResponse, error) + + // GetViolationsHistoryWithResponse request + GetViolationsHistoryWithResponse(ctx context.Context, params *GetViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetViolationsHistoryResponse, error) + + // DeletePolicyWithResponse request + DeletePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*DeletePolicyResponse, error) + + // GetPolicyWithResponse request + GetPolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*GetPolicyResponse, error) + + // UpdatePolicyWithBodyWithResponse request with any body + UpdatePolicyWithBodyWithResponse(ctx context.Context, policyID PolicyID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) + + UpdatePolicyWithResponse(ctx context.Context, policyID PolicyID, body UpdatePolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyResponse, error) + + // TogglePolicyWithResponse request + TogglePolicyWithResponse(ctx context.Context, policyID PolicyID, reqEditors ...RequestEditorFn) (*TogglePolicyResponse, error) + + // GetPolicyViolationsWithResponse request + GetPolicyViolationsWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsResponse, error) + + // GetPolicyViolationsHistoryWithResponse request + GetPolicyViolationsHistoryWithResponse(ctx context.Context, policyID PolicyID, params *GetPolicyViolationsHistoryParams, reqEditors ...RequestEditorFn) (*GetPolicyViolationsHistoryResponse, error) + + // ListPolicyGroupsWithResponse request + ListPolicyGroupsWithResponse(ctx context.Context, params *ListPolicyGroupsParams, reqEditors ...RequestEditorFn) (*ListPolicyGroupsResponse, error) + + // CreatePolicyGroupWithBodyWithResponse request with any body + CreatePolicyGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) + + CreatePolicyGroupWithResponse(ctx context.Context, body CreatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*CreatePolicyGroupResponse, error) + + // DeletePolicyGroupWithResponse request + DeletePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, reqEditors ...RequestEditorFn) (*DeletePolicyGroupResponse, error) + + // ListPoliciesInGroupWithResponse request + ListPoliciesInGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, params *ListPoliciesInGroupParams, reqEditors ...RequestEditorFn) (*ListPoliciesInGroupResponse, error) + + // UpdatePolicyGroupWithBodyWithResponse request with any body + UpdatePolicyGroupWithBodyWithResponse(ctx context.Context, policyGroupID PolicyGroupID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) + + UpdatePolicyGroupWithResponse(ctx context.Context, policyGroupID PolicyGroupID, body UpdatePolicyGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdatePolicyGroupResponse, error) + + // ListAllQueriesWithResponse request + ListAllQueriesWithResponse(ctx context.Context, params *ListAllQueriesParams, reqEditors ...RequestEditorFn) (*ListAllQueriesResponse, error) + + // ExecuteAdHocQueryWithBodyWithResponse request with any body + ExecuteAdHocQueryWithBodyWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) + + ExecuteAdHocQueryWithResponse(ctx context.Context, params *ExecuteAdHocQueryParams, body ExecuteAdHocQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*ExecuteAdHocQueryResponse, error) + + // SaveQueryWithBodyWithResponse request with any body + SaveQueryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) + + SaveQueryWithResponse(ctx context.Context, body SaveQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*SaveQueryResponse, error) + + // ListQueryTagsWithResponse request + ListQueryTagsWithResponse(ctx context.Context, params *ListQueryTagsParams, reqEditors ...RequestEditorFn) (*ListQueryTagsResponse, error) + + // DeleteSavedQueryWithResponse request + DeleteSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteSavedQueryResponse, error) + + // GetSavedQueryWithResponse request + GetSavedQueryWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*GetSavedQueryResponse, error) + + // UpdateQueryWithBodyWithResponse request with any body + UpdateQueryWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) + + UpdateQueryWithResponse(ctx context.Context, queryID QueryID, body UpdateQueryJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateQueryResponse, error) + + // DeleteAlertWithResponse request + DeleteAlertWithResponse(ctx context.Context, queryID QueryID, reqEditors ...RequestEditorFn) (*DeleteAlertResponse, error) + + // ExecuteSavedQueryWithResponse request + ExecuteSavedQueryWithResponse(ctx context.Context, queryID QueryID, params *ExecuteSavedQueryParams, reqEditors ...RequestEditorFn) (*ExecuteSavedQueryResponse, error) + + // QueryListFiltersWithResponse request + QueryListFiltersWithResponse(ctx context.Context, queryID QueryID, params *QueryListFiltersParams, reqEditors ...RequestEditorFn) (*QueryListFiltersResponse, error) + + // QuerySaveFilterWithBodyWithResponse request with any body + QuerySaveFilterWithBodyWithResponse(ctx context.Context, queryID QueryID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) + + QuerySaveFilterWithResponse(ctx context.Context, queryID QueryID, body QuerySaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*QuerySaveFilterResponse, error) + + // QueryListFilterTagsWithResponse request + QueryListFilterTagsWithResponse(ctx context.Context, queryID QueryID, params *QueryListFilterTagsParams, reqEditors ...RequestEditorFn) (*QueryListFilterTagsResponse, error) + + // ListAllRBACPermissionsWithResponse request + ListAllRBACPermissionsWithResponse(ctx context.Context, params *ListAllRBACPermissionsParams, reqEditors ...RequestEditorFn) (*ListAllRBACPermissionsResponse, error) + + // CreateRBACPermissionWithBodyWithResponse request with any body + CreateRBACPermissionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) + + CreateRBACPermissionWithResponse(ctx context.Context, body CreateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACPermissionResponse, error) + + // DeleteRBACPermissionWithResponse request + DeleteRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*DeleteRBACPermissionResponse, error) + + // GetRBACPermissionWithResponse request + GetRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, reqEditors ...RequestEditorFn) (*GetRBACPermissionResponse, error) + + // UpdateRBACPermissionWithBodyWithResponse request with any body + UpdateRBACPermissionWithBodyWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) + + UpdateRBACPermissionWithResponse(ctx context.Context, rbacPermissionID RBACPermissionID, body UpdateRBACPermissionJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACPermissionResponse, error) + + // ListAllRBACRolesWithResponse request + ListAllRBACRolesWithResponse(ctx context.Context, params *ListAllRBACRolesParams, reqEditors ...RequestEditorFn) (*ListAllRBACRolesResponse, error) + + // CreateRBACRoleWithBodyWithResponse request with any body + CreateRBACRoleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) + + CreateRBACRoleWithResponse(ctx context.Context, body CreateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateRBACRoleResponse, error) + + // DeleteRBACRoleWithResponse request + DeleteRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*DeleteRBACRoleResponse, error) + + // GetRBACRoleWithResponse request + GetRBACRoleWithResponse(ctx context.Context, roleID RoleID, reqEditors ...RequestEditorFn) (*GetRBACRoleResponse, error) + + // UpdateRBACRoleWithBodyWithResponse request with any body + UpdateRBACRoleWithBodyWithResponse(ctx context.Context, roleID RoleID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) + + UpdateRBACRoleWithResponse(ctx context.Context, roleID RoleID, body UpdateRBACRoleJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateRBACRoleResponse, error) + + // ListReportsWithResponse request + ListReportsWithResponse(ctx context.Context, params *ListReportsParams, reqEditors ...RequestEditorFn) (*ListReportsResponse, error) + + // CreateReportWithBodyWithResponse request with any body + CreateReportWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) + + CreateReportWithResponse(ctx context.Context, body CreateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportResponse, error) + + // ListReportTemplatesWithResponse request + ListReportTemplatesWithResponse(ctx context.Context, params *ListReportTemplatesParams, reqEditors ...RequestEditorFn) (*ListReportTemplatesResponse, error) + + // CreateReportTemplateWithBodyWithResponse request with any body + CreateReportTemplateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) + + CreateReportTemplateWithResponse(ctx context.Context, body CreateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateReportTemplateResponse, error) + + // DeleteReportTemplateWithResponse request + DeleteReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportTemplateResponse, error) + + // GetReportTemplateWithResponse request + GetReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportTemplateResponse, error) + + // UpdateReportTemplateWithBodyWithResponse request with any body + UpdateReportTemplateWithBodyWithResponse(ctx context.Context, templateId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) + + UpdateReportTemplateWithResponse(ctx context.Context, templateId openapi_types.UUID, body UpdateReportTemplateJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportTemplateResponse, error) + + // DeleteReportWithResponse request + DeleteReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*DeleteReportResponse, error) + + // GetReportWithResponse request + GetReportWithResponse(ctx context.Context, reportId openapi_types.UUID, reqEditors ...RequestEditorFn) (*GetReportResponse, error) + + // UpdateReportWithBodyWithResponse request with any body + UpdateReportWithBodyWithResponse(ctx context.Context, reportId openapi_types.UUID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) + + UpdateReportWithResponse(ctx context.Context, reportId openapi_types.UUID, body UpdateReportJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateReportResponse, error) + + // GetSettingsWithResponse request + GetSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetSettingsResponse, error) + + // UpdateSettingsWithBodyWithResponse request with any body + UpdateSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) + + UpdateSettingsWithResponse(ctx context.Context, body UpdateSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSettingsResponse, error) + + // GetDataSettingsWithResponse request + GetDataSettingsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataSettingsResponse, error) + + // UpdateDataSettingsWithBodyWithResponse request with any body + UpdateDataSettingsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) + + UpdateDataSettingsWithResponse(ctx context.Context, body UpdateDataSettingsJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateDataSettingsResponse, error) + + // CreateSlackConnectionWithBodyWithResponse request with any body + CreateSlackConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) + + CreateSlackConnectionWithResponse(ctx context.Context, body CreateSlackConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSlackConnectionResponse, error) + + // ListSlackChannelsWithResponse request + ListSlackChannelsWithResponse(ctx context.Context, id openapi_types.UUID, params *ListSlackChannelsParams, reqEditors ...RequestEditorFn) (*ListSlackChannelsResponse, error) + + // CreateSyncDestinationTestConnectionWithBodyWithResponse request with any body + CreateSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) + + CreateSyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncDestinationTestConnectionResponse, error) + + // GetSyncDestinationTestConnectionWithResponse request + GetSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionResponse, error) + + // UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) + + UpdateSyncTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationResponse, error) + + // GetSyncDestinationTestConnectionLogsLiveWithResponse request + GetSyncDestinationTestConnectionLogsLiveWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsLiveResponse, error) + + // GetSyncDestinationTestConnectionLogsQueryWithResponse request + GetSyncDestinationTestConnectionLogsQueryWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, params *GetSyncDestinationTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncDestinationTestConnectionLogsQueryResponse, error) + + // PromoteSyncDestinationTestConnectionWithBodyWithResponse request with any body + PromoteSyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) + + PromoteSyncDestinationTestConnectionWithResponse(ctx context.Context, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body PromoteSyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncDestinationTestConnectionResponse, error) + + // ListSyncDestinationsWithResponse request + ListSyncDestinationsWithResponse(ctx context.Context, params *ListSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationsResponse, error) + + // DeleteSyncDestinationWithResponse request + DeleteSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteSyncDestinationResponse, error) + + // GetSyncDestinationWithResponse request + GetSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetSyncDestinationResponse, error) + + // UpdateSyncDestinationWithBodyWithResponse request with any body + UpdateSyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) + + UpdateSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body UpdateSyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncDestinationResponse, error) + + // ListSyncDestinationSyncsWithResponse request + ListSyncDestinationSyncsWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, params *ListSyncDestinationSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncDestinationSyncsResponse, error) + + // GetTestConnectionForSyncDestinationWithResponse request + GetTestConnectionForSyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncDestinationResponse, error) + + // CreateSyncSourceTestConnectionWithBodyWithResponse request with any body + CreateSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) + + CreateSyncSourceTestConnectionWithResponse(ctx context.Context, body CreateSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncSourceTestConnectionResponse, error) + + // GetSyncSourceTestConnectionWithResponse request + GetSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionResponse, error) + + // UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) + + UpdateSyncTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceResponse, error) + + // GetSyncSourceTestConnectionLogsLiveWithResponse request + GetSyncSourceTestConnectionLogsLiveWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsLiveResponse, error) + + // GetSyncSourceTestConnectionLogsQueryWithResponse request + GetSyncSourceTestConnectionLogsQueryWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, params *GetSyncSourceTestConnectionLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncSourceTestConnectionLogsQueryResponse, error) + + // PromoteSyncSourceTestConnectionWithBodyWithResponse request with any body + PromoteSyncSourceTestConnectionWithBodyWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) + + PromoteSyncSourceTestConnectionWithResponse(ctx context.Context, syncSourceTestConnectionID SyncSourceTestConnectionID, body PromoteSyncSourceTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSyncSourceTestConnectionResponse, error) + + // ListSyncSourcesWithResponse request + ListSyncSourcesWithResponse(ctx context.Context, params *ListSyncSourcesParams, reqEditors ...RequestEditorFn) (*ListSyncSourcesResponse, error) + + // DeleteSyncSourceWithResponse request + DeleteSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*DeleteSyncSourceResponse, error) + + // GetSyncSourceWithResponse request + GetSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, reqEditors ...RequestEditorFn) (*GetSyncSourceResponse, error) + + // UpdateSyncSourceWithBodyWithResponse request with any body + UpdateSyncSourceWithBodyWithResponse(ctx context.Context, syncSourceName SyncSourceName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) + + UpdateSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, body UpdateSyncSourceJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncSourceResponse, error) + + // ListSyncSourceSyncsWithResponse request + ListSyncSourceSyncsWithResponse(ctx context.Context, syncSourceName SyncSourceName, params *ListSyncSourceSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncSourceSyncsResponse, error) + + // GetTestConnectionForSyncSourceWithResponse request + GetTestConnectionForSyncSourceWithResponse(ctx context.Context, syncSourceName SyncSourceName, syncTestConnectionId SyncTestConnectionId, reqEditors ...RequestEditorFn) (*GetTestConnectionForSyncSourceResponse, error) + + // ListSyncTransformersWithResponse request + ListSyncTransformersWithResponse(ctx context.Context, params *ListSyncTransformersParams, reqEditors ...RequestEditorFn) (*ListSyncTransformersResponse, error) + + // DeleteSyncTransformerWithResponse request + DeleteSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*DeleteSyncTransformerResponse, error) + + // GetSyncTransformerWithResponse request + GetSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, reqEditors ...RequestEditorFn) (*GetSyncTransformerResponse, error) + + // UpdateSyncTransformerWithBodyWithResponse request with any body + UpdateSyncTransformerWithBodyWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) + + UpdateSyncTransformerWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, body UpdateSyncTransformerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTransformerResponse, error) + + // ListSyncTransformerSyncDestinationsWithResponse request + ListSyncTransformerSyncDestinationsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncDestinationsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncDestinationsResponse, error) + + // ListSyncTransformerSyncsWithResponse request + ListSyncTransformerSyncsWithResponse(ctx context.Context, syncTransformerName SyncTransformerName, params *ListSyncTransformerSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncTransformerSyncsResponse, error) + + // ListSyncUpgradesWithResponse request + ListSyncUpgradesWithResponse(ctx context.Context, params *ListSyncUpgradesParams, reqEditors ...RequestEditorFn) (*ListSyncUpgradesResponse, error) + + // ListSyncsWithResponse request + ListSyncsWithResponse(ctx context.Context, params *ListSyncsParams, reqEditors ...RequestEditorFn) (*ListSyncsResponse, error) + + // CreateSyncWithBodyWithResponse request with any body + CreateSyncWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) + + CreateSyncWithResponse(ctx context.Context, body CreateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncResponse, error) + + // DeleteSyncWithResponse request + DeleteSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*DeleteSyncResponse, error) + + // GetSyncWithResponse request + GetSyncWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetSyncResponse, error) + + // UpdateSyncWithBodyWithResponse request with any body + UpdateSyncWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) + + UpdateSyncWithResponse(ctx context.Context, syncName SyncName, body UpdateSyncJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncResponse, error) + + // ListSyncRunsWithResponse request + ListSyncRunsWithResponse(ctx context.Context, syncName SyncName, params *ListSyncRunsParams, reqEditors ...RequestEditorFn) (*ListSyncRunsResponse, error) + + // CreateSyncRunWithResponse request + CreateSyncRunWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*CreateSyncRunResponse, error) + + // GetSyncRunWithResponse request + GetSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunResponse, error) + + // UpdateSyncRunWithBodyWithResponse request with any body + UpdateSyncRunWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) + + UpdateSyncRunWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body UpdateSyncRunJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncRunResponse, error) + + // GetSyncRunLogsLiveWithResponse request + GetSyncRunLogsLiveWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsLiveParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsLiveResponse, error) + + // GetSyncRunLogsQueryWithResponse request + GetSyncRunLogsQueryWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunLogsQueryParams, reqEditors ...RequestEditorFn) (*GetSyncRunLogsQueryResponse, error) + + // CreateSyncRunProgressWithBodyWithResponse request with any body + CreateSyncRunProgressWithBodyWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) + + CreateSyncRunProgressWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressResponse, error) + + // GetSyncRunStatsWithResponse request + GetSyncRunStatsWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, reqEditors ...RequestEditorFn) (*GetSyncRunStatsResponse, error) + + // GetSyncRunTablesWithResponse request + GetSyncRunTablesWithResponse(ctx context.Context, syncName SyncName, syncRunId SyncRunId, params *GetSyncRunTablesParams, reqEditors ...RequestEditorFn) (*GetSyncRunTablesResponse, error) + + // ListTablesWithResponse request + ListTablesWithResponse(ctx context.Context, params *ListTablesParams, reqEditors ...RequestEditorFn) (*ListTablesResponse, error) + + // GetTablesDataWithResponse request + GetTablesDataWithResponse(ctx context.Context, params *GetTablesDataParams, reqEditors ...RequestEditorFn) (*GetTablesDataResponse, error) + + // TablesDataActionWithBodyWithResponse request with any body + TablesDataActionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) + + TablesDataActionWithResponse(ctx context.Context, body TablesDataActionJSONRequestBody, reqEditors ...RequestEditorFn) (*TablesDataActionResponse, error) + + // GetTablesRelationsWithResponse request + GetTablesRelationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetTablesRelationsResponse, error) + + // BatchTableSchemasWithResponse request + BatchTableSchemasWithResponse(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasResponse, error) + + // TableListColumnsWithResponse request + TableListColumnsWithResponse(ctx context.Context, tableName TableName, params *TableListColumnsParams, reqEditors ...RequestEditorFn) (*TableListColumnsResponse, error) + + // TableColumnListValuesWithResponse request + TableColumnListValuesWithResponse(ctx context.Context, tableName TableName, columnName ColumnName, params *TableColumnListValuesParams, reqEditors ...RequestEditorFn) (*TableColumnListValuesResponse, error) + + // TableListRowsWithResponse request + TableListRowsWithResponse(ctx context.Context, tableName TableName, params *TableListRowsParams, reqEditors ...RequestEditorFn) (*TableListRowsResponse, error) + + // TableRowByIdWithResponse request + TableRowByIdWithResponse(ctx context.Context, tableName TableName, tableRowId TableRowId, params *TableRowByIdParams, reqEditors ...RequestEditorFn) (*TableRowByIdResponse, error) + + // TableListFiltersWithResponse request + TableListFiltersWithResponse(ctx context.Context, tableName TableName, params *TableListFiltersParams, reqEditors ...RequestEditorFn) (*TableListFiltersResponse, error) + + // TableSaveFilterWithBodyWithResponse request with any body + TableSaveFilterWithBodyWithResponse(ctx context.Context, tableName TableName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) + + TableSaveFilterWithResponse(ctx context.Context, tableName TableName, body TableSaveFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*TableSaveFilterResponse, error) + + // TableListFilterTagsWithResponse request + TableListFilterTagsWithResponse(ctx context.Context, tableName TableName, params *TableListFilterTagsParams, reqEditors ...RequestEditorFn) (*TableListFilterTagsResponse, error) + + // TableSchemaWithResponse request + TableSchemaWithResponse(ctx context.Context, tableName TableName, reqEditors ...RequestEditorFn) (*TableSchemaResponse, error) + + // ListTeamsWithResponse request + ListTeamsWithResponse(ctx context.Context, params *ListTeamsParams, reqEditors ...RequestEditorFn) (*ListTeamsResponse, error) + + // DownloadPluginAssetByTeamWithResponse request + DownloadPluginAssetByTeamWithResponse(ctx context.Context, teamName TeamName, pluginTeam PluginTeam, pluginKind PluginKind, pluginName PluginName, versionName VersionName, targetName TargetName, params *DownloadPluginAssetByTeamParams, reqEditors ...RequestEditorFn) (*DownloadPluginAssetByTeamResponse, error) + + // UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncDestinationTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) + + UpdateSyncTestConnectionForSyncDestinationTeamWithResponse(ctx context.Context, teamName TeamName, syncDestinationTestConnectionID SyncDestinationTestConnectionID, body UpdateSyncTestConnectionForSyncDestinationTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncDestinationTeamResponse, error) + + // UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse request with any body + UpdateSyncTestConnectionForSyncSourceTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) + + UpdateSyncTestConnectionForSyncSourceTeamWithResponse(ctx context.Context, teamName TeamName, syncSourceTestConnectionID SyncSourceTestConnectionID, body UpdateSyncTestConnectionForSyncSourceTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateSyncTestConnectionForSyncSourceTeamResponse, error) + + // CreateSyncRunProgressTeamWithBodyWithResponse request with any body + CreateSyncRunProgressTeamWithBodyWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) + + CreateSyncRunProgressTeamWithResponse(ctx context.Context, teamName TeamName, syncName SyncName, syncRunId SyncRunId, body CreateSyncRunProgressTeamJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateSyncRunProgressTeamResponse, error) + + // GetTeamUsageSummaryWithResponse request + GetTeamUsageSummaryWithResponse(ctx context.Context, params *GetTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetTeamUsageSummaryResponse, error) + + // GetGroupedTeamUsageSummaryWithResponse request + GetGroupedTeamUsageSummaryWithResponse(ctx context.Context, groupBy GetGroupedTeamUsageSummaryParamsGroupBy, params *GetGroupedTeamUsageSummaryParams, reqEditors ...RequestEditorFn) (*GetGroupedTeamUsageSummaryResponse, error) + + // GetCurrentUserWithResponse request + GetCurrentUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentUserResponse, error) + + // UpdateCurrentUserWithBodyWithResponse request with any body + UpdateCurrentUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) + + UpdateCurrentUserWithResponse(ctx context.Context, body UpdateCurrentUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCurrentUserResponse, error) + + // SendAnonymousEventWithBodyWithResponse request with any body + SendAnonymousEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) + + SendAnonymousEventWithResponse(ctx context.Context, body SendAnonymousEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendAnonymousEventResponse, error) + + // AuthenticateUserWithBodyWithResponse request with any body + AuthenticateUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) + + AuthenticateUserWithResponse(ctx context.Context, body AuthenticateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AuthenticateUserResponse, error) + + // ChangeUserPasswordWithBodyWithResponse request with any body + ChangeUserPasswordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) + + ChangeUserPasswordWithResponse(ctx context.Context, body ChangeUserPasswordJSONRequestBody, reqEditors ...RequestEditorFn) (*ChangeUserPasswordResponse, error) + + // UpdateCustomerWithBodyWithResponse request with any body + UpdateCustomerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) + + UpdateCustomerWithResponse(ctx context.Context, body UpdateCustomerJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateCustomerResponse, error) + + // SendUserEventWithBodyWithResponse request with any body + SendUserEventWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) + + SendUserEventWithResponse(ctx context.Context, body SendUserEventJSONRequestBody, reqEditors ...RequestEditorFn) (*SendUserEventResponse, error) + + // LogoutUserWithResponse request + LogoutUserWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*LogoutUserResponse, error) + + // LoginUserWithBodyWithResponse request with any body + LoginUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) + + LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) + + // UserTOTPDeleteWithResponse request + UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) + + // UserTOTPSetupWithResponse request + UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) + + // UserTOTPVerifyWithBodyWithResponse request with any body + UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) + + UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) + + // ListUsersWithResponse request + ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) + + // AddUserWithBodyWithResponse request with any body + AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) + + AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) + + // DeleteUserWithResponse request + DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) + + // GetUserWithResponse request + GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) + + // UpdateUserWithBodyWithResponse request with any body + UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) + + UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) + + // DeleteUserTOTPWithResponse request + DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) + + // CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with any body + CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) + + CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) + + // GetV2SyncDestinationsWithResponse request + GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) + + // CreateV2SyncDestinationWithBodyWithResponse request with any body + CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) + + CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) + + // DeleteV2SyncDestinationWithResponse request + DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) + + // GetV2SyncDestinationWithResponse request + GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) + + // PatchV2SyncDestinationWithBodyWithResponse request with any body + PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) + + PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) + + // CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with any body + CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) + + CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) + + // ListV2SyncIntegrationsWithResponse request + ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) + + // CreateV2SyncIntegrationWithBodyWithResponse request with any body + CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) + + CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) + + // DeleteV2SyncIntegrationWithResponse request + DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) + + // GetV2SyncIntegrationWithResponse request + GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) + + // UpdateV2SyncIntegrationWithBodyWithResponse request with any body + UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) + + UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) +} + +type IndexResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *struct { + Errors *[]string `json:"errors,omitempty"` + FieldErrors *map[string]string `json:"field_errors,omitempty"` + Message string `json:"message"` + Status int `json:"status"` + } +} + +// Status returns HTTPResponse.Status +func (r IndexResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r IndexResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type ListAllAlertsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []AlertDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r ListAllAlertsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ListAllAlertsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type TestUnsavedAlertResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Results Notification results for the test alert + Results []AlertTestResponse `json:"results"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r TestUnsavedAlertResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} // StatusCode returns HTTPResponse.StatusCode func (r TestUnsavedAlertResponse) StatusCode() int { @@ -22620,6 +25159,84 @@ func (r UpdateSAMLResponse) StatusCode() int { return 0 } +type DeleteSAMLRolloverCertificateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r DeleteSAMLRolloverCertificateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSAMLRolloverCertificateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type CreateSAMLRolloverCertificateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SAMLConfig + JSON400 *BadRequest + JSON404 *NotFound + JSON409 *Conflict + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r CreateSAMLRolloverCertificateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r CreateSAMLRolloverCertificateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PromoteSAMLRolloverCertificateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *SAMLConfig + JSON400 *BadRequest + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PromoteSAMLRolloverCertificateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PromoteSAMLRolloverCertificateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + type CreateConversationResponse struct { Body []byte HTTPResponse *http.Response @@ -23029,6 +25646,284 @@ func (r HealthCheckHeadResponse) StatusCode() int { return 0 } +type ListPlatformInsightsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Insight `json:"items"` + Metadata InsightsListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r ListPlatformInsightsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r ListPlatformInsightsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetPlatformAssetInsightsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []Insight `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetPlatformAssetInsightsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetPlatformAssetInsightsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetPlatformInsightColumnDistinctValuesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Values []string `json:"values"` + } + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetPlatformInsightColumnDistinctValuesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetPlatformInsightColumnDistinctValuesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PlatformListInsightFiltersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PlatformInsightFilter `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PlatformListInsightFiltersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PlatformListInsightFiltersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PlatformCreateInsightFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *PlatformInsightFilter + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PlatformCreateInsightFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PlatformCreateInsightFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PlatformDeleteInsightFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PlatformDeleteInsightFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PlatformDeleteInsightFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PlatformGetInsightFilterByIDResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformInsightFilter + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PlatformGetInsightFilterByIDResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PlatformGetInsightFilterByIDResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PlatformUpdateInsightFilterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *PlatformInsightFilter + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON422 *UnprocessableEntity + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r PlatformUpdateInsightFilterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PlatformUpdateInsightFilterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetPlatformInsightResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *Insight + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetPlatformInsightResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetPlatformInsightResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetPlatformInsightAssetsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Items []PolicyViolation `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + JSON401 *RequiresAuthentication + JSON403 *Forbidden + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetPlatformInsightAssetsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetPlatformInsightAssetsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + type ListNotificationsResponse struct { Body []byte HTTPResponse *http.Response @@ -23285,6 +26180,106 @@ func (r TestUnsavedNotificationDestinationResponse) StatusCode() int { return 0 } +type CreateAWSCUROnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *OnboardingAWSCURCreateResponse + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r CreateAWSCUROnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r CreateAWSCUROnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetAWSCUROnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *OnboardingAWSCUR + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetAWSCUROnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetAWSCUROnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type NotifyAWSCUROnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r NotifyAWSCUROnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r NotifyAWSCUROnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type VerifyAWSCUROnboardingResponse struct { + Body []byte + HTTPResponse *http.Response + JSON400 *BadRequest + JSON401 *RequiresAuthentication + JSON404 *NotFound + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r VerifyAWSCUROnboardingResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r VerifyAWSCUROnboardingResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + type CreateAWSOnboardingResponse struct { Body []byte HTTPResponse *http.Response @@ -23466,7 +26461,10 @@ type GetPlatformInfoResponse struct { HTTPResponse *http.Response JSON200 *struct { // PublicIPs List of public IPs for the platform - PublicIPs *[]string `json:"public_ips,omitempty"` + PublicIPs []string `json:"public_ips"` + + // TenantID The tenant ID of the current user + TenantID openapi_types.UUID `json:"tenant_id"` // Version Version of the platform Version string `json:"version"` @@ -26442,7 +29440,7 @@ type GetTablesDataResponse struct { HTTPResponse *http.Response JSON200 *struct { Metadata ListMetadata `json:"metadata"` - Syncs []TableDataListItem `json:"syncs"` + Sources []TableDataListItem `json:"sources"` } JSON401 *RequiresAuthentication JSON403 *Forbidden @@ -26491,6 +29489,30 @@ func (r TablesDataActionResponse) StatusCode() int { return 0 } +type GetTablesRelationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *map[string][]RelationDef + JSON401 *RequiresAuthentication + JSON500 *InternalError +} + +// Status returns HTTPResponse.Status +func (r GetTablesRelationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetTablesRelationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + type BatchTableSchemasResponse struct { Body []byte HTTPResponse *http.Response @@ -27932,6 +30954,49 @@ func (c *ClientWithResponses) UpdateSAMLWithResponse(ctx context.Context, body U return ParseUpdateSAMLResponse(rsp) } +// DeleteSAMLRolloverCertificateWithBodyWithResponse request with arbitrary body returning *DeleteSAMLRolloverCertificateResponse +func (c *ClientWithResponses) DeleteSAMLRolloverCertificateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSAMLRolloverCertificateResponse, error) { + rsp, err := c.DeleteSAMLRolloverCertificateWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSAMLRolloverCertificateResponse(rsp) +} + +func (c *ClientWithResponses) DeleteSAMLRolloverCertificateWithResponse(ctx context.Context, body DeleteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSAMLRolloverCertificateResponse, error) { + rsp, err := c.DeleteSAMLRolloverCertificate(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSAMLRolloverCertificateResponse(rsp) +} + +// CreateSAMLRolloverCertificateWithResponse request returning *CreateSAMLRolloverCertificateResponse +func (c *ClientWithResponses) CreateSAMLRolloverCertificateWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateSAMLRolloverCertificateResponse, error) { + rsp, err := c.CreateSAMLRolloverCertificate(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateSAMLRolloverCertificateResponse(rsp) +} + +// PromoteSAMLRolloverCertificateWithBodyWithResponse request with arbitrary body returning *PromoteSAMLRolloverCertificateResponse +func (c *ClientWithResponses) PromoteSAMLRolloverCertificateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PromoteSAMLRolloverCertificateResponse, error) { + rsp, err := c.PromoteSAMLRolloverCertificateWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePromoteSAMLRolloverCertificateResponse(rsp) +} + +func (c *ClientWithResponses) PromoteSAMLRolloverCertificateWithResponse(ctx context.Context, body PromoteSAMLRolloverCertificateJSONRequestBody, reqEditors ...RequestEditorFn) (*PromoteSAMLRolloverCertificateResponse, error) { + rsp, err := c.PromoteSAMLRolloverCertificate(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePromoteSAMLRolloverCertificateResponse(rsp) +} + // CreateConversationWithBodyWithResponse request with arbitrary body returning *CreateConversationResponse func (c *ClientWithResponses) CreateConversationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateConversationResponse, error) { rsp, err := c.CreateConversationWithBody(ctx, contentType, body, reqEditors...) @@ -28107,6 +31172,112 @@ func (c *ClientWithResponses) HealthCheckHeadWithResponse(ctx context.Context, r return ParseHealthCheckHeadResponse(rsp) } +// ListPlatformInsightsWithResponse request returning *ListPlatformInsightsResponse +func (c *ClientWithResponses) ListPlatformInsightsWithResponse(ctx context.Context, params *ListPlatformInsightsParams, reqEditors ...RequestEditorFn) (*ListPlatformInsightsResponse, error) { + rsp, err := c.ListPlatformInsights(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListPlatformInsightsResponse(rsp) +} + +// GetPlatformAssetInsightsWithResponse request returning *GetPlatformAssetInsightsResponse +func (c *ClientWithResponses) GetPlatformAssetInsightsWithResponse(ctx context.Context, assetID AssetID, params *GetPlatformAssetInsightsParams, reqEditors ...RequestEditorFn) (*GetPlatformAssetInsightsResponse, error) { + rsp, err := c.GetPlatformAssetInsights(ctx, assetID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPlatformAssetInsightsResponse(rsp) +} + +// GetPlatformInsightColumnDistinctValuesWithResponse request returning *GetPlatformInsightColumnDistinctValuesResponse +func (c *ClientWithResponses) GetPlatformInsightColumnDistinctValuesWithResponse(ctx context.Context, insightColumnName InsightColumnName, params *GetPlatformInsightColumnDistinctValuesParams, reqEditors ...RequestEditorFn) (*GetPlatformInsightColumnDistinctValuesResponse, error) { + rsp, err := c.GetPlatformInsightColumnDistinctValues(ctx, insightColumnName, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPlatformInsightColumnDistinctValuesResponse(rsp) +} + +// PlatformListInsightFiltersWithResponse request returning *PlatformListInsightFiltersResponse +func (c *ClientWithResponses) PlatformListInsightFiltersWithResponse(ctx context.Context, params *PlatformListInsightFiltersParams, reqEditors ...RequestEditorFn) (*PlatformListInsightFiltersResponse, error) { + rsp, err := c.PlatformListInsightFilters(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformListInsightFiltersResponse(rsp) +} + +// PlatformCreateInsightFilterWithBodyWithResponse request with arbitrary body returning *PlatformCreateInsightFilterResponse +func (c *ClientWithResponses) PlatformCreateInsightFilterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PlatformCreateInsightFilterResponse, error) { + rsp, err := c.PlatformCreateInsightFilterWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformCreateInsightFilterResponse(rsp) +} + +func (c *ClientWithResponses) PlatformCreateInsightFilterWithResponse(ctx context.Context, body PlatformCreateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*PlatformCreateInsightFilterResponse, error) { + rsp, err := c.PlatformCreateInsightFilter(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformCreateInsightFilterResponse(rsp) +} + +// PlatformDeleteInsightFilterWithResponse request returning *PlatformDeleteInsightFilterResponse +func (c *ClientWithResponses) PlatformDeleteInsightFilterWithResponse(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*PlatformDeleteInsightFilterResponse, error) { + rsp, err := c.PlatformDeleteInsightFilter(ctx, insightFilterID, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformDeleteInsightFilterResponse(rsp) +} + +// PlatformGetInsightFilterByIDWithResponse request returning *PlatformGetInsightFilterByIDResponse +func (c *ClientWithResponses) PlatformGetInsightFilterByIDWithResponse(ctx context.Context, insightFilterID InsightFilterID, reqEditors ...RequestEditorFn) (*PlatformGetInsightFilterByIDResponse, error) { + rsp, err := c.PlatformGetInsightFilterByID(ctx, insightFilterID, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformGetInsightFilterByIDResponse(rsp) +} + +// PlatformUpdateInsightFilterWithBodyWithResponse request with arbitrary body returning *PlatformUpdateInsightFilterResponse +func (c *ClientWithResponses) PlatformUpdateInsightFilterWithBodyWithResponse(ctx context.Context, insightFilterID InsightFilterID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PlatformUpdateInsightFilterResponse, error) { + rsp, err := c.PlatformUpdateInsightFilterWithBody(ctx, insightFilterID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformUpdateInsightFilterResponse(rsp) +} + +func (c *ClientWithResponses) PlatformUpdateInsightFilterWithResponse(ctx context.Context, insightFilterID InsightFilterID, body PlatformUpdateInsightFilterJSONRequestBody, reqEditors ...RequestEditorFn) (*PlatformUpdateInsightFilterResponse, error) { + rsp, err := c.PlatformUpdateInsightFilter(ctx, insightFilterID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePlatformUpdateInsightFilterResponse(rsp) +} + +// GetPlatformInsightWithResponse request returning *GetPlatformInsightResponse +func (c *ClientWithResponses) GetPlatformInsightWithResponse(ctx context.Context, insightID InsightID, reqEditors ...RequestEditorFn) (*GetPlatformInsightResponse, error) { + rsp, err := c.GetPlatformInsight(ctx, insightID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPlatformInsightResponse(rsp) +} + +// GetPlatformInsightAssetsWithResponse request returning *GetPlatformInsightAssetsResponse +func (c *ClientWithResponses) GetPlatformInsightAssetsWithResponse(ctx context.Context, insightID InsightID, params *GetPlatformInsightAssetsParams, reqEditors ...RequestEditorFn) (*GetPlatformInsightAssetsResponse, error) { + rsp, err := c.GetPlatformInsightAssets(ctx, insightID, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetPlatformInsightAssetsResponse(rsp) +} + // ListNotificationsWithResponse request returning *ListNotificationsResponse func (c *ClientWithResponses) ListNotificationsWithResponse(ctx context.Context, params *ListNotificationsParams, reqEditors ...RequestEditorFn) (*ListNotificationsResponse, error) { rsp, err := c.ListNotifications(ctx, params, reqEditors...) @@ -28212,6 +31383,50 @@ func (c *ClientWithResponses) TestUnsavedNotificationDestinationWithResponse(ctx return ParseTestUnsavedNotificationDestinationResponse(rsp) } +// CreateAWSCUROnboardingWithResponse request returning *CreateAWSCUROnboardingResponse +func (c *ClientWithResponses) CreateAWSCUROnboardingWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*CreateAWSCUROnboardingResponse, error) { + rsp, err := c.CreateAWSCUROnboarding(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateAWSCUROnboardingResponse(rsp) +} + +// GetAWSCUROnboardingWithResponse request returning *GetAWSCUROnboardingResponse +func (c *ClientWithResponses) GetAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*GetAWSCUROnboardingResponse, error) { + rsp, err := c.GetAWSCUROnboarding(ctx, onboardingID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetAWSCUROnboardingResponse(rsp) +} + +// NotifyAWSCUROnboardingWithBodyWithResponse request with arbitrary body returning *NotifyAWSCUROnboardingResponse +func (c *ClientWithResponses) NotifyAWSCUROnboardingWithBodyWithResponse(ctx context.Context, onboardingID OnboardingID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*NotifyAWSCUROnboardingResponse, error) { + rsp, err := c.NotifyAWSCUROnboardingWithBody(ctx, onboardingID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseNotifyAWSCUROnboardingResponse(rsp) +} + +func (c *ClientWithResponses) NotifyAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, body NotifyAWSCUROnboardingJSONRequestBody, reqEditors ...RequestEditorFn) (*NotifyAWSCUROnboardingResponse, error) { + rsp, err := c.NotifyAWSCUROnboarding(ctx, onboardingID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseNotifyAWSCUROnboardingResponse(rsp) +} + +// VerifyAWSCUROnboardingWithResponse request returning *VerifyAWSCUROnboardingResponse +func (c *ClientWithResponses) VerifyAWSCUROnboardingWithResponse(ctx context.Context, onboardingID OnboardingID, reqEditors ...RequestEditorFn) (*VerifyAWSCUROnboardingResponse, error) { + rsp, err := c.VerifyAWSCUROnboarding(ctx, onboardingID, reqEditors...) + if err != nil { + return nil, err + } + return ParseVerifyAWSCUROnboardingResponse(rsp) +} + // CreateAWSOnboardingWithBodyWithResponse request with arbitrary body returning *CreateAWSOnboardingResponse func (c *ClientWithResponses) CreateAWSOnboardingWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateAWSOnboardingResponse, error) { rsp, err := c.CreateAWSOnboardingWithBody(ctx, contentType, body, reqEditors...) @@ -29562,6 +32777,15 @@ func (c *ClientWithResponses) TablesDataActionWithResponse(ctx context.Context, return ParseTablesDataActionResponse(rsp) } +// GetTablesRelationsWithResponse request returning *GetTablesRelationsResponse +func (c *ClientWithResponses) GetTablesRelationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetTablesRelationsResponse, error) { + rsp, err := c.GetTablesRelations(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTablesRelationsResponse(rsp) +} + // BatchTableSchemasWithResponse request returning *BatchTableSchemasResponse func (c *ClientWithResponses) BatchTableSchemasWithResponse(ctx context.Context, params *BatchTableSchemasParams, reqEditors ...RequestEditorFn) (*BatchTableSchemasResponse, error) { rsp, err := c.BatchTableSchemas(ctx, params, reqEditors...) @@ -29864,346 +33088,1059 @@ func (c *ClientWithResponses) LoginUserWithBodyWithResponse(ctx context.Context, if err != nil { return nil, err } - return ParseLoginUserResponse(rsp) + return ParseLoginUserResponse(rsp) +} + +func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { + rsp, err := c.LoginUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseLoginUserResponse(rsp) +} + +// UserTOTPDeleteWithResponse request returning *UserTOTPDeleteResponse +func (c *ClientWithResponses) UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) { + rsp, err := c.UserTOTPDelete(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseUserTOTPDeleteResponse(rsp) +} + +// UserTOTPSetupWithResponse request returning *UserTOTPSetupResponse +func (c *ClientWithResponses) UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) { + rsp, err := c.UserTOTPSetup(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseUserTOTPSetupResponse(rsp) +} + +// UserTOTPVerifyWithBodyWithResponse request with arbitrary body returning *UserTOTPVerifyResponse +func (c *ClientWithResponses) UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { + rsp, err := c.UserTOTPVerifyWithBody(ctx, params, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUserTOTPVerifyResponse(rsp) +} + +func (c *ClientWithResponses) UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { + rsp, err := c.UserTOTPVerify(ctx, params, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUserTOTPVerifyResponse(rsp) +} + +// ListUsersWithResponse request returning *ListUsersResponse +func (c *ClientWithResponses) ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) { + rsp, err := c.ListUsers(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListUsersResponse(rsp) +} + +// AddUserWithBodyWithResponse request with arbitrary body returning *AddUserResponse +func (c *ClientWithResponses) AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { + rsp, err := c.AddUserWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAddUserResponse(rsp) +} + +func (c *ClientWithResponses) AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { + rsp, err := c.AddUser(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseAddUserResponse(rsp) +} + +// DeleteUserWithResponse request returning *DeleteUserResponse +func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) { + rsp, err := c.DeleteUser(ctx, userID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteUserResponse(rsp) +} + +// GetUserWithResponse request returning *GetUserResponse +func (c *ClientWithResponses) GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) { + rsp, err := c.GetUser(ctx, userID, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetUserResponse(rsp) +} + +// UpdateUserWithBodyWithResponse request with arbitrary body returning *UpdateUserResponse +func (c *ClientWithResponses) UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { + rsp, err := c.UpdateUserWithBody(ctx, userID, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateUserResponse(rsp) +} + +func (c *ClientWithResponses) UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { + rsp, err := c.UpdateUser(ctx, userID, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseUpdateUserResponse(rsp) +} + +// DeleteUserTOTPWithResponse request returning *DeleteUserTOTPResponse +func (c *ClientWithResponses) DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) { + rsp, err := c.DeleteUserTOTP(ctx, userID, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteUserTOTPResponse(rsp) +} + +// CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationTestConnectionResponse +func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncDestinationTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) +} + +func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncDestinationTestConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) +} + +// GetV2SyncDestinationsWithResponse request returning *GetV2SyncDestinationsResponse +func (c *ClientWithResponses) GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) { + rsp, err := c.GetV2SyncDestinations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetV2SyncDestinationsResponse(rsp) +} + +// CreateV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationResponse +func (c *ClientWithResponses) CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { + rsp, err := c.CreateV2SyncDestinationWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationResponse(rsp) +} + +func (c *ClientWithResponses) CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { + rsp, err := c.CreateV2SyncDestination(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncDestinationResponse(rsp) +} + +// DeleteV2SyncDestinationWithResponse request returning *DeleteV2SyncDestinationResponse +func (c *ClientWithResponses) DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) { + rsp, err := c.DeleteV2SyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteV2SyncDestinationResponse(rsp) +} + +// GetV2SyncDestinationWithResponse request returning *GetV2SyncDestinationResponse +func (c *ClientWithResponses) GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) { + rsp, err := c.GetV2SyncDestination(ctx, syncDestinationName, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetV2SyncDestinationResponse(rsp) +} + +// PatchV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *PatchV2SyncDestinationResponse +func (c *ClientWithResponses) PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { + rsp, err := c.PatchV2SyncDestinationWithBody(ctx, syncDestinationName, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchV2SyncDestinationResponse(rsp) +} + +func (c *ClientWithResponses) PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { + rsp, err := c.PatchV2SyncDestination(ctx, syncDestinationName, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchV2SyncDestinationResponse(rsp) +} + +// CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationTestConnectionResponse +func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncIntegrationTestConnectionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) +} + +func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { + rsp, err := c.CreateV2SyncIntegrationTestConnection(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) +} + +// ListV2SyncIntegrationsWithResponse request returning *ListV2SyncIntegrationsResponse +func (c *ClientWithResponses) ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) { + rsp, err := c.ListV2SyncIntegrations(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseListV2SyncIntegrationsResponse(rsp) } -func (c *ClientWithResponses) LoginUserWithResponse(ctx context.Context, body LoginUserJSONRequestBody, reqEditors ...RequestEditorFn) (*LoginUserResponse, error) { - rsp, err := c.LoginUser(ctx, body, reqEditors...) +// CreateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationResponse +func (c *ClientWithResponses) CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { + rsp, err := c.CreateV2SyncIntegrationWithBody(ctx, contentType, body, reqEditors...) if err != nil { return nil, err } - return ParseLoginUserResponse(rsp) + return ParseCreateV2SyncIntegrationResponse(rsp) } -// UserTOTPDeleteWithResponse request returning *UserTOTPDeleteResponse -func (c *ClientWithResponses) UserTOTPDeleteWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPDeleteResponse, error) { - rsp, err := c.UserTOTPDelete(ctx, reqEditors...) +func (c *ClientWithResponses) CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { + rsp, err := c.CreateV2SyncIntegration(ctx, body, reqEditors...) if err != nil { return nil, err } - return ParseUserTOTPDeleteResponse(rsp) + return ParseCreateV2SyncIntegrationResponse(rsp) } -// UserTOTPSetupWithResponse request returning *UserTOTPSetupResponse -func (c *ClientWithResponses) UserTOTPSetupWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*UserTOTPSetupResponse, error) { - rsp, err := c.UserTOTPSetup(ctx, reqEditors...) +// DeleteV2SyncIntegrationWithResponse request returning *DeleteV2SyncIntegrationResponse +func (c *ClientWithResponses) DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) { + rsp, err := c.DeleteV2SyncIntegration(ctx, syncName, params, reqEditors...) if err != nil { return nil, err } - return ParseUserTOTPSetupResponse(rsp) + return ParseDeleteV2SyncIntegrationResponse(rsp) } -// UserTOTPVerifyWithBodyWithResponse request with arbitrary body returning *UserTOTPVerifyResponse -func (c *ClientWithResponses) UserTOTPVerifyWithBodyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { - rsp, err := c.UserTOTPVerifyWithBody(ctx, params, contentType, body, reqEditors...) +// GetV2SyncIntegrationWithResponse request returning *GetV2SyncIntegrationResponse +func (c *ClientWithResponses) GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) { + rsp, err := c.GetV2SyncIntegration(ctx, syncName, reqEditors...) if err != nil { return nil, err } - return ParseUserTOTPVerifyResponse(rsp) + return ParseGetV2SyncIntegrationResponse(rsp) } -func (c *ClientWithResponses) UserTOTPVerifyWithResponse(ctx context.Context, params *UserTOTPVerifyParams, body UserTOTPVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*UserTOTPVerifyResponse, error) { - rsp, err := c.UserTOTPVerify(ctx, params, body, reqEditors...) +// UpdateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *UpdateV2SyncIntegrationResponse +func (c *ClientWithResponses) UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { + rsp, err := c.UpdateV2SyncIntegrationWithBody(ctx, syncName, contentType, body, reqEditors...) if err != nil { return nil, err } - return ParseUserTOTPVerifyResponse(rsp) + return ParseUpdateV2SyncIntegrationResponse(rsp) } -// ListUsersWithResponse request returning *ListUsersResponse -func (c *ClientWithResponses) ListUsersWithResponse(ctx context.Context, params *ListUsersParams, reqEditors ...RequestEditorFn) (*ListUsersResponse, error) { - rsp, err := c.ListUsers(ctx, params, reqEditors...) +func (c *ClientWithResponses) UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { + rsp, err := c.UpdateV2SyncIntegration(ctx, syncName, body, reqEditors...) if err != nil { return nil, err } - return ParseListUsersResponse(rsp) + return ParseUpdateV2SyncIntegrationResponse(rsp) } -// AddUserWithBodyWithResponse request with arbitrary body returning *AddUserResponse -func (c *ClientWithResponses) AddUserWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { - rsp, err := c.AddUserWithBody(ctx, contentType, body, reqEditors...) +// ParseIndexResponse parses an HTTP response from a IndexWithResponse call +func ParseIndexResponse(rsp *http.Response) (*IndexResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseAddUserResponse(rsp) -} -func (c *ClientWithResponses) AddUserWithResponse(ctx context.Context, body AddUserJSONRequestBody, reqEditors ...RequestEditorFn) (*AddUserResponse, error) { - rsp, err := c.AddUser(ctx, body, reqEditors...) - if err != nil { - return nil, err + response := &IndexResponse{ + Body: bodyBytes, + HTTPResponse: rsp, } - return ParseAddUserResponse(rsp) + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest struct { + Errors *[]string `json:"errors,omitempty"` + FieldErrors *map[string]string `json:"field_errors,omitempty"` + Message string `json:"message"` + Status int `json:"status"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + } + + return response, nil } -// DeleteUserWithResponse request returning *DeleteUserResponse -func (c *ClientWithResponses) DeleteUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserResponse, error) { - rsp, err := c.DeleteUser(ctx, userID, reqEditors...) +// ParseListAllAlertsResponse parses an HTTP response from a ListAllAlertsWithResponse call +func ParseListAllAlertsResponse(rsp *http.Response) (*ListAllAlertsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseDeleteUserResponse(rsp) + + response := &ListAllAlertsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []AlertDetail `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -// GetUserWithResponse request returning *GetUserResponse -func (c *ClientWithResponses) GetUserWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*GetUserResponse, error) { - rsp, err := c.GetUser(ctx, userID, reqEditors...) +// ParseTestUnsavedAlertResponse parses an HTTP response from a TestUnsavedAlertWithResponse call +func ParseTestUnsavedAlertResponse(rsp *http.Response) (*TestUnsavedAlertResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseGetUserResponse(rsp) + + response := &TestUnsavedAlertResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Results Notification results for the test alert + Results []AlertTestResponse `json:"results"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -// UpdateUserWithBodyWithResponse request with arbitrary body returning *UpdateUserResponse -func (c *ClientWithResponses) UpdateUserWithBodyWithResponse(ctx context.Context, userID UserID, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { - rsp, err := c.UpdateUserWithBody(ctx, userID, contentType, body, reqEditors...) +// ParseListAPIKeysResponse parses an HTTP response from a ListAPIKeysWithResponse call +func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseUpdateUserResponse(rsp) + + response := &ListAPIKeysResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // AllowedRoles List of allowed roles when creating a new API key + AllowedRoles []Role `json:"allowed_roles"` + Items []APIKey `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -func (c *ClientWithResponses) UpdateUserWithResponse(ctx context.Context, userID UserID, body UpdateUserJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateUserResponse, error) { - rsp, err := c.UpdateUser(ctx, userID, body, reqEditors...) +// ParseCreateAPIKeyResponse parses an HTTP response from a CreateAPIKeyWithResponse call +func ParseCreateAPIKeyResponse(rsp *http.Response) (*CreateAPIKeyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseUpdateUserResponse(rsp) + + response := &CreateAPIKeyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest APIKey + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -// DeleteUserTOTPWithResponse request returning *DeleteUserTOTPResponse -func (c *ClientWithResponses) DeleteUserTOTPWithResponse(ctx context.Context, userID UserID, reqEditors ...RequestEditorFn) (*DeleteUserTOTPResponse, error) { - rsp, err := c.DeleteUserTOTP(ctx, userID, reqEditors...) +// ParseDeleteAPIKeyResponse parses an HTTP response from a DeleteAPIKeyWithResponse call +func ParseDeleteAPIKeyResponse(rsp *http.Response) (*DeleteAPIKeyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseDeleteUserTOTPResponse(rsp) + + response := &DeleteAPIKeyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -// CreateV2SyncDestinationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationTestConnectionResponse -func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncDestinationTestConnectionWithBody(ctx, contentType, body, reqEditors...) +// ParseListAuditLogsResponse parses an HTTP response from a ListAuditLogsWithResponse call +func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) + + response := &ListAuditLogsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []AuditLogEvent `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -func (c *ClientWithResponses) CreateV2SyncDestinationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncDestinationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncDestinationTestConnection(ctx, body, reqEditors...) +// ParseGetAuditLogResponse parses an HTTP response from a GetAuditLogWithResponse call +func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseCreateV2SyncDestinationTestConnectionResponse(rsp) + + response := &GetAuditLogResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest AuditLogEvent + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil } -// GetV2SyncDestinationsWithResponse request returning *GetV2SyncDestinationsResponse -func (c *ClientWithResponses) GetV2SyncDestinationsWithResponse(ctx context.Context, params *GetV2SyncDestinationsParams, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationsResponse, error) { - rsp, err := c.GetV2SyncDestinations(ctx, params, reqEditors...) +// ParseGetSAMLResponse parses an HTTP response from a GetSAMLWithResponse call +func ParseGetSAMLResponse(rsp *http.Response) (*GetSAMLResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseGetV2SyncDestinationsResponse(rsp) -} -// CreateV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncDestinationResponse -func (c *ClientWithResponses) CreateV2SyncDestinationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { - rsp, err := c.CreateV2SyncDestinationWithBody(ctx, contentType, body, reqEditors...) - if err != nil { - return nil, err + response := &GetSAMLResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SAMLConfig + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } - return ParseCreateV2SyncDestinationResponse(rsp) -} -func (c *ClientWithResponses) CreateV2SyncDestinationWithResponse(ctx context.Context, body CreateV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncDestinationResponse, error) { - rsp, err := c.CreateV2SyncDestination(ctx, body, reqEditors...) - if err != nil { - return nil, err - } - return ParseCreateV2SyncDestinationResponse(rsp) + return response, nil } -// DeleteV2SyncDestinationWithResponse request returning *DeleteV2SyncDestinationResponse -func (c *ClientWithResponses) DeleteV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*DeleteV2SyncDestinationResponse, error) { - rsp, err := c.DeleteV2SyncDestination(ctx, syncDestinationName, reqEditors...) +// ParseUpdateSAMLResponse parses an HTTP response from a UpdateSAMLWithResponse call +func ParseUpdateSAMLResponse(rsp *http.Response) (*UpdateSAMLResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseDeleteV2SyncDestinationResponse(rsp) -} -// GetV2SyncDestinationWithResponse request returning *GetV2SyncDestinationResponse -func (c *ClientWithResponses) GetV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, reqEditors ...RequestEditorFn) (*GetV2SyncDestinationResponse, error) { - rsp, err := c.GetV2SyncDestination(ctx, syncDestinationName, reqEditors...) - if err != nil { - return nil, err + response := &UpdateSAMLResponse{ + Body: bodyBytes, + HTTPResponse: rsp, } - return ParseGetV2SyncDestinationResponse(rsp) -} -// PatchV2SyncDestinationWithBodyWithResponse request with arbitrary body returning *PatchV2SyncDestinationResponse -func (c *ClientWithResponses) PatchV2SyncDestinationWithBodyWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { - rsp, err := c.PatchV2SyncDestinationWithBody(ctx, syncDestinationName, contentType, body, reqEditors...) - if err != nil { - return nil, err - } - return ParsePatchV2SyncDestinationResponse(rsp) -} + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SAMLConfig + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest -func (c *ClientWithResponses) PatchV2SyncDestinationWithResponse(ctx context.Context, syncDestinationName SyncDestinationName, body PatchV2SyncDestinationJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchV2SyncDestinationResponse, error) { - rsp, err := c.PatchV2SyncDestination(ctx, syncDestinationName, body, reqEditors...) - if err != nil { - return nil, err } - return ParsePatchV2SyncDestinationResponse(rsp) + + return response, nil } -// CreateV2SyncIntegrationTestConnectionWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationTestConnectionResponse -func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncIntegrationTestConnectionWithBody(ctx, contentType, body, reqEditors...) +// ParseDeleteSAMLRolloverCertificateResponse parses an HTTP response from a DeleteSAMLRolloverCertificateWithResponse call +func ParseDeleteSAMLRolloverCertificateResponse(rsp *http.Response) (*DeleteSAMLRolloverCertificateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) -} -func (c *ClientWithResponses) CreateV2SyncIntegrationTestConnectionWithResponse(ctx context.Context, body CreateV2SyncIntegrationTestConnectionJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationTestConnectionResponse, error) { - rsp, err := c.CreateV2SyncIntegrationTestConnection(ctx, body, reqEditors...) - if err != nil { - return nil, err + response := &DeleteSAMLRolloverCertificateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, } - return ParseCreateV2SyncIntegrationTestConnectionResponse(rsp) -} -// ListV2SyncIntegrationsWithResponse request returning *ListV2SyncIntegrationsResponse -func (c *ClientWithResponses) ListV2SyncIntegrationsWithResponse(ctx context.Context, params *ListV2SyncIntegrationsParams, reqEditors ...RequestEditorFn) (*ListV2SyncIntegrationsResponse, error) { - rsp, err := c.ListV2SyncIntegrations(ctx, params, reqEditors...) - if err != nil { - return nil, err + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } - return ParseListV2SyncIntegrationsResponse(rsp) + + return response, nil } -// CreateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *CreateV2SyncIntegrationResponse -func (c *ClientWithResponses) CreateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { - rsp, err := c.CreateV2SyncIntegrationWithBody(ctx, contentType, body, reqEditors...) +// ParseCreateSAMLRolloverCertificateResponse parses an HTTP response from a CreateSAMLRolloverCertificateWithResponse call +func ParseCreateSAMLRolloverCertificateResponse(rsp *http.Response) (*CreateSAMLRolloverCertificateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseCreateV2SyncIntegrationResponse(rsp) -} -func (c *ClientWithResponses) CreateV2SyncIntegrationWithResponse(ctx context.Context, body CreateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateV2SyncIntegrationResponse, error) { - rsp, err := c.CreateV2SyncIntegration(ctx, body, reqEditors...) - if err != nil { - return nil, err + response := &CreateSAMLRolloverCertificateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, } - return ParseCreateV2SyncIntegrationResponse(rsp) -} -// DeleteV2SyncIntegrationWithResponse request returning *DeleteV2SyncIntegrationResponse -func (c *ClientWithResponses) DeleteV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, params *DeleteV2SyncIntegrationParams, reqEditors ...RequestEditorFn) (*DeleteV2SyncIntegrationResponse, error) { - rsp, err := c.DeleteV2SyncIntegration(ctx, syncName, params, reqEditors...) - if err != nil { - return nil, err + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SAMLConfig + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest Conflict + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } - return ParseDeleteV2SyncIntegrationResponse(rsp) + + return response, nil } -// GetV2SyncIntegrationWithResponse request returning *GetV2SyncIntegrationResponse -func (c *ClientWithResponses) GetV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, reqEditors ...RequestEditorFn) (*GetV2SyncIntegrationResponse, error) { - rsp, err := c.GetV2SyncIntegration(ctx, syncName, reqEditors...) +// ParsePromoteSAMLRolloverCertificateResponse parses an HTTP response from a PromoteSAMLRolloverCertificateWithResponse call +func ParsePromoteSAMLRolloverCertificateResponse(rsp *http.Response) (*PromoteSAMLRolloverCertificateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - return ParseGetV2SyncIntegrationResponse(rsp) -} -// UpdateV2SyncIntegrationWithBodyWithResponse request with arbitrary body returning *UpdateV2SyncIntegrationResponse -func (c *ClientWithResponses) UpdateV2SyncIntegrationWithBodyWithResponse(ctx context.Context, syncName SyncName, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { - rsp, err := c.UpdateV2SyncIntegrationWithBody(ctx, syncName, contentType, body, reqEditors...) - if err != nil { - return nil, err + response := &PromoteSAMLRolloverCertificateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, } - return ParseUpdateV2SyncIntegrationResponse(rsp) -} -func (c *ClientWithResponses) UpdateV2SyncIntegrationWithResponse(ctx context.Context, syncName SyncName, body UpdateV2SyncIntegrationJSONRequestBody, reqEditors ...RequestEditorFn) (*UpdateV2SyncIntegrationResponse, error) { - rsp, err := c.UpdateV2SyncIntegration(ctx, syncName, body, reqEditors...) - if err != nil { - return nil, err + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest SAMLConfig + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } - return ParseUpdateV2SyncIntegrationResponse(rsp) + + return response, nil } -// ParseIndexResponse parses an HTTP response from a IndexWithResponse call -func ParseIndexResponse(rsp *http.Response) (*IndexResponse, error) { +// ParseCreateConversationResponse parses an HTTP response from a CreateConversationWithResponse call +func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &IndexResponse{ + response := &CreateConversationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest struct { - Errors *[]string `json:"errors,omitempty"` - FieldErrors *map[string]string `json:"field_errors,omitempty"` - Message string `json:"message"` - Status int `json:"status"` + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest Conversation + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest TooManyRequests + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + } return response, nil } -// ParseListAllAlertsResponse parses an HTTP response from a ListAllAlertsWithResponse call -func ParseListAllAlertsResponse(rsp *http.Response) (*ListAllAlertsResponse, error) { +// ParseGetConversationResponse parses an HTTP response from a GetConversationWithResponse call +func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllAlertsResponse{ + response := &GetConversationResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []AlertDetail `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest Conversation if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON401 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -30231,29 +34168,26 @@ func ParseListAllAlertsResponse(rsp *http.Response) (*ListAllAlertsResponse, err return response, nil } -// ParseTestUnsavedAlertResponse parses an HTTP response from a TestUnsavedAlertWithResponse call -func ParseTestUnsavedAlertResponse(rsp *http.Response) (*TestUnsavedAlertResponse, error) { +// ParseSendMessageResponse parses an HTTP response from a SendMessageWithResponse call +func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &TestUnsavedAlertResponse{ + response := &SendMessageResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - // Results Notification results for the test alert - Results []AlertTestResponse `json:"results"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest ConversationMessage if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -30302,15 +34236,15 @@ func ParseTestUnsavedAlertResponse(rsp *http.Response) (*TestUnsavedAlertRespons return response, nil } -// ParseListAPIKeysResponse parses an HTTP response from a ListAPIKeysWithResponse call -func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) { +// ParseListAllCustomColumnsResponse parses an HTTP response from a ListAllCustomColumnsWithResponse call +func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumnsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAPIKeysResponse{ + response := &ListAllCustomColumnsResponse{ Body: bodyBytes, HTTPResponse: rsp, } @@ -30318,16 +34252,21 @@ func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { - // AllowedRoles List of allowed roles when creating a new API key - AllowedRoles []Role `json:"allowed_roles"` - Items []APIKey `json:"items"` - Metadata ListMetadata `json:"metadata"` + Items []CustomColumn `json:"items"` + Metadata ListMetadata `json:"metadata"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30335,6 +34274,13 @@ func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) } response.JSON401 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30342,6 +34288,13 @@ func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30354,22 +34307,22 @@ func ParseListAPIKeysResponse(rsp *http.Response) (*ListAPIKeysResponse, error) return response, nil } -// ParseCreateAPIKeyResponse parses an HTTP response from a CreateAPIKeyWithResponse call -func ParseCreateAPIKeyResponse(rsp *http.Response) (*CreateAPIKeyResponse, error) { +// ParseSaveCustomColumnResponse parses an HTTP response from a SaveCustomColumnWithResponse call +func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateAPIKeyResponse{ + response := &SaveCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest APIKey + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -30396,6 +34349,13 @@ func ParseCreateAPIKeyResponse(rsp *http.Response) (*CreateAPIKeyResponse, error } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30415,33 +34375,33 @@ func ParseCreateAPIKeyResponse(rsp *http.Response) (*CreateAPIKeyResponse, error return response, nil } -// ParseDeleteAPIKeyResponse parses an HTTP response from a DeleteAPIKeyWithResponse call -func ParseDeleteAPIKeyResponse(rsp *http.Response) (*DeleteAPIKeyResponse, error) { +// ParseDeleteCustomColumnResponse parses an HTTP response from a DeleteCustomColumnWithResponse call +func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteAPIKeyResponse{ + response := &DeleteCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -30469,25 +34429,22 @@ func ParseDeleteAPIKeyResponse(rsp *http.Response) (*DeleteAPIKeyResponse, error return response, nil } -// ParseListAuditLogsResponse parses an HTTP response from a ListAuditLogsWithResponse call -func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, error) { +// ParseGetCustomColumnResponse parses an HTTP response from a GetCustomColumnWithResponse call +func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAuditLogsResponse{ + response := &GetCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []AuditLogEvent `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -30507,6 +34464,20 @@ func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, err } response.JSON403 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30519,27 +34490,34 @@ func ParseListAuditLogsResponse(rsp *http.Response) (*ListAuditLogsResponse, err return response, nil } -// ParseGetAuditLogResponse parses an HTTP response from a GetAuditLogWithResponse call -func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) { +// ParseUpdateCustomColumnResponse parses an HTTP response from a UpdateCustomColumnWithResponse call +func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetAuditLogResponse{ + response := &UpdateCustomColumnResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest AuditLogEvent + var dest CustomColumn if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30561,6 +34539,13 @@ func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) } response.JSON404 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30573,33 +34558,57 @@ func ParseGetAuditLogResponse(rsp *http.Response) (*GetAuditLogResponse, error) return response, nil } -// ParseGetSAMLResponse parses an HTTP response from a GetSAMLWithResponse call -func ParseGetSAMLResponse(rsp *http.Response) (*GetSAMLResponse, error) { +// ParseListFiltersResponse parses an HTTP response from a ListFiltersWithResponse call +func ParseListFiltersResponse(rsp *http.Response) (*ListFiltersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetSAMLResponse{ + response := &ListFiltersResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SAMLConfig + var dest struct { + Items []Filter `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -30613,33 +34622,43 @@ func ParseGetSAMLResponse(rsp *http.Response) (*GetSAMLResponse, error) { return response, nil } -// ParseUpdateSAMLResponse parses an HTTP response from a UpdateSAMLWithResponse call -func ParseUpdateSAMLResponse(rsp *http.Response) (*UpdateSAMLResponse, error) { +// ParseListFilterTagsResponse parses an HTTP response from a ListFilterTagsWithResponse call +func ParseListFilterTagsResponse(rsp *http.Response) (*ListFilterTagsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateSAMLResponse{ + response := &ListFilterTagsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest SAMLConfig + var dest struct { + Items []FilterTag `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -30667,47 +34686,47 @@ func ParseUpdateSAMLResponse(rsp *http.Response) (*UpdateSAMLResponse, error) { return response, nil } -// ParseCreateConversationResponse parses an HTTP response from a CreateConversationWithResponse call -func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationResponse, error) { +// ParseDeleteFilterResponse parses an HTTP response from a DeleteFilterWithResponse call +func ParseDeleteFilterResponse(rsp *http.Response) (*DeleteFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &CreateConversationResponse{ + response := &DeleteFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest Conversation + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: - var dest TooManyRequests + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON429 = &dest + response.JSON422 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -30721,40 +34740,40 @@ func ParseCreateConversationResponse(rsp *http.Response) (*CreateConversationRes return response, nil } -// ParseGetConversationResponse parses an HTTP response from a GetConversationWithResponse call -func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, error) { +// ParseGetFilterByIDResponse parses an HTTP response from a GetFilterByIDWithResponse call +func ParseGetFilterByIDResponse(rsp *http.Response) (*GetFilterByIDResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetConversationResponse{ + response := &GetFilterByIDResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Conversation + var dest Filter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON403 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: var dest NotFound @@ -30782,33 +34801,26 @@ func ParseGetConversationResponse(rsp *http.Response) (*GetConversationResponse, return response, nil } -// ParseSendMessageResponse parses an HTTP response from a SendMessageWithResponse call -func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) { +// ParseUpdateFilterResponse parses an HTTP response from a UpdateFilterWithResponse call +func ParseUpdateFilterResponse(rsp *http.Response) (*UpdateFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SendMessageResponse{ + response := &UpdateFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest ConversationMessage - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON201 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest Filter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -30850,30 +34862,20 @@ func ParseSendMessageResponse(rsp *http.Response) (*SendMessageResponse, error) return response, nil } -// ParseListAllCustomColumnsResponse parses an HTTP response from a ListAllCustomColumnsWithResponse call -func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumnsResponse, error) { +// ParseHealthCheckResponse parses an HTTP response from a HealthCheckWithResponse call +func ParseHealthCheckResponse(rsp *http.Response) (*HealthCheckResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListAllCustomColumnsResponse{ + response := &HealthCheckResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []CustomColumn `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30881,33 +34883,45 @@ func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumn } response.JSON400 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: - var dest RequiresAuthentication + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON401 = &dest + response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: - var dest Forbidden + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest ServiceUnavailable if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON403 = &dest + response.JSON503 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest + } - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity + return response, nil +} + +// ParseHealthCheckHeadResponse parses an HTTP response from a HealthCheckHeadWithResponse call +func ParseHealthCheckHeadResponse(rsp *http.Response) (*HealthCheckHeadResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &HealthCheckHeadResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON422 = &dest + response.JSON400 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -30916,31 +34930,41 @@ func ParseListAllCustomColumnsResponse(rsp *http.Response) (*ListAllCustomColumn } response.JSON500 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest ServiceUnavailable + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + } return response, nil } -// ParseSaveCustomColumnResponse parses an HTTP response from a SaveCustomColumnWithResponse call -func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnResponse, error) { +// ParseListPlatformInsightsResponse parses an HTTP response from a ListPlatformInsightsWithResponse call +func ParseListPlatformInsightsResponse(rsp *http.Response) (*ListPlatformInsightsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &SaveCustomColumnResponse{ + response := &ListPlatformInsightsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: - var dest CustomColumn + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []Insight `json:"items"` + Metadata InsightsListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON201 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: var dest BadRequest @@ -30963,20 +34987,6 @@ func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnRespons } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -30989,20 +34999,37 @@ func ParseSaveCustomColumnResponse(rsp *http.Response) (*SaveCustomColumnRespons return response, nil } -// ParseDeleteCustomColumnResponse parses an HTTP response from a DeleteCustomColumnWithResponse call -func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnResponse, error) { +// ParseGetPlatformAssetInsightsResponse parses an HTTP response from a GetPlatformAssetInsightsWithResponse call +func ParseGetPlatformAssetInsightsResponse(rsp *http.Response) (*GetPlatformAssetInsightsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteCustomColumnResponse{ + response := &GetPlatformAssetInsightsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []Insight `json:"items"` + Metadata ListMetadata `json:"metadata"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31024,13 +35051,6 @@ func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnRes } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31043,27 +35063,36 @@ func ParseDeleteCustomColumnResponse(rsp *http.Response) (*DeleteCustomColumnRes return response, nil } -// ParseGetCustomColumnResponse parses an HTTP response from a GetCustomColumnWithResponse call -func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, error) { +// ParseGetPlatformInsightColumnDistinctValuesResponse parses an HTTP response from a GetPlatformInsightColumnDistinctValuesWithResponse call +func ParseGetPlatformInsightColumnDistinctValuesResponse(rsp *http.Response) (*GetPlatformInsightColumnDistinctValuesResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetCustomColumnResponse{ + response := &GetPlatformInsightColumnDistinctValuesResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest CustomColumn + var dest struct { + Values []string `json:"values"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31078,20 +35107,6 @@ func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31104,33 +35119,29 @@ func ParseGetCustomColumnResponse(rsp *http.Response) (*GetCustomColumnResponse, return response, nil } -// ParseUpdateCustomColumnResponse parses an HTTP response from a UpdateCustomColumnWithResponse call -func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnResponse, error) { +// ParsePlatformListInsightFiltersResponse parses an HTTP response from a PlatformListInsightFiltersWithResponse call +func ParsePlatformListInsightFiltersResponse(rsp *http.Response) (*PlatformListInsightFiltersResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateCustomColumnResponse{ + response := &PlatformListInsightFiltersResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest CustomColumn - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err + var dest struct { + Items []PlatformInsightFilter `json:"items"` + Metadata ListMetadata `json:"metadata"` } - response.JSON200 = &dest - - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -31172,29 +35183,26 @@ func ParseUpdateCustomColumnResponse(rsp *http.Response) (*UpdateCustomColumnRes return response, nil } -// ParseListFiltersResponse parses an HTTP response from a ListFiltersWithResponse call -func ParseListFiltersResponse(rsp *http.Response) (*ListFiltersResponse, error) { +// ParsePlatformCreateInsightFilterResponse parses an HTTP response from a PlatformCreateInsightFilterWithResponse call +func ParsePlatformCreateInsightFilterResponse(rsp *http.Response) (*PlatformCreateInsightFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListFiltersResponse{ + response := &PlatformCreateInsightFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []Filter `json:"items"` - Metadata ListMetadata `json:"metadata"` - } + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest PlatformInsightFilter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON200 = &dest + response.JSON201 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication @@ -31210,13 +35218,6 @@ func ParseListFiltersResponse(rsp *http.Response) (*ListFiltersResponse, error) } response.JSON403 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: - var dest NotFound - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: var dest UnprocessableEntity if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31236,30 +35237,20 @@ func ParseListFiltersResponse(rsp *http.Response) (*ListFiltersResponse, error) return response, nil } -// ParseListFilterTagsResponse parses an HTTP response from a ListFilterTagsWithResponse call -func ParseListFilterTagsResponse(rsp *http.Response) (*ListFilterTagsResponse, error) { +// ParsePlatformDeleteInsightFilterResponse parses an HTTP response from a PlatformDeleteInsightFilterWithResponse call +func ParsePlatformDeleteInsightFilterResponse(rsp *http.Response) (*PlatformDeleteInsightFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &ListFilterTagsResponse{ + response := &PlatformDeleteInsightFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest struct { - Items []FilterTag `json:"items"` - Metadata ListMetadata `json:"metadata"` - } - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31300,20 +35291,27 @@ func ParseListFilterTagsResponse(rsp *http.Response) (*ListFilterTagsResponse, e return response, nil } -// ParseDeleteFilterResponse parses an HTTP response from a DeleteFilterWithResponse call -func ParseDeleteFilterResponse(rsp *http.Response) (*DeleteFilterResponse, error) { +// ParsePlatformGetInsightFilterByIDResponse parses an HTTP response from a PlatformGetInsightFilterByIDWithResponse call +func ParsePlatformGetInsightFilterByIDResponse(rsp *http.Response) (*PlatformGetInsightFilterByIDResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &DeleteFilterResponse{ + response := &PlatformGetInsightFilterByIDResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest PlatformInsightFilter + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31354,22 +35352,22 @@ func ParseDeleteFilterResponse(rsp *http.Response) (*DeleteFilterResponse, error return response, nil } -// ParseGetFilterByIDResponse parses an HTTP response from a GetFilterByIDWithResponse call -func ParseGetFilterByIDResponse(rsp *http.Response) (*GetFilterByIDResponse, error) { +// ParsePlatformUpdateInsightFilterResponse parses an HTTP response from a PlatformUpdateInsightFilterWithResponse call +func ParsePlatformUpdateInsightFilterResponse(rsp *http.Response) (*PlatformUpdateInsightFilterResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &GetFilterByIDResponse{ + response := &PlatformUpdateInsightFilterResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Filter + var dest PlatformInsightFilter if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -31415,22 +35413,22 @@ func ParseGetFilterByIDResponse(rsp *http.Response) (*GetFilterByIDResponse, err return response, nil } -// ParseUpdateFilterResponse parses an HTTP response from a UpdateFilterWithResponse call -func ParseUpdateFilterResponse(rsp *http.Response) (*UpdateFilterResponse, error) { +// ParseGetPlatformInsightResponse parses an HTTP response from a GetPlatformInsightWithResponse call +func ParseGetPlatformInsightResponse(rsp *http.Response) (*GetPlatformInsightResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &UpdateFilterResponse{ + response := &GetPlatformInsightResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: - var dest Filter + var dest Insight if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } @@ -31457,13 +35455,6 @@ func ParseUpdateFilterResponse(rsp *http.Response) (*UpdateFilterResponse, error } response.JSON404 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: - var dest UnprocessableEntity - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON422 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError if err := json.Unmarshal(bodyBytes, &dest); err != nil { @@ -31476,66 +35467,50 @@ func ParseUpdateFilterResponse(rsp *http.Response) (*UpdateFilterResponse, error return response, nil } -// ParseHealthCheckResponse parses an HTTP response from a HealthCheckWithResponse call -func ParseHealthCheckResponse(rsp *http.Response) (*HealthCheckResponse, error) { +// ParseGetPlatformInsightAssetsResponse parses an HTTP response from a GetPlatformInsightAssetsWithResponse call +func ParseGetPlatformInsightAssetsResponse(rsp *http.Response) (*GetPlatformInsightAssetsResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) defer func() { _ = rsp.Body.Close() }() if err != nil { return nil, err } - response := &HealthCheckResponse{ + response := &GetPlatformInsightAssetsResponse{ Body: bodyBytes, HTTPResponse: rsp, } switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Items []PolicyViolation `json:"items"` + Metadata ListMetadata `json:"metadata"` + } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON200 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: - var dest InternalError + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON500 = &dest + response.JSON401 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: - var dest ServiceUnavailable + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest Forbidden if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON503 = &dest - - } - - return response, nil -} - -// ParseHealthCheckHeadResponse parses an HTTP response from a HealthCheckHeadWithResponse call -func ParseHealthCheckHeadResponse(rsp *http.Response) (*HealthCheckHeadResponse, error) { - bodyBytes, err := io.ReadAll(rsp.Body) - defer func() { _ = rsp.Body.Close() }() - if err != nil { - return nil, err - } - - response := &HealthCheckHeadResponse{ - Body: bodyBytes, - HTTPResponse: rsp, - } + response.JSON403 = &dest - switch { - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: - var dest BadRequest + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err } - response.JSON400 = &dest + response.JSON404 = &dest case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: var dest InternalError @@ -31544,13 +35519,6 @@ func ParseHealthCheckHeadResponse(rsp *http.Response) (*HealthCheckHeadResponse, } response.JSON500 = &dest - case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: - var dest ServiceUnavailable - if err := json.Unmarshal(bodyBytes, &dest); err != nil { - return nil, err - } - response.JSON503 = &dest - } return response, nil @@ -32142,6 +36110,194 @@ func ParseTestUnsavedNotificationDestinationResponse(rsp *http.Response) (*TestU return response, nil } +// ParseCreateAWSCUROnboardingResponse parses an HTTP response from a CreateAWSCUROnboardingWithResponse call +func ParseCreateAWSCUROnboardingResponse(rsp *http.Response) (*CreateAWSCUROnboardingResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &CreateAWSCUROnboardingResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest OnboardingAWSCURCreateResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseGetAWSCUROnboardingResponse parses an HTTP response from a GetAWSCUROnboardingWithResponse call +func ParseGetAWSCUROnboardingResponse(rsp *http.Response) (*GetAWSCUROnboardingResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetAWSCUROnboardingResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest OnboardingAWSCUR + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseNotifyAWSCUROnboardingResponse parses an HTTP response from a NotifyAWSCUROnboardingWithResponse call +func ParseNotifyAWSCUROnboardingResponse(rsp *http.Response) (*NotifyAWSCUROnboardingResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &NotifyAWSCUROnboardingResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + +// ParseVerifyAWSCUROnboardingResponse parses an HTTP response from a VerifyAWSCUROnboardingWithResponse call +func ParseVerifyAWSCUROnboardingResponse(rsp *http.Response) (*VerifyAWSCUROnboardingResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &VerifyAWSCUROnboardingResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest BadRequest + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NotFound + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + // ParseCreateAWSOnboardingResponse parses an HTTP response from a CreateAWSOnboardingWithResponse call func ParseCreateAWSOnboardingResponse(rsp *http.Response) (*CreateAWSOnboardingResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) @@ -32495,7 +36651,10 @@ func ParseGetPlatformInfoResponse(rsp *http.Response) (*GetPlatformInfoResponse, case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { // PublicIPs List of public IPs for the platform - PublicIPs *[]string `json:"public_ips,omitempty"` + PublicIPs []string `json:"public_ips"` + + // TenantID The tenant ID of the current user + TenantID openapi_types.UUID `json:"tenant_id"` // Version Version of the platform Version string `json:"version"` @@ -38658,7 +42817,7 @@ func ParseGetTablesDataResponse(rsp *http.Response) (*GetTablesDataResponse, err case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: var dest struct { Metadata ListMetadata `json:"metadata"` - Syncs []TableDataListItem `json:"syncs"` + Sources []TableDataListItem `json:"sources"` } if err := json.Unmarshal(bodyBytes, &dest); err != nil { return nil, err @@ -38745,6 +42904,46 @@ func ParseTablesDataActionResponse(rsp *http.Response) (*TablesDataActionRespons return response, nil } +// ParseGetTablesRelationsResponse parses an HTTP response from a GetTablesRelationsWithResponse call +func ParseGetTablesRelationsResponse(rsp *http.Response) (*GetTablesRelationsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetTablesRelationsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest map[string][]RelationDef + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 401: + var dest RequiresAuthentication + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON401 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 500: + var dest InternalError + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON500 = &dest + + } + + return response, nil +} + // ParseBatchTableSchemasResponse parses an HTTP response from a BatchTableSchemasWithResponse call func ParseBatchTableSchemasResponse(rsp *http.Response) (*BatchTableSchemasResponse, error) { bodyBytes, err := io.ReadAll(rsp.Body) diff --git a/spec.json b/spec.json index e69ac15..89f4d85 100644 --- a/spec.json +++ b/spec.json @@ -6,7 +6,7 @@ "name": "CloudQuery Support Team", "url": "https://cloudquery.io" }, - "description": "Welcome to the CloudQuery Platform API documentation! This API can be used to interact with the CloudQuery platform. As a user, the API allows you to search the CloudQuery asset inventory, run SQL queries against the data warehouse, save and load searches, and much more. As an administrator, it allows you to manage your teams, syncs, and other objects.\n### Authentication\nThe API is secured using bearer tokens. To get started, you can generate an API key for your Platform deployment from your platform dashboard. For a step-by-step guide, see: https://docs.cloudquery.io/docs/deployment/generate-api-key.\nThe base URL for the API depends on where your CloudQuery Platform is hosted. If running locally, this is usually http://localhost:3000/api. In a production deployment it should be an HTTPS URL. For purposes of illustration, we will assume the platform instance is available at https://cloudquery.mycompany.com. In this case, the base API endpoint will be https://cloudquery.mycompany.com/api.\n### Example Request\nTo test your connection to the API, we can use the `/plugins` endpoint. For example:\n`curl -v -H \"Authorization: Bearer $CLOUDQUERY_API_KEY\" \\ https://cloudquery.mycompany.com/api/plugins`\n", + "description": "Welcome to the CloudQuery Platform API documentation! This API can be used to interact with the CloudQuery platform. As a user, the API allows you to search the CloudQuery asset inventory, run SQL queries against the data warehouse, save and load searches, and much more. As an administrator, it allows you to manage your teams, syncs, and other objects.\n### Authentication\nThe API is secured using bearer tokens. To get started, you can generate an API key for your Platform deployment from your platform dashboard. For a step-by-step guide, see: https://www.cloudquery.io/docs/cli/managing-cloudquery/deployments/generate-api-key.\nThe base URL for the API depends on where your CloudQuery Platform is hosted. If running locally, this is usually http://localhost:3000/api. In a production deployment it should be an HTTPS URL. For purposes of illustration, we will assume the platform instance is available at https://cloudquery.mycompany.com. In this case, the base API endpoint will be https://cloudquery.mycompany.com/api.\n### Example Request\nTo test your connection to the API, we can use the `/plugins` endpoint. For example:\n`curl -v -H \"Authorization: Bearer $CLOUDQUERY_API_KEY\" \\ https://cloudquery.mycompany.com/api/plugins`\n", "license": { "name": "MIT", "url": "https://spdx.org/licenses/MIT" @@ -70,6 +70,9 @@ { "name": "queries" }, + { + "name": "insights" + }, { "name": "reports" }, @@ -396,8 +399,9 @@ "application/json": { "schema": { "required": [ - "items", - "version" + "public_ips", + "version", + "tenant_id" ], "properties": { "public_ips": { @@ -411,6 +415,12 @@ "version": { "type": "string", "description": "Version of the platform" + }, + "tenant_id": { + "type": "string", + "format": "uuid", + "description": "The tenant ID of the current user", + "x-go-name": "TenantID" } } } @@ -3626,6 +3636,136 @@ } } }, + "/onboardings/aws/cur": { + "post": { + "operationId": "CreateAWSCUROnboarding", + "description": "Create an interactive onboarding for AWS CUR", + "tags": [ + "onboardings" + ], + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/OnboardingAWSCURCreateResponse" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/onboardings/aws/cur/{onboarding_id}": { + "get": { + "operationId": "GetAWSCUROnboarding", + "description": "Query an interactive onboarding for AWS CUR", + "parameters": [ + { + "$ref": "#/components/parameters/onboarding_id" + } + ], + "tags": [ + "onboardings" + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/OnboardingAWSCUR" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/onboardings/aws/cur/{onboarding_id}/notify": { + "post": { + "operationId": "NotifyAWSCUROnboarding", + "description": "Update AWS CUR onboarding state", + "tags": [ + "onboardings" + ], + "parameters": [ + { + "$ref": "#/components/parameters/onboarding_id" + } + ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/OnboardingAWSCURNotification" + } + } + } + }, + "responses": { + "202": {}, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/onboardings/aws/cur/{onboarding_id}/verify": { + "post": { + "operationId": "VerifyAWSCUROnboarding", + "description": "Trigger verification of the AWS CUR onboarding", + "tags": [ + "onboardings" + ], + "parameters": [ + { + "$ref": "#/components/parameters/onboarding_id" + } + ], + "responses": { + "202": {}, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, "/queries": { "get": { "description": "List all queries", @@ -3654,6 +3794,9 @@ }, { "$ref": "#/components/parameters/alert_enabled" + }, + { + "$ref": "#/components/parameters/query_column_filter" } ], "responses": { @@ -4338,66 +4481,179 @@ ] } }, - "/reports": { + "/insights": { "get": { - "operationId": "ListReports", - "description": "List reports", - "tags": [ - "reports" - ], + "description": "List insights with optional filtering", + "operationId": "ListPlatformInsights", "parameters": [ { - "name": "search_term", + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "name": "search", "in": "query", + "required": false, "schema": { "type": "string" }, - "description": "Filter reports by title or description." + "description": "Search in title, evidence (description), mitigation, or related fields" }, { - "name": "visibility", + "name": "severities", "in": "query", + "required": false, "schema": { - "type": "string", - "enum": [ - "private", - "public" - ] - } + "type": "array", + "items": { + "$ref": "#/components/schemas/InsightSeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (any match)" }, { - "$ref": "#/components/parameters/per_page" + "name": "cloud", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by cloud" }, { - "$ref": "#/components/parameters/page" + "name": "account", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by account" }, { - "$ref": "#/components/parameters/report_sort_bys" + "name": "region", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by region" }, { - "$ref": "#/components/parameters/report_sort_dirs" + "name": "insight_category", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by insight category" + }, + { + "name": "source_category", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by source category" + }, + { + "name": "source", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by source" + }, + { + "name": "resource_types", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by resource types" + }, + { + "name": "tags", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by tags (any match)" + }, + { + "name": "sort_by", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "title", + "severity", + "insight_category", + "source_category", + "account", + "source", + "resource_types", + "resources_count", + "accounts_count", + "created_at", + "detected_at" + ], + "default": "detected_at" + }, + "description": "Field to sort by" + }, + { + "name": "sort_dir", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc" + }, + "description": "Sort direction" } ], "responses": { "200": { - "description": "List of reports.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "reports", + "items", "metadata" ], "properties": { - "reports": { + "items": { "type": "array", "items": { - "$ref": "#/components/schemas/Report" + "$ref": "#/components/schemas/Insight" } }, "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "$ref": "#/components/schemas/InsightsListMetadata" } } } @@ -4407,238 +4663,323 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - }, - "post": { - "description": "Create Report", - "operationId": "CreateReport", - "tags": [ - "reports" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportCreate" - } - } + "500": { + "$ref": "#/components/responses/InternalError" } }, - "responses": { - "201": { - "description": "Created report.", - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/Report" - } - } - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - } - } + "tags": [ + "insights" + ] } }, - "/reports/{report_id}": { + "/insights/columns/{column_name}/distinct-values": { "get": { - "description": "Get Report", - "operationId": "GetReport", - "tags": [ - "reports" - ], + "description": "Get the candidate values for the next filter dimension (`column_name`), given the current active filters. The supplied filter parameters represent where the user currently is in the filter matrix; only values for `column_name` that would yield at least one insight when added to that current position are returned. Values that would produce zero results are omitted, preventing the user from navigating to an empty state.\nThe filter parameter corresponding to `column_name` is always ignored when computing candidates — asking \"which severities exist where severity=X\" is self-referential and nonsensical. For example, if `column_name=severity` then any `severities` filter in the request is not applied; if `column_name=source` then any `source` filter is not applied; and so on. This ensures the full set of viable values for that dimension is always returned given the other active filters.\nWhen `owner_tag` is specified (e.g., \"team\", \"department\"), this endpoint returns distinct values for that specific ownership tag key, ignoring the `column_name` parameter. The corresponding tags filter for this owner key is ignored to prevent self-referential queries.\nWhen querying for `column_name=tag` without `owner_tag`, ownership tags configured in platform settings are automatically excluded from results.", + "operationId": "GetPlatformInsightColumnDistinctValues", "parameters": [ { - "name": "report_id", - "in": "path", - "required": true, + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/insight_column_name" + }, + { + "name": "owner_tag", + "in": "query", + "required": false, "schema": { - "type": "string", - "format": "uuid" + "type": "string" }, - "description": "ID of the report." - } - ], - "responses": { - "200": { - "description": "Retrieved report.", - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/Report" - } - } - } - } - } - }, - "403": { - "$ref": "#/components/responses/Forbidden" + "description": "When specified, returns distinct values for this ownership tag key (e.g., \"team\", \"department\"). The column_name parameter is ignored when owner_tag is provided." }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - }, - "put": { - "description": "Update Report", - "operationId": "UpdateReport", - "tags": [ - "reports" - ], - "parameters": [ { - "name": "report_id", - "in": "path", - "required": true, + "name": "search", + "in": "query", + "required": false, "schema": { - "type": "string", - "format": "uuid" + "type": "string" }, - "description": "ID of the report." - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ReportUpdate" - } - } - } - }, - "responses": { - "200": { - "description": "Updated report.", - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/Report" - } - } - } - } - } + "description": "Search in title, evidence (description), mitigation, or related fields" }, - "400": { - "$ref": "#/components/responses/BadRequest" + { + "name": "severities", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/InsightSeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (any match)" }, - "403": { - "$ref": "#/components/responses/Forbidden" + { + "name": "cloud", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by cloud" }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - }, - "delete": { - "description": "Delete Report", - "operationId": "DeleteReport", - "tags": [ - "reports" - ], - "parameters": [ { - "name": "report_id", - "in": "path", - "required": true, + "name": "account", + "in": "query", + "required": false, "schema": { - "type": "string", - "format": "uuid" + "type": "string" }, - "description": "ID of the report." - } - ], - "responses": { - "204": { - "description": "Report deleted." + "description": "Filter by account" }, - "403": { - "$ref": "#/components/responses/Forbidden" + { + "name": "region", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by region" }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/reports/templates": { - "get": { - "operationId": "ListReportTemplates", - "description": "List report templates", - "tags": [ - "reports" - ], - "parameters": [ { - "name": "search_term", + "name": "insight_category", "in": "query", + "required": false, "schema": { "type": "string" }, - "description": "Filter report templates by name." + "description": "Filter by insight category" }, { - "$ref": "#/components/parameters/per_page" + "name": "source_category", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by source category" }, { - "$ref": "#/components/parameters/page" + "name": "source", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Filter by source" }, { - "$ref": "#/components/parameters/report_templates_sort_bys" + "name": "resource_types", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by resource types" }, { - "$ref": "#/components/parameters/report_templates_sort_dirs" + "name": "tags", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by tags (any match)" } ], "responses": { "200": { - "description": "List of report templates.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", "required": [ - "templates", - "metadata" + "values" ], "properties": { - "templates": { + "values": { "type": "array", "items": { - "$ref": "#/components/schemas/ReportTemplate" + "type": "string" + } + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "insights" + ] + } + }, + "/insights/saved-filters": { + "get": { + "description": "List saved insight filters", + "operationId": "PlatformListInsightFilters", + "parameters": [ + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "name": "search_term", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Search in filter name or description" + }, + { + "name": "insight_category", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by insight category" + }, + { + "name": "severities", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/InsightSeverity" + } + }, + "style": "form", + "explode": true, + "description": "Filter by severities (any match)" + }, + { + "name": "resource_types", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by resource types" + }, + { + "name": "source", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by source" + }, + { + "name": "source_category", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by source category" + }, + { + "name": "tags", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by tags (any match)" + }, + { + "name": "group_by", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by group by fields" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PlatformInsightFilter" } }, "metadata": { @@ -4649,255 +4990,195 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] }, "post": { - "description": "Create Report Template", - "operationId": "CreateReportTemplate", - "tags": [ - "reports" - ], + "description": "Create a new saved insight filter", + "operationId": "PlatformCreateInsightFilter", "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" + "$ref": "#/components/schemas/PlatformInsightFilterCreate" } } } }, "responses": { "201": { - "description": "Created report template.", + "description": "Created", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/ReportTemplate" - } - } + "$ref": "#/components/schemas/PlatformInsightFilter" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "403": { "$ref": "#/components/responses/Forbidden" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] } }, - "/reports/templates/{template_id}": { + "/insights/saved-filters/{insight_filter_id}": { "get": { - "description": "Get Report Template", - "operationId": "GetReportTemplate", - "tags": [ - "reports" - ], + "description": "Get a saved insight filter by ID", + "operationId": "PlatformGetInsightFilterByID", "parameters": [ { - "name": "template_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." + "$ref": "#/components/parameters/platform_insight_filter_id" } ], "responses": { "200": { - "description": "Retrieved report template.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/ReportTemplate" - } - } + "$ref": "#/components/schemas/PlatformInsightFilter" } } } }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } - }, - "put": { - "description": "Update Report Template", - "operationId": "UpdateReportTemplate", + }, "tags": [ - "reports" - ], + "insights" + ] + }, + "patch": { + "description": "Update a saved insight filter", + "operationId": "PlatformUpdateInsightFilter", "parameters": [ { - "name": "template_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." + "$ref": "#/components/parameters/platform_insight_filter_id" } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" + "$ref": "#/components/schemas/PlatformInsightFilterUpdate" } } } }, "responses": { "200": { - "description": "Updated report template.", + "description": "Response", "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "data" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/ReportTemplate" - } - } + "$ref": "#/components/schemas/PlatformInsightFilter" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] }, "delete": { - "description": "Delete Report Template", - "operationId": "DeleteReportTemplate", - "tags": [ - "reports" - ], + "description": "Delete a saved insight filter", + "operationId": "PlatformDeleteInsightFilter", "parameters": [ { - "name": "template_id", - "in": "path", - "required": true, - "schema": { - "type": "string", - "format": "uuid" - }, - "description": "ID of the report template." + "$ref": "#/components/parameters/platform_insight_filter_id" } ], "responses": { "204": { - "description": "Report template deleted." - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - } - } - } - }, - "/sync-destination-test-connections": { - "post": { - "description": "Create a test destination connection.", - "operationId": "CreateSyncDestinationTestConnection", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnectionCreate" - } - } - } - }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Deleted" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] } }, - "/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "/insights/{insight_id}": { "get": { - "description": "Get a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnection", - "tags": [ - "syncs" - ], + "description": "Get insight by ID", + "operationId": "GetPlatformInsight", "parameters": [ { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/insight_id" } ], "responses": { @@ -4906,7 +5187,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" + "$ref": "#/components/schemas/Insight" } } } @@ -4923,105 +5204,90 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "patch": { - "description": "Update a sync destination test connection.", - "operationId": "UpdateSyncTestConnectionForSyncDestination", + }, "tags": [ - "syncs" - ], + "insights" + ] + } + }, + "/insights/{insight_id}/assets": { + "get": { + "description": "List assets affected by an insight", + "operationId": "GetPlatformInsightAssets", "parameters": [ { - "$ref": "#/components/parameters/sync_destination_test_connection_id" - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "#/components/schemas/SyncTestConnectionStatus" - }, - "failure_reason": { - "type": "string", - "description": "Reason for failure", - "example": "password authentication failed for user \"exampleuser\"" - }, - "failure_code": { - "example": "INVALID_CREDENTIALS", - "type": "string", - "description": "Code for failure" - } - } - } - } - } - }, - "responses": { - "200": { - "description": "Updated", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "403": { - "$ref": "#/components/responses/Forbidden" + "$ref": "#/components/parameters/insight_id" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "$ref": "#/components/parameters/page" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + { + "$ref": "#/components/parameters/per_page" }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/query": { - "get": { - "description": "Get logs for a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnectionLogsQuery", - "tags": [ - "syncs" - ], - "parameters": [ { - "in": "header", - "name": "Accept", + "name": "search", + "in": "query", "required": false, "schema": { "type": "string" - } - }, - { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + }, + "description": "Search in asset name, account, region, etc." }, { - "$ref": "#/components/parameters/table_filters" + "name": "accounts", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by account IDs" }, { - "$ref": "#/components/parameters/per_page" + "name": "clouds", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by cloud providers (e.g. aws, azure, gcp, github, backstage, digitalocean, wiz)" }, { - "$ref": "#/components/parameters/page" + "name": "regions", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by regions" }, { - "$ref": "#/components/parameters/download_file" + "name": "resource_type", + "in": "query", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + } + }, + "style": "form", + "explode": true, + "description": "Filter by resource type" } ], "responses": { @@ -5031,140 +5297,124 @@ "application/json": { "schema": { "required": [ - "data", + "items", "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/TableData" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyViolation" + } }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Download file." - } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] } }, - "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/live": { + "/insights/assets/{asset_id}": { "get": { - "description": "Get live logs for a sync destination test connection.", - "operationId": "GetSyncDestinationTestConnectionLogsLive", - "tags": [ - "syncs" - ], + "description": "List insights for a specific asset (by _cq_platform_id)", + "operationId": "GetPlatformAssetInsights", "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/asset_id" }, { - "$ref": "#/components/parameters/sync_destination_test_connection_id" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "text/plain": { - "schema": { - "type": "string", - "description": "Chunked response logs for a test connection that is in progress." - } - } - } - }, - "204": { - "description": "No logs available for a test connection that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "$ref": "#/components/parameters/page" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + { + "$ref": "#/components/parameters/per_page" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "name": "search", + "in": "query", + "required": false, + "schema": { + "type": "string" + }, + "description": "Search in asset name, account, region, etc." }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + { + "name": "sort_by", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "title", + "severity", + "insight_category", + "source_category", + "account", + "source", + "resource_types", + "resources_count", + "accounts_count", + "created_at", + "detected_at" + ], + "default": "detected_at" + }, + "description": "Field to sort by" }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/sync-destination-test-connections/{sync_destination_test_connection_id}/promote": { - "post": { - "description": "Promote a sync destination test connection to a sync destination.", - "operationId": "PromoteSyncDestinationTestConnection", - "tags": [ - "syncs" - ], - "parameters": [ { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "name": "sort_dir", + "in": "query", + "required": false, + "schema": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "desc" + }, + "description": "Sort direction" } ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PromoteSyncDestinationTestConnection" - } - } - } - }, "responses": { "200": { - "description": "Successful response indicating that an existing sync destination was replaced.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestination" - } - } - } - }, - "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Insight" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -5175,58 +5425,78 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "insights" + ] } }, - "/sync-destinations": { + "/reports": { "get": { - "description": "List all sync destination definitions.", - "operationId": "ListSyncDestinations", + "operationId": "ListReports", + "description": "List reports", "tags": [ - "syncs" + "reports" ], "parameters": [ { - "$ref": "#/components/parameters/per_page" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter reports by title or description." }, { - "$ref": "#/components/parameters/page" + "name": "visibility", + "in": "query", + "schema": { + "type": "string", + "enum": [ + "private", + "public" + ] + } }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_generic_sort_bys" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/report_sort_bys" + }, + { + "$ref": "#/components/parameters/report_sort_dirs" } ], "responses": { "200": { - "description": "Response", + "description": "List of reports.", "content": { "application/json": { "schema": { + "type": "object", "required": [ - "items", + "reports", "metadata" ], "properties": { - "items": { + "reports": { + "type": "array", "items": { - "$ref": "#/components/schemas/SyncDestination" - }, - "type": "array" + "$ref": "#/components/schemas/Report" + } }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -5239,80 +5509,45 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/sync-destinations/{sync_destination_name}": { - "get": { - "description": "Get a single sync destination definition.", - "operationId": "GetSyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestination" - } - } - } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" } } }, - "patch": { - "description": "Update a Sync Destination definition.", - "operationId": "UpdateSyncDestination", + "post": { + "description": "Create Report", + "operationId": "CreateReport", "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_destination_name" - } + "reports" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationUpdate" + "$ref": "#/components/schemas/ReportCreate" } } } }, "responses": { - "200": { - "description": "Response", + "201": { + "description": "Created report.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/Report" + } + } } } } @@ -5320,99 +5555,99 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" + "403": { + "$ref": "#/components/responses/Forbidden" } } - }, - "delete": { - "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", - "operationId": "DeleteSyncDestination", + } + }, + "/reports/{report_id}": { + "get": { + "description": "Get Report", + "operationId": "GetReport", "tags": [ - "syncs" + "reports" ], "parameters": [ { - "$ref": "#/components/parameters/sync_destination_name" + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." } ], "responses": { - "204": { - "description": "Deleted" + "200": { + "description": "Retrieved report.", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/Report" + } + } + } + } + } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } } - } - }, - "/sync-destinations/{sync_destination_name}/syncs": { - "get": { - "description": "List all Syncs for a given sync destination.", - "operationId": "ListSyncDestinationSyncs", + }, + "put": { + "description": "Update Report", + "operationId": "UpdateReport", "tags": [ - "syncs" + "reports" ], "parameters": [ { - "$ref": "#/components/parameters/sync_destination_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/migration_filter" + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ReportUpdate" + } + } + } + }, "responses": { "200": { - "description": "Response", + "description": "Updated report.", "content": { "application/json": { "schema": { + "type": "object", "required": [ - "items", - "metadata" + "data" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/ListSync" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "data": { + "$ref": "#/components/schemas/Report" } } } @@ -5422,40 +5657,96 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" + } + } + }, + "delete": { + "description": "Delete Report", + "operationId": "DeleteReport", + "tags": [ + "reports" + ], + "parameters": [ + { + "name": "report_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report." + } + ], + "responses": { + "204": { + "description": "Report deleted." }, - "500": { - "$ref": "#/components/responses/InternalError" + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" } } } }, - "/sync-destinations/{sync_destination_name}/test-connections/{sync_test_connection_id}": { + "/reports/templates": { "get": { - "description": "Get test connection details for sync destination.", - "operationId": "GetTestConnectionForSyncDestination", + "operationId": "ListReportTemplates", + "description": "List report templates", "tags": [ - "syncs" + "reports" ], "parameters": [ { - "$ref": "#/components/parameters/sync_destination_name" + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter report templates by name." }, { - "$ref": "#/components/parameters/sync_test_connection_id" + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/report_templates_sort_bys" + }, + { + "$ref": "#/components/parameters/report_templates_sort_dirs" } ], "responses": { "200": { - "description": "Response", + "description": "List of report templates.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTestConnection" + "type": "object", + "required": [ + "templates", + "metadata" + ], + "properties": { + "templates": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReportTemplate" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -5463,42 +5754,45 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" } } - } - }, - "/sync-source-test-connections": { + }, "post": { - "description": "Create a test source connection.", - "operationId": "CreateSyncSourceTestConnection", + "description": "Create Report Template", + "operationId": "CreateReportTemplate", "tags": [ - "syncs" + "reports" ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnectionCreate" + "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" } } } }, "responses": { "201": { - "description": "Response", + "description": "Created report template.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/ReportTemplate" + } + } } } } @@ -5506,43 +5800,215 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" + "403": { + "$ref": "#/components/responses/Forbidden" } } } }, - "/sync-source-test-connections/{sync_source_test_connection_id}": { + "/reports/templates/{template_id}": { "get": { - "description": "Get a sync source test connection.", - "operationId": "GetSyncSourceTestConnection", + "description": "Get Report Template", + "operationId": "GetReportTemplate", "tags": [ - "syncs" + "reports" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_test_connection_id" - } - ], - "responses": { - "200": { - "description": "Response", + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." + } + ], + "responses": { + "200": { + "description": "Retrieved report template.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/ReportTemplate" + } + } + } + } + } + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + } + } + }, + "put": { + "description": "Update Report Template", + "operationId": "UpdateReportTemplate", + "tags": [ + "reports" + ], + "parameters": [ + { + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ReportTemplateCreateOrUpdate" + } + } + } + }, + "responses": { + "200": { + "description": "Updated report template.", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "data" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/ReportTemplate" + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + } + } + }, + "delete": { + "description": "Delete Report Template", + "operationId": "DeleteReportTemplate", + "tags": [ + "reports" + ], + "parameters": [ + { + "name": "template_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + }, + "description": "ID of the report template." + } + ], + "responses": { + "204": { + "description": "Report template deleted." + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + } + } + } + }, + "/sync-destination-test-connections": { + "post": { + "description": "Create a test destination connection.", + "operationId": "CreateSyncDestinationTestConnection", + "tags": [ + "syncs" + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationTestConnectionCreate" + } + } + } + }, + "responses": { + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationTestConnection" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "get": { + "description": "Get a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnection", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_destination_test_connection_id" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationTestConnection" } } } @@ -5562,14 +6028,14 @@ } }, "patch": { - "description": "Update a sync source test connection.", - "operationId": "UpdateSyncTestConnectionForSyncSource", + "description": "Update a sync destination test connection.", + "operationId": "UpdateSyncTestConnectionForSyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_test_connection_id" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "requestBody": { @@ -5605,7 +6071,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "$ref": "#/components/schemas/SyncDestinationTestConnection" } } } @@ -5628,10 +6094,10 @@ } } }, - "/sync-source-test-connections/{sync_source_test_connection_id}/logs/query": { + "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/query": { "get": { - "description": "Get logs for a sync source test connection.", - "operationId": "GetSyncSourceTestConnectionLogsQuery", + "description": "Get logs for a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnectionLogsQuery", "tags": [ "syncs" ], @@ -5645,7 +6111,7 @@ } }, { - "$ref": "#/components/parameters/sync_source_test_connection_id" + "$ref": "#/components/parameters/sync_destination_test_connection_id" }, { "$ref": "#/components/parameters/table_filters" @@ -5709,10 +6175,10 @@ } } }, - "/sync-source-test-connections/{sync_source_test_connection_id}/logs/live": { + "/sync-destination-test-connections/{sync_destination_test_connection_id}/logs/live": { "get": { - "description": "Get live logs for a sync source test connection.", - "operationId": "GetSyncSourceTestConnectionLogsLive", + "description": "Get live logs for a sync destination test connection.", + "operationId": "GetSyncDestinationTestConnectionLogsLive", "tags": [ "syncs" ], @@ -5726,7 +6192,7 @@ } }, { - "$ref": "#/components/parameters/sync_source_test_connection_id" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "responses": { @@ -5762,16 +6228,16 @@ } } }, - "/sync-source-test-connections/{sync_source_test_connection_id}/promote": { + "/sync-destination-test-connections/{sync_destination_test_connection_id}/promote": { "post": { - "description": "Promote a sync source test connection to a sync source.", - "operationId": "PromoteSyncSourceTestConnection", + "description": "Promote a sync destination test connection to a sync destination.", + "operationId": "PromoteSyncDestinationTestConnection", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_test_connection_id" + "$ref": "#/components/parameters/sync_destination_test_connection_id" } ], "requestBody": { @@ -5779,28 +6245,28 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PromoteSyncSourceTestConnection" + "$ref": "#/components/schemas/PromoteSyncDestinationTestConnection" } } } }, "responses": { "200": { - "description": "Successful response indicating that an existing sync source was replaced.", + "description": "Successful response indicating that an existing sync destination was replaced.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncDestination" } } } }, "201": { - "description": "Successful response indicating that a new sync source was created.", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncDestination" } } } @@ -5823,59 +6289,10 @@ } } }, - "/v2/sync-integration-test-connections": { - "post": { - "description": "Create an integration test connection.", - "operationId": "CreateV2SyncIntegrationTestConnection", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncIntegrationTestConnectionCreateV2" - } - } - } - }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncIntegrationTestConnectionV2" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/v2/sync-integrations": { - "get": { - "description": "List sync integrations", - "operationId": "ListV2SyncIntegrations", + "/sync-destinations": { + "get": { + "description": "List all sync destination definitions.", + "operationId": "ListSyncDestinations", "tags": [ "syncs" ], @@ -5887,13 +6304,13 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/sync_sort_bys" + "$ref": "#/components/parameters/sync_name_filter" }, { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/sync_generic_sort_bys" }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { @@ -5909,7 +6326,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncIntegrationExpandedV2" + "$ref": "#/components/schemas/SyncDestination" }, "type": "array" }, @@ -5934,62 +6351,18 @@ "$ref": "#/components/responses/InternalError" } } - }, - "post": { - "description": "Create a new integration associated with a completed test connection", - "operationId": "CreateV2SyncIntegration", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncIntegrationCreateV2" - } - } - } - }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncIntegrationV2" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } } }, - "/v2/sync-integrations/{sync_name}": { + "/sync-destinations/{sync_destination_name}": { "get": { - "description": "Get a sync integration by name", - "operationId": "GetV2SyncIntegration", + "description": "Get a single sync destination definition.", + "operationId": "GetSyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { @@ -5998,14 +6371,11 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationExpandedV2" + "$ref": "#/components/schemas/SyncDestination" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -6018,14 +6388,14 @@ } }, "patch": { - "description": "Update attributes of an integration", - "operationId": "UpdateV2SyncIntegration", + "description": "Update a Sync Destination definition.", + "operationId": "UpdateSyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "requestBody": { @@ -6033,7 +6403,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationUpdateV2" + "$ref": "#/components/schemas/SyncDestinationUpdate" } } } @@ -6044,7 +6414,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncIntegrationV2" + "$ref": "#/components/schemas/SyncDestination" } } } @@ -6067,44 +6437,28 @@ } }, "delete": { - "description": "Delete an integration", - "operationId": "DeleteV2SyncIntegration", + "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", + "operationId": "DeleteSyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" - }, - { - "name": "delete_data", - "description": "If true, also delete data associated with this integration from the relevant destinations.", - "in": "query", - "required": false, - "schema": { - "type": "boolean", - "default": false - } + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "description": "Deleted" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" @@ -6112,14 +6466,17 @@ } } }, - "/sync-sources": { + "/sync-destinations/{sync_destination_name}/syncs": { "get": { - "description": "List all sync source definitions.", - "operationId": "ListSyncSources", + "description": "List all Syncs for a given sync destination.", + "operationId": "ListSyncDestinationSyncs", "tags": [ "syncs" ], "parameters": [ + { + "$ref": "#/components/parameters/sync_destination_name" + }, { "$ref": "#/components/parameters/per_page" }, @@ -6127,13 +6484,16 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/sync_sort_bys" }, { - "$ref": "#/components/parameters/sync_generic_sort_bys" + "$ref": "#/components/parameters/sync_sort_dirs" }, { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/migration_filter" } ], "responses": { @@ -6149,7 +6509,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/ListSync" }, "type": "array" }, @@ -6176,16 +6536,19 @@ } } }, - "/sync-sources/{sync_source_name}": { + "/sync-destinations/{sync_destination_name}/test-connections/{sync_test_connection_id}": { "get": { - "description": "Get a single sync source definition.", - "operationId": "GetSyncSource", + "description": "Get test connection details for sync destination.", + "operationId": "GetTestConnectionForSyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_name" + "$ref": "#/components/parameters/sync_destination_name" + }, + { + "$ref": "#/components/parameters/sync_test_connection_id" } ], "responses": { @@ -6194,11 +6557,14 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncTestConnection" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -6209,35 +6575,32 @@ "$ref": "#/components/responses/InternalError" } } - }, - "patch": { - "description": "Update a Sync Source definition.", - "operationId": "UpdateSyncSource", + } + }, + "/sync-source-test-connections": { + "post": { + "description": "Create a test source connection.", + "operationId": "CreateSyncSourceTestConnection", "tags": [ "syncs" ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_source_name" - } - ], "requestBody": { "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceUpdate" + "$ref": "#/components/schemas/SyncSourceTestConnectionCreate" } } } }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSource" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -6254,133 +6617,97 @@ "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } } - }, - "delete": { - "description": "Delete a Sync Source definition. Any syncs relying on this source must be deleted first.", - "operationId": "DeleteSyncSource", + } + }, + "/sync-source-test-connections/{sync_source_test_connection_id}": { + "get": { + "description": "Get a sync source test connection.", + "operationId": "GetSyncSourceTestConnection", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_name" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "responses": { - "204": { - "description": "Deleted" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncSourceTestConnection" + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } } - } - }, - "/sync-sources/{sync_source_name}/syncs": { - "get": { - "description": "List all Syncs for a given sync source.", - "operationId": "ListSyncSourceSyncs", + }, + "patch": { + "description": "Update a sync source test connection.", + "operationId": "UpdateSyncTestConnectionForSyncSource", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_source_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/migration_filter" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/ListSync" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" + }, + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" } } } } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/sync-sources/{sync_source_name}/test-connections/{sync_test_connection_id}": { - "get": { - "description": "Get test connection details for sync source.", - "operationId": "GetTestConnectionForSyncSource", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_source_name" - }, - { - "$ref": "#/components/parameters/sync_test_connection_id" } - ], + }, "responses": { "200": { - "description": "Response", + "description": "Updated", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTestConnection" + "$ref": "#/components/schemas/SyncSourceTestConnection" } } } @@ -6388,40 +6715,51 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/sync-transformers": { + "/sync-source-test-connections/{sync_source_test_connection_id}/logs/query": { "get": { - "description": "List all sync transformer definitions.", - "operationId": "ListSyncTransformers", + "description": "Get logs for a sync source test connection.", + "operationId": "GetSyncSourceTestConnectionLogsQuery", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/per_page" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_source_test_connection_id" }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/table_filters" }, { - "$ref": "#/components/parameters/sync_generic_sort_bys" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -6431,24 +6769,30 @@ "application/json": { "schema": { "required": [ - "items", + "data", "metadata" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncTransformer" - }, - "type": "array" + "data": { + "$ref": "#/components/schemas/TableData" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } + }, + "text/plain": { + "schema": { + "type": "string", + "description": "Download file." + } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, "400": { "$ref": "#/components/responses/BadRequest" }, @@ -6458,55 +6802,78 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/sync-transformers/{sync_transformer_name}": { + "/sync-source-test-connections/{sync_source_test_connection_id}/logs/live": { "get": { - "description": "Get a single sync transformer definition.", - "operationId": "GetSyncTransformer", + "description": "Get live logs for a sync source test connection.", + "operationId": "GetSyncSourceTestConnectionLogsLive", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_transformer_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } + }, + { + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "responses": { "200": { "description": "Response", "content": { - "application/json": { + "text/plain": { "schema": { - "$ref": "#/components/schemas/SyncTransformer" + "type": "string", + "description": "Chunked response logs for a test connection that is in progress." } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } - }, - "patch": { - "description": "Update a Sync Transformer definition.", - "operationId": "UpdateSyncTransformer", + } + }, + "/sync-source-test-connections/{sync_source_test_connection_id}/promote": { + "post": { + "description": "Promote a sync source test connection to a sync source.", + "operationId": "PromoteSyncSourceTestConnection", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_transformer_name" + "$ref": "#/components/parameters/sync_source_test_connection_id" } ], "requestBody": { @@ -6514,18 +6881,28 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTransformerUpdate" + "$ref": "#/components/schemas/PromoteSyncSourceTestConnection" } } } }, "responses": { "200": { - "description": "Response", + "description": "Successful response indicating that an existing sync source was replaced.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncTransformer" + "$ref": "#/components/schemas/SyncSource" + } + } + } + }, + "201": { + "description": "Successful response indicating that a new sync source was created.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncSource" } } } @@ -6546,21 +6923,38 @@ "$ref": "#/components/responses/InternalError" } } - }, - "delete": { - "description": "Delete a Sync Transformer definition. Any syncs relying on this transformer must be deleted first.", - "operationId": "DeleteSyncTransformer", + } + }, + "/v2/sync-integration-test-connections": { + "post": { + "description": "Create an integration test connection.", + "operationId": "CreateV2SyncIntegrationTestConnection", "tags": [ "syncs" ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_transformer_name" + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationTestConnectionCreateV2" + } + } } - ], + }, "responses": { - "204": { - "description": "Deleted" + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationTestConnectionV2" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -6571,28 +6965,37 @@ "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/sync-transformers/{sync_transformer_name}/syncs": { + "/v2/sync-integrations": { "get": { - "description": "List all Syncs for a given sync transformer.", - "operationId": "ListSyncTransformerSyncs", + "description": "List sync integrations", + "operationId": "ListV2SyncIntegrations", "tags": [ "syncs" ], "parameters": [ - { - "$ref": "#/components/parameters/sync_transformer_name" - }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + }, + { + "$ref": "#/components/parameters/sync_name_filter" } ], "responses": { @@ -6608,7 +7011,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Sync" + "$ref": "#/components/schemas/SyncIntegrationExpandedV2" }, "type": "array" }, @@ -6620,6 +7023,9 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -6630,114 +7036,117 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/sync-transformers/{sync_transformer_name}/sync-destinations": { - "get": { - "description": "List all Sync Destinations for a given sync transformer.", - "operationId": "ListSyncTransformerSyncDestinations", + }, + "post": { + "description": "Create a new integration associated with a completed test connection", + "operationId": "CreateV2SyncIntegration", "tags": [ "syncs" ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_transformer_name" - }, - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationCreateV2" + } + } } - ], + }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncDestination" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncIntegrationV2" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/sync-upgrades": { + "/v2/sync-integrations/{sync_name}": { "get": { - "description": "List all version upgrades for syncs", - "operationId": "ListSyncUpgrades", + "description": "Get a sync integration by name", + "operationId": "GetV2SyncIntegration", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_upgrades_sort_bys" + "$ref": "#/components/parameters/sync_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationExpandedV2" + } + } + } }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "400": { + "$ref": "#/components/responses/BadRequest" }, - { - "$ref": "#/components/parameters/sync_upgrades_path_filter" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - { - "$ref": "#/components/parameters/sync_upgrades_kind_filter" + "404": { + "$ref": "#/components/responses/NotFound" }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "patch": { + "description": "Update attributes of an integration", + "operationId": "UpdateV2SyncIntegration", + "tags": [ + "syncs" + ], + "parameters": [ { - "$ref": "#/components/parameters/sync_upgrades_platform_version_filter" + "$ref": "#/components/parameters/sync_name" } ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncIntegrationUpdateV2" + } + } + } + }, "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncUpgrade" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncIntegrationV2" } } } @@ -6751,16 +7160,64 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "delete": { + "description": "Delete an integration", + "operationId": "DeleteV2SyncIntegration", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" + }, + { + "name": "delete_data", + "description": "If true, also delete data associated with this integration from the relevant destinations.", + "in": "query", + "required": false, + "schema": { + "type": "boolean", + "default": false + } + } + ], + "responses": { + "204": { + "description": "Success" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/syncs": { + "/sync-sources": { "get": { - "description": "List all Syncs.", - "operationId": "ListSyncs", + "description": "List all sync source definitions.", + "operationId": "ListSyncSources", "tags": [ "syncs" ], @@ -6772,16 +7229,13 @@ "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/sync_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "$ref": "#/components/parameters/sync_name_filter" }, { - "$ref": "#/components/parameters/sync_name_filter" + "$ref": "#/components/parameters/sync_generic_sort_bys" }, { - "$ref": "#/components/parameters/migration_filter" + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { @@ -6797,7 +7251,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/ListSync" + "$ref": "#/components/schemas/SyncSource" }, "type": "array" }, @@ -6822,59 +7276,18 @@ "$ref": "#/components/responses/InternalError" } } - }, - "post": { - "description": "Create new Sync definition. Sync runs can be scheduled automatically, or triggered manually after sync is created.", - "operationId": "CreateSync", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncCreate" - } - } - } - }, - "responses": { - "201": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Sync" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } } }, - "/syncs/{sync_name}": { + "/sync-sources/{sync_source_name}": { "get": { - "description": "Get a Sync", - "operationId": "GetSync", + "description": "Get a single sync source definition.", + "operationId": "GetSyncSource", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_source_name" } ], "responses": { @@ -6883,14 +7296,11 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Sync" + "$ref": "#/components/schemas/SyncSource" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -6903,32 +7313,33 @@ } }, "patch": { - "description": "Update a Sync", - "operationId": "UpdateSync", + "description": "Update a Sync Source definition.", + "operationId": "UpdateSyncSource", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_source_name" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncUpdate" + "$ref": "#/components/schemas/SyncSourceUpdate" } } } }, "responses": { "200": { - "description": "Updated", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Sync" + "$ref": "#/components/schemas/SyncSource" } } } @@ -6936,8 +7347,8 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" @@ -6951,23 +7362,20 @@ } }, "delete": { - "description": "Delete Sync. This will delete Sync configuration and all associated sync runs, but will not delete the associated source and destination(s). These will need to be deleted separately.", - "operationId": "DeleteSync", + "description": "Delete a Sync Source definition. Any syncs relying on this source must be deleted first.", + "operationId": "DeleteSyncSource", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_source_name" } ], "responses": { "204": { "description": "Deleted" }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -6983,25 +7391,34 @@ } } }, - "/syncs/{sync_name}/runs": { + "/sync-sources/{sync_source_name}/syncs": { "get": { - "description": "List all Sync Runs.", - "operationId": "ListSyncRuns", + "description": "List all Syncs for a given sync source.", + "operationId": "ListSyncSourceSyncs", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/migration_filter" + "$ref": "#/components/parameters/sync_source_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/migration_filter" } ], "responses": { @@ -7017,7 +7434,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/ListSync" }, "type": "array" }, @@ -7029,6 +7446,9 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -7039,25 +7459,30 @@ "$ref": "#/components/responses/InternalError" } } - }, - "post": { - "description": "Create new SyncRun. This will trigger a manual job run.", - "operationId": "CreateSyncRun", + } + }, + "/sync-sources/{sync_source_name}/test-connections/{sync_test_connection_id}": { + "get": { + "description": "Get test connection details for sync source.", + "operationId": "GetTestConnectionForSyncSource", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_source_name" + }, + { + "$ref": "#/components/parameters/sync_test_connection_id" } ], "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/SyncTestConnection" } } } @@ -7068,8 +7493,8 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "404": { + "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" @@ -7077,19 +7502,28 @@ } } }, - "/syncs/{sync_name}/runs/{sync_run_id}": { + "/sync-transformers": { "get": { - "description": "Get a Sync Run.", - "operationId": "GetSyncRun", + "description": "List all sync transformer definitions.", + "operationId": "ListSyncTransformers", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/sync_generic_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { @@ -7098,11 +7532,28 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRunDetails" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/SyncTransformer" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -7113,45 +7564,70 @@ "$ref": "#/components/responses/InternalError" } } - }, - "patch": { - "description": "Update a SyncRun", - "operationId": "UpdateSyncRun", + } + }, + "/sync-transformers/{sync_transformer_name}": { + "get": { + "description": "Get a single sync transformer definition.", + "operationId": "GetSyncTransformer", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_transformer_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncTransformer" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "patch": { + "description": "Update a Sync Transformer definition.", + "operationId": "UpdateSyncTransformer", + "tags": [ + "syncs" + ], + "parameters": [ { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/sync_transformer_name" } ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "properties": { - "status": { - "$ref": "#/components/schemas/SyncRunStatus" - }, - "status_reason": { - "$ref": "#/components/schemas/SyncRunStatusReason" - } - } + "$ref": "#/components/schemas/SyncTransformerUpdate" } } } }, "responses": { "200": { - "description": "Updated", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRun" + "$ref": "#/components/schemas/SyncTransformer" } } } @@ -7159,8 +7635,8 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" @@ -7172,41 +7648,53 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/syncs/{sync_name}/runs/{sync_run_id}/logs/query": { - "get": { - "description": "Get logs for a sync run.", - "operationId": "GetSyncRunLogsQuery", + }, + "delete": { + "description": "Delete a Sync Transformer definition. Any syncs relying on this transformer must be deleted first.", + "operationId": "DeleteSyncTransformer", "tags": [ "syncs" ], "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/sync_transformer_name" + } + ], + "responses": { + "204": { + "description": "Deleted" }, - { - "$ref": "#/components/parameters/sync_name" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - { - "$ref": "#/components/parameters/sync_run_id" + "404": { + "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/sync-transformers/{sync_transformer_name}/syncs": { + "get": { + "description": "List all Syncs for a given sync transformer.", + "operationId": "ListSyncTransformerSyncs", + "tags": [ + "syncs" + ], + "parameters": [ { - "$ref": "#/components/parameters/table_filters" + "$ref": "#/components/parameters/sync_transformer_name" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -7216,213 +7704,119 @@ "application/json": { "schema": { "required": [ - "data", + "items", "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/TableData" + "items": { + "items": { + "$ref": "#/components/schemas/Sync" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } - }, - "text/plain": { - "schema": { - "type": "string", - "description": "Download file." - } } } }, - "204": { - "description": "No logs available for a test connection that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/syncs/{sync_name}/runs/{sync_run_id}/logs/live": { + "/sync-transformers/{sync_transformer_name}/sync-destinations": { "get": { - "description": "Get live logs for a sync run.", - "operationId": "GetSyncRunLogsLive", + "description": "List all Sync Destinations for a given sync transformer.", + "operationId": "ListSyncTransformerSyncDestinations", "tags": [ "syncs" ], "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/sync_transformer_name" }, { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/per_page" }, { - "in": "query", - "name": "table", - "required": false, - "schema": { - "type": "string", - "description": "Table name to filter logs by. Use a single dash (\"-\") as input to exclude all table-specific log lines." - } + "$ref": "#/components/parameters/page" } ], "responses": { "200": { "description": "Response", "content": { - "text/plain": { + "application/json": { "schema": { - "type": "string", - "description": "Chunked response logs for a sync run that is in progress." + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/SyncDestination" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, - "204": { - "description": "No logs available for a sync run that has not started." - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } } } }, - "/syncs/{sync_name}/runs/{sync_run_id}/progress": { - "post": { - "description": "Create a new sync run progress update.", - "operationId": "CreateSyncRunProgress", - "x-internal": true, + "/sync-upgrades": { + "get": { + "description": "List all version upgrades for syncs", + "operationId": "ListSyncUpgrades", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_run_id" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "rows", - "warnings", - "errors" - ], - "properties": { - "rows": { - "type": "integer", - "format": "int64", - "description": "Number of rows synced so far" - }, - "warnings": { - "type": "integer", - "format": "int64", - "description": "Number of warnings encountered so far" - }, - "errors": { - "type": "integer", - "format": "int64", - "description": "Number of errors encountered so far" - }, - "status": { - "$ref": "#/components/schemas/SyncRunStatus" - }, - "shard_num": { - "type": "integer", - "format": "int32", - "description": "The shard number that this progress update is for" - }, - "shard_total": { - "type": "integer", - "format": "int32", - "description": "The total number of shards for this sync run" - }, - "table_progress": { - "$ref": "#/components/schemas/SyncRunTableProgress", - "description": "Table-specific progress information including error and row counts per table" - } - } - } - } - } - }, - "responses": { - "204": { - "description": "Progress was reported successfully" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "$ref": "#/components/parameters/page" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + { + "$ref": "#/components/parameters/sync_upgrades_sort_bys" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "$ref": "#/components/parameters/sync_sort_dirs" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + { + "$ref": "#/components/parameters/sync_upgrades_path_filter" }, - "500": { - "$ref": "#/components/responses/InternalError" - } - } - } - }, - "/syncs/{sync_name}/runs/{sync_run_id}/stats": { - "get": { - "description": "Get statistics on a Sync Run", - "operationId": "GetSyncRunStats", - "tags": [ - "syncs" - ], - "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/sync_upgrades_kind_filter" }, { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/sync_upgrades_platform_version_filter" } ], "responses": { @@ -7431,7 +7825,21 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncRunStats" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/SyncUpgrade" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -7451,31 +7859,31 @@ } } }, - "/syncs/{sync_name}/runs/{sync_run_id}/tables": { + "/syncs": { "get": { - "description": "Get table details on a Sync Run", - "operationId": "GetSyncRunTables", + "description": "List all Syncs.", + "operationId": "ListSyncs", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/sync_name" + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/sync_sort_bys" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_sort_dirs" }, { - "$ref": "#/components/parameters/sync_run_table_sort_bys" + "$ref": "#/components/parameters/sync_name_filter" }, { - "$ref": "#/components/parameters/table_sort_dirs" + "$ref": "#/components/parameters/migration_filter" } ], "responses": { @@ -7491,7 +7899,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/SyncRunTableStat" + "$ref": "#/components/schemas/ListSync" }, "type": "array" }, @@ -7516,79 +7924,59 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/tables": { - "get": { - "description": "List Tables", - "operationId": "ListTables", - "parameters": [ - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - } + }, + "post": { + "description": "Create new Sync definition. Sync runs can be scheduled automatically, or triggered manually after sync is created.", + "operationId": "CreateSync", + "tags": [ + "syncs" ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncCreate" + } + } + } + }, "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/Sync" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables" - ] + } } }, - "/tables/data": { + "/syncs/{sync_name}": { "get": { - "description": "Get all syncs and their associated tables. Returns data in the format needed for the delete action.", - "operationId": "GetTablesData", + "description": "Get a Sync", + "operationId": "GetSync", "tags": [ - "tables" + "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_name" } ], "responses": { @@ -7597,101 +7985,65 @@ "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "syncs", - "metadata" - ], - "properties": { - "syncs": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableDataListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - }, - "example": { - "syncs": [ - { - "sync_name": "aws-integration", - "display_name": "AWS Integration", - "tables": [ - { - "name": "aws_ec2_instances", - "deletion_pending": false - }, - { - "name": "aws_s3_buckets", - "deletion_pending": true - } - ], - "plugin": "cloudquery/aws" - }, - { - "sync_name": "gcp-integration", - "display_name": "GCP Integration", - "tables": [ - { - "name": "gcp_compute_instances", - "deletion_pending": false - } - ], - "plugin": "cloudquery/gcp" - } - ], - "metadata": { - "page_size": 10, - "last_page": 1, - "total_count": 2 - } - } + "$ref": "#/components/schemas/Sync" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" + "404": { + "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" } } }, - "post": { - "description": "Perform an action on table data across multiple syncs. Supported actions: delete (drops partitions for specified tenant/source/table combinations).", - "operationId": "TablesDataAction", + "patch": { + "description": "Update a Sync", + "operationId": "UpdateSync", "tags": [ - "tables" + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" + } ], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/TableDataAction" + "$ref": "#/components/schemas/SyncUpdate" } } } }, "responses": { - "204": { - "description": "Success - action completed" + "200": { + "description": "Updated", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Sync" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, "403": { "$ref": "#/components/responses/Forbidden" }, + "404": { + "$ref": "#/components/responses/NotFound" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -7699,36 +8051,53 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/tables/{table_name}/data": { - "get": { - "description": "List Table Rows", - "operationId": "TableListRows", + }, + "delete": { + "description": "Delete Sync. This will delete Sync configuration and all associated sync runs, but will not delete the associated source and destination(s). These will need to be deleted separately.", + "operationId": "DeleteSync", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_selects" + "$ref": "#/components/parameters/sync_name" + } + ], + "responses": { + "204": { + "description": "Deleted" }, - { - "$ref": "#/components/parameters/table_filter_mode" + "400": { + "$ref": "#/components/responses/BadRequest" }, - { - "$ref": "#/components/parameters/table_filters" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" }, - { - "$ref": "#/components/parameters/table_filter_ids" + "404": { + "$ref": "#/components/responses/NotFound" }, - { - "$ref": "#/components/parameters/table_sort_bys" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/syncs/{sync_name}/runs": { + "get": { + "description": "List all Sync Runs.", + "operationId": "ListSyncRuns", + "tags": [ + "syncs" + ], + "parameters": [ { - "$ref": "#/components/parameters/table_sort_dirs" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/table_group_bys" + "$ref": "#/components/parameters/migration_filter" }, { "$ref": "#/components/parameters/per_page" @@ -7744,12 +8113,15 @@ "application/json": { "schema": { "required": [ - "data", + "items", "metadata" ], "properties": { - "data": { - "$ref": "#/components/schemas/TableData" + "items": { + "items": { + "$ref": "#/components/schemas/SyncRun" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -7759,72 +8131,35 @@ } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + }, + "post": { + "description": "Create new SyncRun. This will trigger a manual job run.", + "operationId": "CreateSyncRun", "tags": [ - "tables" - ] - } - }, - "/tables/{table_name}/data/{table_row_id}": { - "get": { - "description": "Get Table row", - "operationId": "TableRowById", + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_row_id" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_filters" - }, - { - "$ref": "#/components/parameters/table_filter_ids" + "$ref": "#/components/parameters/sync_name" } ], "responses": { - "200": { + "201": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "data", - "matches" - ], - "properties": { - "data": { - "$ref": "#/components/schemas/TableRow" - }, - "matches": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableRowFieldMatch" - } - } - } + "$ref": "#/components/schemas/SyncRun" } } } @@ -7835,31 +8170,28 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables" - ] + } } }, - "/tables/{table_name}/schema": { + "/syncs/{sync_name}/runs/{sync_run_id}": { "get": { - "description": "Get Table Schema", - "operationId": "TableSchema", + "description": "Get a Sync Run.", + "operationId": "GetSyncRun", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" } ], "responses": { @@ -7868,22 +8200,7 @@ "content": { "application/json": { "schema": { - "required": [ - "schema", - "default_columns" - ], - "properties": { - "schema": { - "$ref": "#/components/schemas/TableSchema" - }, - "default_columns": { - "type": "array", - "items": { - "type": "string", - "description": "Column name" - } - } - } + "$ref": "#/components/schemas/SyncRunDetails" } } } @@ -7891,137 +8208,58 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + }, + "patch": { + "description": "Update a SyncRun", + "operationId": "UpdateSyncRun", "tags": [ - "tables" - ] - } - }, - "/tables/schemas": { - "get": { - "description": "Get Table Schemas", - "operationId": "BatchTableSchemas", + "syncs" + ], "parameters": [ { - "name": "tables", - "in": "query", - "description": "A list of table names to retrieve schemas for", - "required": true, - "schema": { - "type": "array", - "items": { - "type": "string", - "minLength": 1 - }, - "example": [ - "aws_ec2_instances", - "aws_s3_buckets" - ] - } + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" } ], - "responses": { - "200": { - "description": "Response", - "content": { - "application/json": { - "schema": { - "required": [ - "items" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/BatchTableSchemaItem" - } - } + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "status_reason": { + "$ref": "#/components/schemas/SyncRunStatusReason" } } } } - }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" } }, - "tags": [ - "tables" - ] - } - }, - "/tables/{table_name}/columns": { - "get": { - "description": "Get Table Columns", - "operationId": "TableListColumns", - "parameters": [ - { - "$ref": "#/components/parameters/table_name" - }, - { - "$ref": "#/components/parameters/table_filter_mode" - }, - { - "$ref": "#/components/parameters/table_column_name_filter" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/per_page" - } - ], "responses": { "200": { - "description": "Response", + "description": "Updated", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableColumnListItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/SyncRun" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" }, "403": { "$ref": "#/components/responses/Forbidden" @@ -8035,34 +8273,42 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables" - ] + } } }, - "/tables/{table_name}/columns/{column_name}/values": { + "/syncs/{sync_name}/runs/{sync_run_id}/logs/query": { "get": { - "description": "Get Table Column Values", - "operationId": "TableColumnListValues", + "description": "Get logs for a sync run.", + "operationId": "GetSyncRunLogsQuery", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/column_name" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/table_filter_mode" + "$ref": "#/components/parameters/sync_run_id" }, { - "$ref": "#/components/parameters/table_column_value_filter" + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/download_file" } ], "responses": { @@ -8072,30 +8318,36 @@ "application/json": { "schema": { "required": [ - "items", + "data", "metadata" ], "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TableColumnValueListItem" - } + "data": { + "$ref": "#/components/schemas/TableData" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" } } } + }, + "text/plain": { + "schema": { + "type": "string", + "description": "Download file." + } } } }, + "204": { + "description": "No logs available for a test connection that has not started." + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8105,64 +8357,62 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables" - ] + } } }, - "/tables/{table_name}/filters": { + "/syncs/{sync_name}/runs/{sync_run_id}/logs/live": { "get": { - "description": "List Table Filters", - "operationId": "TableListFilters", + "description": "Get live logs for a sync run.", + "operationId": "GetSyncRunLogsLive", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } }, { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/sync_name" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/sync_run_id" }, { - "$ref": "#/components/parameters/filter_tags" + "in": "query", + "name": "table", + "required": false, + "schema": { + "type": "string", + "description": "Table name to filter logs by. Use a single dash (\"-\") as input to exclude all table-specific log lines." + } } ], "responses": { "200": { "description": "Response", "content": { - "application/json": { + "text/plain": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Filter" - } - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "type": "string", + "description": "Chunked response logs for a sync run that is in progress." } } } }, + "204": { + "description": "No logs available for a sync run that has not started." + }, "400": { "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -8172,18 +8422,23 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables", - "filters" - ] - }, + } + } + }, + "/syncs/{sync_name}/runs/{sync_run_id}/progress": { "post": { - "description": "Save Table Filter", - "operationId": "TableSaveFilter", + "description": "Create a new sync run progress update.", + "operationId": "CreateSyncRunProgress", + "x-internal": true, + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" } ], "requestBody": { @@ -8191,28 +8446,94 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/FilterCreate" + "type": "object", + "required": [ + "rows", + "warnings", + "errors" + ], + "properties": { + "rows": { + "type": "integer", + "format": "int64", + "description": "Number of rows synced so far" + }, + "warnings": { + "type": "integer", + "format": "int64", + "description": "Number of warnings encountered so far" + }, + "errors": { + "type": "integer", + "format": "int64", + "description": "Number of errors encountered so far" + }, + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "shard_num": { + "type": "integer", + "format": "int32", + "description": "The shard number that this progress update is for" + }, + "shard_total": { + "type": "integer", + "format": "int32", + "description": "The total number of shards for this sync run" + }, + "table_progress": { + "$ref": "#/components/schemas/SyncRunTableProgress", + "description": "Table-specific progress information including error and row counts per table" + } + } } } } }, "responses": { - "200": { - "description": "Filter already exists", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Filter" - } - } - } + "204": { + "description": "Progress was reported successfully" }, - "201": { - "description": "Filter created", + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/syncs/{sync_name}/runs/{sync_run_id}/stats": { + "get": { + "description": "Get statistics on a Sync Run", + "operationId": "GetSyncRunStats", + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" + } + ], + "responses": { + "200": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Filter" + "$ref": "#/components/schemas/SyncRunStats" } } } @@ -8223,38 +8544,40 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "tables", - "filters" - ] + } } }, - "/tables/{table_name}/filters/tags": { + "/syncs/{sync_name}/runs/{sync_run_id}/tables": { "get": { - "description": "List Filter Tags For A Table", - "operationId": "TableListFilterTags", + "description": "Get table details on a Sync Run", + "operationId": "GetSyncRunTables", + "tags": [ + "syncs" + ], "parameters": [ { - "$ref": "#/components/parameters/table_name" + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" }, { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_run_table_sort_bys" + }, + { + "$ref": "#/components/parameters/table_sort_dirs" } ], "responses": { @@ -8269,10 +8592,10 @@ ], "properties": { "items": { - "type": "array", "items": { - "$ref": "#/components/schemas/FilterTag" - } + "$ref": "#/components/schemas/SyncRunTableStat" + }, + "type": "array" }, "metadata": { "$ref": "#/components/schemas/ListMetadata" @@ -8282,103 +8605,58 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "queries", - "filters" - ] + } } }, - "/usage-summary": { + "/tables": { "get": { - "description": "Get a summary of usage for the specified time range.", - "operationId": "GetTeamUsageSummary", + "description": "List Tables", + "operationId": "ListTables", "parameters": [ { - "in": "query", - "name": "metrics", - "required": false, - "schema": { - "type": "array", - "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", - "items": { - "type": "string", - "enum": [ - "paid_rows", - "cloud_vcpu_seconds", - "cloud_vram_byte_seconds", - "network_egress_bytes" - ] - }, - "default": [ - "paid_rows" - ] - } - }, - { - "in": "query", - "name": "start", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." - } - }, - { - "in": "query", - "name": "end", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." - } + "$ref": "#/components/parameters/per_page" }, { - "in": "query", - "name": "aggregation_period", - "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", - "required": false, - "schema": { - "type": "string", - "default": "day", - "enum": [ - "day", - "month" - ] - } + "$ref": "#/components/parameters/page" } ], "responses": { "200": { - "description": "A summary of usage for the specified time range.", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/UsageSummary" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -8396,92 +8674,189 @@ } }, "tags": [ - "usage" + "tables" ] } }, - "/usage-summary/{group_by}": { + "/tables/data": { "get": { - "description": "Get a grouped summary of usage for the specified time range.", - "operationId": "GetGroupedTeamUsageSummary", + "description": "Get all sources and their associated tables. Returns data in the format needed for the delete action.", + "operationId": "GetTablesData", + "tags": [ + "tables" + ], "parameters": [ { - "in": "path", - "name": "group_by", - "required": true, - "schema": { - "type": "string", - "enum": [ - "price_category", - "plugin", - "sync_id" - ], - "description": "Group by usage summary. `plugin` and `price_category` groupings are only available for `paid-rows`." - } + "$ref": "#/components/parameters/per_page" }, { - "in": "query", - "name": "metrics", - "required": false, - "schema": { - "type": "array", - "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", - "items": { - "type": "string", - "enum": [ - "paid_rows", - "cloud_vcpu_seconds", - "cloud_vram_byte_seconds", - "network_egress_bytes" - ] - }, - "default": [ - "paid_rows" - ] + "$ref": "#/components/parameters/page" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "sources", + "metadata" + ], + "properties": { + "sources": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableDataListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + }, + "example": { + "sources": [ + { + "source_name": "aws-integration", + "display_name": "AWS Integration", + "tables": [ + { + "name": "aws_ec2_instances", + "deletion_pending": false + }, + { + "name": "aws_s3_buckets", + "deletion_pending": true + } + ], + "plugin": "cloudquery/aws" + }, + { + "source_name": "gcp-integration", + "display_name": "GCP Integration", + "tables": [ + { + "name": "gcp_compute_instances", + "deletion_pending": false + } + ], + "plugin": "cloudquery/gcp" + } + ], + "metadata": { + "page_size": 10, + "last_page": 1, + "total_count": 2 + } + } + } + } } }, - { - "in": "query", - "name": "start", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + }, + "post": { + "description": "Perform an action on table data across multiple sources. Supported actions: delete (drops partitions for specified tenant/source/table combinations).", + "operationId": "TablesDataAction", + "tags": [ + "tables" + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/TableDataAction" + } } + } + }, + "responses": { + "204": { + "description": "Success - action completed" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/tables/{table_name}/data": { + "get": { + "description": "List Table Rows", + "operationId": "TableListRows", + "parameters": [ { - "in": "query", - "name": "end", - "required": false, - "schema": { - "type": "string", - "format": "date-time", - "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." - } + "$ref": "#/components/parameters/table_name" }, { - "in": "query", - "name": "aggregation_period", - "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", - "required": false, - "schema": { - "type": "string", - "default": "day", - "enum": [ - "day", - "month" - ] - } + "$ref": "#/components/parameters/table_selects" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/table_filter_ids" + }, + { + "$ref": "#/components/parameters/table_sort_bys" + }, + { + "$ref": "#/components/parameters/table_sort_dirs" + }, + { + "$ref": "#/components/parameters/table_group_bys" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" } ], "responses": { "200": { - "description": "A summary of usage for the specified time range.", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/UsageSummary" + "required": [ + "data", + "metadata" + ], + "properties": { + "data": { + "$ref": "#/components/schemas/TableData" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -8506,36 +8881,29 @@ } }, "tags": [ - "usage" + "tables" ] } }, - "/users": { + "/tables/{table_name}/data/{table_row_id}": { "get": { - "description": "List all users", - "operationId": "ListUsers", + "description": "Get Table row", + "operationId": "TableRowById", "parameters": [ { - "$ref": "#/components/parameters/per_page" + "$ref": "#/components/parameters/table_name" }, { - "$ref": "#/components/parameters/page" + "$ref": "#/components/parameters/table_row_id" }, { - "name": "user_search", - "description": "Search by user name or email", - "in": "query", - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/table_filter_mode" }, { - "name": "role_id", - "description": "Search by user role ID", - "in": "query", - "schema": { - "$ref": "#/components/schemas/RoleID" - } + "$ref": "#/components/parameters/table_filters" + }, + { + "$ref": "#/components/parameters/table_filter_ids" } ], "responses": { @@ -8545,18 +8913,18 @@ "application/json": { "schema": { "required": [ - "items", - "metadata" + "data", + "matches" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/User" - }, - "type": "array" + "data": { + "$ref": "#/components/schemas/TableRow" }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "matches": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableRowFieldMatch" + } } } } @@ -8575,65 +8943,53 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" + "tables" ] - }, - "post": { - "description": "Add new user", - "operationId": "AddUser", - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "name", - "roles" - ], - "properties": { - "email": { - "type": "string" - }, - "name": { - "type": "string" - }, - "password": { - "type": "string" - }, - "roles": { - "description": "Roles for the user", - "type": "array", - "minItems": 0, - "items": { - "$ref": "#/components/schemas/RoleID" - } - } - } - } - } + } + }, + "/tables/{table_name}/schema": { + "get": { + "description": "Get Table Schema", + "operationId": "TableSchema", + "parameters": [ + { + "$ref": "#/components/parameters/table_name" } - }, + ], "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/User" + "required": [ + "schema", + "default_columns" + ], + "properties": { + "schema": { + "$ref": "#/components/schemas/TableSchema" + }, + "default_columns": { + "type": "array", + "items": { + "type": "string", + "description": "Column name" + } + } + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -8643,9 +8999,6 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -8654,109 +9007,87 @@ } }, "tags": [ - "users", - "admin" + "tables" ] } }, - "/users/{user_id}": { + "/tables/relations": { "get": { - "description": "Get user details", - "operationId": "GetUser", - "parameters": [ - { - "$ref": "#/components/parameters/user_id" - } - ], + "description": "Get resource relations for all configured tables.", + "operationId": "GetTablesRelations", "responses": { "200": { + "description": "Resource relations keyed by source table name.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/User" + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RelationDef" + } + } } } - }, - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users", - "admin" + "tables" ] - }, - "patch": { - "description": "Update user", - "operationId": "UpdateUser", + } + }, + "/tables/schemas": { + "get": { + "description": "Get Table Schemas", + "operationId": "BatchTableSchemas", "parameters": [ { - "$ref": "#/components/parameters/user_id" - } - ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "email": { - "type": "string" - }, - "name": { - "type": "string" - }, - "password": { - "type": "string" - }, - "enabled": { - "type": "boolean" - }, - "roles": { - "description": "Roles for the user", - "type": "array", - "minItems": 0, - "items": { - "$ref": "#/components/schemas/RoleID" - } - } - } - } + "name": "tables", + "in": "query", + "description": "A list of table names to retrieve schemas for", + "required": true, + "schema": { + "type": "array", + "items": { + "type": "string", + "minLength": 1 + }, + "example": [ + "aws_ec2_instances", + "aws_s3_buckets" + ] } } - }, + ], "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/User" + "required": [ + "items" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/BatchTableSchemaItem" + } + } + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -8774,24 +9105,55 @@ } }, "tags": [ - "users", - "admin" + "tables" ] - }, - "delete": { - "description": "Delete user", - "operationId": "DeleteUser", + } + }, + "/tables/{table_name}/columns": { + "get": { + "description": "Get Table Columns", + "operationId": "TableListColumns", "parameters": [ { - "$ref": "#/components/parameters/user_id" + "$ref": "#/components/parameters/table_name" + }, + { + "$ref": "#/components/parameters/table_filter_mode" + }, + { + "$ref": "#/components/parameters/table_column_name_filter" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/per_page" } ], "responses": { - "204": { - "description": "Response" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableColumnListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -8810,100 +9172,64 @@ } }, "tags": [ - "users", - "admin" + "tables" ] } }, - "/users/{user_id}/totp": { - "delete": { - "description": "Disable/Reset MFA for a specific user", - "operationId": "DeleteUserTOTP", + "/tables/{table_name}/columns/{column_name}/values": { + "get": { + "description": "Get Table Column Values", + "operationId": "TableColumnListValues", "parameters": [ { - "$ref": "#/components/parameters/user_id" - } - ], - "responses": { - "204": { - "description": "Success" - }, - "400": { - "$ref": "#/components/responses/BadRequest" + "$ref": "#/components/parameters/table_name" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + { + "$ref": "#/components/parameters/column_name" }, - "403": { - "$ref": "#/components/responses/Forbidden" + { + "$ref": "#/components/parameters/table_filter_mode" }, - "404": { - "$ref": "#/components/responses/NotFound" + { + "$ref": "#/components/parameters/table_column_value_filter" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + { + "$ref": "#/components/parameters/page" }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - } - }, - "/auth/saml": { - "get": { - "description": "Get SAML integration information", - "operationId": "GetSAML", - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SAMLConfig" - } - } - } - }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "admin" - ] - }, - "patch": { - "description": "Update SAML integration information", - "operationId": "UpdateSAML", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SAMLConfigUpdate" - } - } + { + "$ref": "#/components/parameters/per_page" } - }, + ], "responses": { "200": { - "description": "Success", + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SAMLConfig" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/TableColumnValueListItem" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" }, "404": { "$ref": "#/components/responses/NotFound" @@ -8916,25 +9242,56 @@ } }, "tags": [ - "admin" + "tables" ] } }, - "/settings": { + "/tables/{table_name}/filters": { "get": { - "description": "Show current platform settings", - "operationId": "GetSettings", + "description": "List Table Filters", + "operationId": "TableListFilters", + "parameters": [ + { + "$ref": "#/components/parameters/table_name" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/filter_tags" + } + ], "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformSettings" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Filter" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -8952,68 +9309,52 @@ } }, "tags": [ - "admin" + "tables", + "filters" ] }, - "patch": { - "description": "Update platform settings", - "operationId": "UpdateSettings", + "post": { + "description": "Save Table Filter", + "operationId": "TableSaveFilter", + "parameters": [ + { + "$ref": "#/components/parameters/table_name" + } + ], "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformSettingsUpdate" + "$ref": "#/components/schemas/FilterCreate" } } } }, "responses": { "200": { - "description": "Response", + "description": "Filter already exists", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformSettings" + "$ref": "#/components/schemas/Filter" } } } }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, - "404": { - "$ref": "#/components/responses/NotFound" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "admin" - ] - } - }, - "/settings/data": { - "get": { - "description": "Show current platform data settings", - "operationId": "GetDataSettings", - "responses": { - "200": { - "description": "Response", + "201": { + "description": "Filter created", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformDataSettings" + "$ref": "#/components/schemas/Filter" } } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -9031,28 +9372,47 @@ } }, "tags": [ - "admin" + "tables", + "filters" ] - }, - "patch": { - "description": "Update platform data settings", - "operationId": "UpdateDataSettings", - "requestBody": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/PlatformDataSettingsUpdate" - } - } + } + }, + "/tables/{table_name}/filters/tags": { + "get": { + "description": "List Filter Tags For A Table", + "operationId": "TableListFilterTags", + "parameters": [ + { + "$ref": "#/components/parameters/table_name" + }, + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" } - }, + ], "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PlatformDataSettings" + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/FilterTag" + } + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } } } } @@ -9074,112 +9434,79 @@ } }, "tags": [ - "admin" + "queries", + "filters" ] } }, - "/user": { + "/usage-summary": { "get": { - "description": "Get the current authenticated user from the OAuth token\n", - "operationId": "GetCurrentUser", - "parameters": [], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "$ref": "#/components/schemas/User" - }, - { - "type": "object", - "properties": { - "event_identifiers": { - "type": "object", - "additionalProperties": true - }, - "group_identifier": { - "type": "string" - }, - "registered_team_name": { - "type": "string", - "description": "The name of the team that the platform is registered with" - }, - "registered_team_internal": { - "type": "boolean", - "description": "Whether the team is internal or not" - } - } - } - ] - } - } - }, - "description": "Response" + "description": "Get a summary of usage for the specified time range.", + "operationId": "GetTeamUsageSummary", + "parameters": [ + { + "in": "query", + "name": "metrics", + "required": false, + "schema": { + "type": "array", + "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", + "items": { + "type": "string", + "enum": [ + "paid_rows", + "cloud_vcpu_seconds", + "cloud_vram_byte_seconds", + "network_egress_bytes" + ] + }, + "default": [ + "paid_rows" + ] + } }, - "401": { - "content": { - "application/json": { - "schema": { - "allOf": [ - { - "$ref": "#/components/schemas/BasicError" - }, - { - "properties": { - "password_reset_required": { - "type": "boolean", - "description": "Whether the user needs to reset their password" - } - } - } - ] - } - } + { + "in": "query", + "name": "start", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." } }, - "403": { - "$ref": "#/components/responses/Forbidden" + { + "in": "query", + "name": "end", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." + } }, - "500": { - "$ref": "#/components/responses/InternalError" - } - }, - "tags": [ - "users" - ] - }, - "patch": { - "description": "Update attributes for the current authenticated user from the OAuth token", - "operationId": "UpdateCurrentUser", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "properties": { - "name": { - "$ref": "#/components/schemas/UserName" - }, - "tracking_opt_in": { - "type": "boolean", - "description": "Whether to opt in or out of anonymous user tracking" - } - } - } + { + "in": "query", + "name": "aggregation_period", + "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", + "required": false, + "schema": { + "type": "string", + "default": "day", + "enum": [ + "day", + "month" + ] } } - }, + ], "responses": { "200": { - "description": "Response", + "description": "A summary of usage for the specified time range.", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/User" + "$ref": "#/components/schemas/UsageSummary" } } } @@ -9193,116 +9520,178 @@ "403": { "$ref": "#/components/responses/Forbidden" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" + "usage" ] } }, - "/user/anon-event": { - "post": { - "description": "Send an anonymous event", - "operationId": "SendAnonymousEvent", - "x-internal": true, - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "name", - "anonymous_id" - ], - "properties": { - "name": { - "type": "string", - "description": "Name of event" - }, - "anonymous_id": { - "type": "string", - "description": "Anonymous ID identifying the user", - "x-go-name": "AnonymousID" - }, - "properties": { - "type": "object", - "description": "Properties of event, keys should be of string type" - } - } - } + "/usage-summary/{group_by}": { + "get": { + "description": "Get a grouped summary of usage for the specified time range.", + "operationId": "GetGroupedTeamUsageSummary", + "parameters": [ + { + "in": "path", + "name": "group_by", + "required": true, + "schema": { + "type": "string", + "enum": [ + "price_category", + "plugin", + "sync_id" + ], + "description": "Group by usage summary. `plugin` and `price_category` groupings are only available for `paid-rows`." + } + }, + { + "in": "query", + "name": "metrics", + "required": false, + "schema": { + "type": "array", + "description": "A list of metrics to include in the response. Each metric must be one of the predefined valid values. If not provided, only `paid-rows` will be included.", + "items": { + "type": "string", + "enum": [ + "paid_rows", + "cloud_vcpu_seconds", + "cloud_vram_byte_seconds", + "network_egress_bytes" + ] + }, + "default": [ + "paid_rows" + ] + } + }, + { + "in": "query", + "name": "start", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the inclusive start of the query time range. Defaults to 30 days ago." + } + }, + { + "in": "query", + "name": "end", + "required": false, + "schema": { + "type": "string", + "format": "date-time", + "description": "A valid ISO-8601-formatted date and time, indicating the exclusive end of the query time range. Defaults to the current time." + } + }, + { + "in": "query", + "name": "aggregation_period", + "description": "An aggregation period to sum data over. In other words, data will be returned at this granularity. Currently only supports day and month.", + "required": false, + "schema": { + "type": "string", + "default": "day", + "enum": [ + "day", + "month" + ] } } - }, + ], "responses": { - "204": { - "description": "Success" + "200": { + "description": "A summary of usage for the specified time range.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/UsageSummary" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "analytics" - ], - "security": [] + "usage" + ] } }, - "/user/authenticate": { - "post": { - "description": "Authenticate a user with password", - "operationId": "AuthenticateUser", - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "email", - "password" - ], - "properties": { - "email": { - "type": "string" - }, - "password": { - "type": "string" - } - } - } + "/users": { + "get": { + "description": "List all users", + "operationId": "ListUsers", + "parameters": [ + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "name": "user_search", + "description": "Search by user name or email", + "in": "query", + "schema": { + "type": "string" + } + }, + { + "name": "role_id", + "description": "Search by user role ID", + "in": "query", + "schema": { + "$ref": "#/components/schemas/RoleID" } } - }, + ], "responses": { "200": { - "description": "Authentication is successful", + "description": "Response", "content": { "application/json": { "schema": { "required": [ - "id_token" + "items", + "metadata" ], "properties": { - "id_token": { - "type": "string", - "x-go-name": "IDToken" + "items": { + "items": { + "$ref": "#/components/schemas/User" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" } } } @@ -9321,30 +9710,17 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" - }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ "users" - ], - "security": [] - } - }, - "/user/change-password": { + ] + }, "post": { - "description": "Change user password", - "operationId": "ChangeUserPassword", - "parameters": [], + "description": "Add new user", + "operationId": "AddUser", "requestBody": { "content": { "application/json": { @@ -9353,18 +9729,26 @@ "additionalProperties": false, "required": [ "email", - "old_password", - "new_password" + "name", + "roles" ], "properties": { "email": { "type": "string" }, - "old_password": { + "name": { "type": "string" }, - "new_password": { + "password": { "type": "string" + }, + "roles": { + "description": "Roles for the user", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/components/schemas/RoleID" + } } } } @@ -9372,14 +9756,12 @@ } }, "responses": { - "204": { - "description": "Successful", - "headers": { - "Set-Cookie": { - "description": "Reset session cookie", + "200": { + "description": "Response", + "content": { + "application/json": { "schema": { - "type": "string", - "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + "$ref": "#/components/schemas/User" } } } @@ -9407,44 +9789,89 @@ } }, "tags": [ - "users" + "users", + "admin" ] } }, - "/user/customer": { + "/users/{user_id}": { + "get": { + "description": "Get user details", + "operationId": "GetUser", + "parameters": [ + { + "$ref": "#/components/parameters/user_id" + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/User" + } + } + }, + "description": "Response" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "users", + "admin" + ] + }, "patch": { - "description": "Update customer details", - "operationId": "UpdateCustomer", - "x-internal": true, - "parameters": [], + "description": "Update user", + "operationId": "UpdateUser", + "parameters": [ + { + "$ref": "#/components/parameters/user_id" + } + ], "requestBody": { "content": { "application/json": { "schema": { "type": "object", "additionalProperties": false, - "required": [ - "first_name", - "last_name" - ], "properties": { - "first_name": { - "type": "string" - }, - "last_name": { + "email": { "type": "string" }, - "company_name": { + "name": { "type": "string" }, - "learned_about_cq_from": { + "password": { "type": "string" }, - "learned_about_cq_from_other": { - "type": "string" + "enabled": { + "type": "boolean" }, - "phone": { - "type": "string" + "roles": { + "description": "Roles for the user", + "type": "array", + "minItems": 0, + "items": { + "$ref": "#/components/schemas/RoleID" + } } } } @@ -9452,8 +9879,15 @@ } }, "responses": { - "201": { - "description": "Queued for processing" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/User" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -9461,6 +9895,9 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -9472,42 +9909,21 @@ } }, "tags": [ - "analytics" + "users", + "admin" ] - } - }, - "/user/event": { - "post": { - "description": "Send a user event", - "operationId": "SendUserEvent", - "x-internal": true, - "parameters": [], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "name" - ], - "properties": { - "name": { - "type": "string", - "description": "Name of event" - }, - "properties": { - "type": "object", - "description": "Properties of event, keys should be of string type" - } - } - } - } + }, + "delete": { + "description": "Delete user", + "operationId": "DeleteUser", + "parameters": [ + { + "$ref": "#/components/parameters/user_id" } - }, + ], "responses": { "204": { - "description": "Success" + "description": "Response" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -9515,6 +9931,9 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -9526,52 +9945,94 @@ } }, "tags": [ - "analytics" + "users", + "admin" ] } }, - "/user/totp/verify": { - "post": { - "description": "Verify a one time password for MFA", - "operationId": "UserTOTPVerify", + "/users/{user_id}/totp": { + "delete": { + "description": "Disable/Reset MFA for a specific user", + "operationId": "DeleteUserTOTP", "parameters": [ { - "name": "__cqp_sess", - "in": "cookie", - "style": "form", - "schema": { - "type": "string" - } + "$ref": "#/components/parameters/user_id" } ], + "responses": { + "204": { + "description": "Success" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "users" + ] + } + }, + "/auth/saml": { + "get": { + "description": "Get SAML integration information", + "operationId": "GetSAML", + "responses": { + "200": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SAMLConfig" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "admin" + ] + }, + "patch": { + "description": "Update SAML integration information", + "operationId": "UpdateSAML", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "additionalProperties": false, - "required": [ - "otp" - ], - "properties": { - "otp": { - "type": "string", - "x-go-name": "OTP" - } - } + "$ref": "#/components/schemas/SAMLConfigUpdate" } } } }, "responses": { - "204": { - "description": "Multifactor authentication is complete.", - "headers": { - "Set-Cookie": { - "description": "Session cookie", + "200": { + "description": "Success", + "content": { + "application/json": { "schema": { - "type": "string", - "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + "$ref": "#/components/schemas/SAMLConfig" } } } @@ -9579,56 +10040,32 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" - }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" + "admin" ] } }, - "/user/totp": { - "post": { - "description": "Set up MFA for the current user", - "operationId": "UserTOTPSetup", - "parameters": [], + "/auth/saml/rollover": { + "put": { + "description": "Create new SAML rollover certificate", + "operationId": "CreateSAMLRolloverCertificate", "responses": { "200": { - "description": "Response", + "description": "Success", "content": { "application/json": { "schema": { - "required": [ - "secret", - "url" - ], - "properties": { - "url": { - "type": "string" - }, - "secret": { - "type": "string" - } - } + "$ref": "#/components/schemas/SAMLConfig" } } } @@ -9636,17 +10073,11 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "409": { + "$ref": "#/components/responses/Conflict" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" @@ -9656,13 +10087,32 @@ } }, "tags": [ - "users" + "admin" ] }, "delete": { - "description": "Disable MFA for the current user", - "operationId": "UserTOTPDelete", - "parameters": [], + "description": "Delete current SAML rollover certificate", + "operationId": "DeleteSAMLRolloverCertificate", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "fingerprint" + ], + "properties": { + "fingerprint": { + "type": "string", + "description": "The fingerprint of the rollover certificate to delete", + "example": "SHA256:AB:CD:EF:12:34:56:78:90:AB:CD:EF:12:34:56:78:90" + } + } + } + } + } + }, "responses": { "204": { "description": "Success" @@ -9670,45 +10120,39 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" + "admin" ] } }, - "/user/login": { - "post": { - "description": "Start a session using ID token", - "operationId": "LoginUser", - "parameters": [], + "/auth/saml/rollover/promote": { + "put": { + "description": "Promote SAML rollover certificate", + "operationId": "PromoteSAMLRolloverCertificate", "requestBody": { + "required": true, "content": { "application/json": { "schema": { "type": "object", - "additionalProperties": false, "required": [ - "id_token" + "fingerprint" ], "properties": { - "id_token": { + "fingerprint": { "type": "string", - "x-go-name": "IDToken" + "description": "The fingerprint of the rollover certificate to promote", + "example": "SHA256:AB:CD:EF:12:34:56:78:90:AB:CD:EF:12:34:56:78:90" } } } @@ -9716,14 +10160,12 @@ } }, "responses": { - "204": { - "description": "Authentication is complete.", - "headers": { - "Set-Cookie": { - "description": "Session cookie", + "200": { + "description": "Success", + "content": { + "application/json": { "schema": { - "type": "string", - "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + "$ref": "#/components/schemas/SAMLConfig" } } } @@ -9731,46 +10173,36 @@ "400": { "$ref": "#/components/responses/BadRequest" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" - }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" - ], - "security": [] - }, - "delete": { - "description": "Logout a session", - "operationId": "LogoutUser", + "admin" + ] + } + }, + "/settings": { + "get": { + "description": "Show current platform settings", + "operationId": "GetSettings", "responses": { - "204": { - "description": "Logout is complete.", - "headers": { - "Set-Cookie": { - "description": "Empty session cookie", + "200": { + "description": "Response", + "content": { + "application/json": { "schema": { - "type": "string", - "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + "$ref": "#/components/schemas/PlatformSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, @@ -9780,111 +10212,82 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "405": { - "$ref": "#/components/responses/MethodNotAllowed" + "422": { + "$ref": "#/components/responses/UnprocessableEntity" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "users" + "admin" ] - } - }, - "/v2/sync-destination-test-connections": { - "post": { - "description": "Create a test destination connection.", - "operationId": "CreateV2SyncDestinationTestConnection", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { + }, + "patch": { + "description": "Update platform settings", + "operationId": "UpdateSettings", + "requestBody": { + "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/CreateSyncDestinationTestConnectionV2" + "$ref": "#/components/schemas/PlatformSettingsUpdate" } } } }, "responses": { - "201": { + "200": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnectionV2" + "$ref": "#/components/schemas/PlatformSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] } }, - "/v2/sync-destinations": { - "post": { - "description": "Create sync destination based on test connection.", - "operationId": "CreateV2SyncDestination", - "tags": [ - "syncs" - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateSyncDestinationV2" - } - } - } - }, + "/settings/data": { + "get": { + "description": "Show current platform data settings", + "operationId": "GetDataSettings", "responses": { "200": { - "description": "Successful response indicating that an existing sync destination was replaced.", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" - } - } - } - }, - "201": { "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" + "$ref": "#/components/schemas/PlatformDataSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -9894,122 +10297,146 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "get": { - "description": "List all sync destination definitions.", - "operationId": "GetV2SyncDestinations", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/sync_name_filter" - }, - { - "$ref": "#/components/parameters/sync_generic_sort_bys" - }, - { - "$ref": "#/components/parameters/sync_sort_dirs" + "admin" + ] + }, + "patch": { + "description": "Update platform data settings", + "operationId": "UpdateDataSettings", + "requestBody": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/PlatformDataSettingsUpdate" + } + } } - ], + }, "responses": { "200": { "description": "Response", "content": { "application/json": { "schema": { - "required": [ - "items", - "metadata" - ], - "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/SyncDestinationV2" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" - } - } + "$ref": "#/components/schemas/PlatformDataSettings" } } } }, - "400": { - "$ref": "#/components/responses/BadRequest" - }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, "404": { "$ref": "#/components/responses/NotFound" }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "admin" + ] } }, - "/v2/sync-destinations/{sync_destination_name}": { + "/user": { "get": { - "description": "Get a single sync destination definition.", - "operationId": "GetV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], + "description": "Get the current authenticated user from the OAuth token\n", + "operationId": "GetCurrentUser", + "parameters": [], "responses": { "200": { - "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationV2" + "allOf": [ + { + "$ref": "#/components/schemas/User" + }, + { + "type": "object", + "properties": { + "event_identifiers": { + "type": "object", + "additionalProperties": true + }, + "group_identifier": { + "type": "string" + }, + "registered_team_name": { + "type": "string", + "description": "The name of the team that the platform is registered with" + }, + "registered_team_internal": { + "type": "boolean", + "description": "Whether the team is internal or not" + } + } + } + ] } } - } + }, + "description": "Response" }, "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/BasicError" + }, + { + "properties": { + "password_reset_required": { + "type": "boolean", + "description": "Whether the user needs to reset their password" + } + } + } + ] + } + } + } }, - "404": { - "$ref": "#/components/responses/NotFound" + "403": { + "$ref": "#/components/responses/Forbidden" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "users" + ] }, "patch": { - "description": "Update a Sync Destination definition.", - "operationId": "PatchV2SyncDestination", - "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], + "description": "Update attributes for the current authenticated user from the OAuth token", + "operationId": "UpdateCurrentUser", + "parameters": [], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationUpdateV2" + "type": "object", + "additionalProperties": false, + "properties": { + "name": { + "$ref": "#/components/schemas/UserName" + }, + "tracking_opt_in": { + "type": "boolean", + "description": "Whether to opt in or out of anonymous user tracking" + } + } } } } @@ -10020,7 +10447,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestination" + "$ref": "#/components/schemas/User" } } } @@ -10031,92 +10458,119 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "404": { - "$ref": "#/components/responses/NotFound" + "403": { + "$ref": "#/components/responses/Forbidden" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } - } - }, - "delete": { - "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", - "operationId": "DeleteV2SyncDestination", + }, "tags": [ - "syncs" - ], - "parameters": [ - { - "$ref": "#/components/parameters/sync_destination_name" - } - ], + "users" + ] + } + }, + "/user/anon-event": { + "post": { + "description": "Send an anonymous event", + "operationId": "SendAnonymousEvent", + "x-internal": true, + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "name", + "anonymous_id" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of event" + }, + "anonymous_id": { + "type": "string", + "description": "Anonymous ID identifying the user", + "x-go-name": "AnonymousID" + }, + "properties": { + "type": "object", + "description": "Properties of event, keys should be of string type" + } + } + } + } + } + }, "responses": { "204": { - "description": "Deleted" + "description": "Success" }, - "401": { - "$ref": "#/components/responses/RequiresAuthentication" + "400": { + "$ref": "#/components/responses/BadRequest" }, "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "429": { + "$ref": "#/components/responses/TooManyRequests" }, "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "analytics" + ], + "security": [] } }, - "/rbac/permissions": { - "get": { - "description": "List all permissions", - "operationId": "ListAllRBACPermissions", - "parameters": [ - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/rbac_permissions_sort_bys" - }, - { - "$ref": "#/components/parameters/rbac_permissions_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter permissions by name or description." + "/user/authenticate": { + "post": { + "description": "Authenticate a user with password", + "operationId": "AuthenticateUser", + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "email", + "password" + ], + "properties": { + "email": { + "type": "string" + }, + "password": { + "type": "string" + } + } + } + } } - ], + }, "responses": { "200": { - "description": "Response", + "description": "Authentication is successful", "content": { "application/json": { "schema": { "required": [ - "items", - "metadata" + "id_token" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/RBACPermission" - }, - "type": "array" - }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "id_token": { + "type": "string", + "x-go-name": "IDToken" } } } @@ -10135,37 +10589,65 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "rbac" - ] - }, + "users" + ], + "security": [] + } + }, + "/user/change-password": { "post": { - "description": "Create a permission", - "operationId": "CreateRBACPermission", + "description": "Change user password", + "operationId": "ChangeUserPassword", + "parameters": [], "requestBody": { - "required": true, "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/RBACPermissionCreate" + "type": "object", + "additionalProperties": false, + "required": [ + "email", + "old_password", + "new_password" + ], + "properties": { + "email": { + "type": "string" + }, + "old_password": { + "type": "string" + }, + "new_password": { + "type": "string" + } + } } } } }, "responses": { - "201": { - "description": "Success", - "content": { - "application/json": { + "204": { + "description": "Successful", + "headers": { + "Set-Cookie": { + "description": "Reset session cookie", "schema": { - "$ref": "#/components/schemas/RBACPermission" + "type": "string", + "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } @@ -10182,6 +10664,9 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -10190,29 +10675,53 @@ } }, "tags": [ - "rbac" + "users" ] } }, - "/rbac/permissions/{permission_id}": { - "get": { - "description": "Get a permission", - "operationId": "GetRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/rbac_permission_id" - } - ], - "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermission" + "/user/customer": { + "patch": { + "description": "Update customer details", + "operationId": "UpdateCustomer", + "x-internal": true, + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "first_name", + "last_name" + ], + "properties": { + "first_name": { + "type": "string" + }, + "last_name": { + "type": "string" + }, + "company_name": { + "type": "string" + }, + "learned_about_cq_from": { + "type": "string" + }, + "learned_about_cq_from_other": { + "type": "string" + }, + "phone": { + "type": "string" + } } } } + } + }, + "responses": { + "201": { + "description": "Queued for processing" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -10220,9 +10729,6 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -10234,37 +10740,42 @@ } }, "tags": [ - "rbac" + "analytics" ] - }, - "patch": { - "description": "Update a permission", - "operationId": "UpdateRBACPermission", - "parameters": [ - { - "$ref": "#/components/parameters/rbac_permission_id" - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermissionUpdate" - } + } + }, + "/user/event": { + "post": { + "description": "Send a user event", + "operationId": "SendUserEvent", + "x-internal": true, + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of event" + }, + "properties": { + "type": "object", + "description": "Properties of event, keys should be of string type" + } + } + } } } }, "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACPermission" - } - } - } + "204": { + "description": "Success" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -10272,9 +10783,6 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -10286,20 +10794,58 @@ } }, "tags": [ - "rbac" + "analytics" ] - }, - "delete": { - "description": "Delete a permission", - "operationId": "DeleteRBACPermission", + } + }, + "/user/totp/verify": { + "post": { + "description": "Verify a one time password for MFA", + "operationId": "UserTOTPVerify", "parameters": [ { - "$ref": "#/components/parameters/rbac_permission_id" + "name": "__cqp_sess", + "in": "cookie", + "style": "form", + "schema": { + "type": "string" + } } ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "otp" + ], + "properties": { + "otp": { + "type": "string", + "x-go-name": "OTP" + } + } + } + } + } + }, "responses": { "204": { - "description": "Success" + "description": "Multifactor authentication is complete.", + "headers": { + "Set-Cookie": { + "description": "Session cookie", + "schema": { + "type": "string", + "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" @@ -10310,52 +10856,29 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "rbac" + "users" ] } }, - "/rbac/roles": { - "get": { - "description": "List all roles", - "operationId": "ListAllRBACRoles", - "parameters": [ - { - "$ref": "#/components/parameters/per_page" - }, - { - "$ref": "#/components/parameters/page" - }, - { - "$ref": "#/components/parameters/rbac_roles_sort_bys" - }, - { - "$ref": "#/components/parameters/rbac_roles_sort_dirs" - }, - { - "name": "search_term", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter roles by name or description." - }, - { - "name": "type", - "in": "query", - "schema": { - "type": "string" - }, - "description": "Filter roles by type." - } - ], + "/user/totp": { + "post": { + "description": "Set up MFA for the current user", + "operationId": "UserTOTPSetup", + "parameters": [], "responses": { "200": { "description": "Response", @@ -10363,18 +10886,15 @@ "application/json": { "schema": { "required": [ - "items", - "metadata" + "secret", + "url" ], "properties": { - "items": { - "items": { - "$ref": "#/components/schemas/Role" - }, - "type": "array" + "url": { + "type": "string" }, - "metadata": { - "$ref": "#/components/schemas/ListMetadata" + "secret": { + "type": "string" } } } @@ -10393,6 +10913,9 @@ "404": { "$ref": "#/components/responses/NotFound" }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, @@ -10401,32 +10924,16 @@ } }, "tags": [ - "rbac" + "users" ] }, - "post": { - "description": "Create a role", - "operationId": "CreateRBACRole", - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RBACRoleCreate" - } - } - } - }, + "delete": { + "description": "Disable MFA for the current user", + "operationId": "UserTOTPDelete", + "parameters": [], "responses": { - "201": { - "description": "Success", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/Role" - } - } - } + "204": { + "description": "Success" }, "400": { "$ref": "#/components/responses/BadRequest" @@ -10440,34 +10947,51 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "rbac" + "users" ] } }, - "/rbac/roles/{role_id}": { - "get": { - "description": "Get a role", - "operationId": "GetRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/rbac_role_id" + "/user/login": { + "post": { + "description": "Start a session using ID token", + "operationId": "LoginUser", + "parameters": [], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "additionalProperties": false, + "required": [ + "id_token" + ], + "properties": { + "id_token": { + "type": "string", + "x-go-name": "IDToken" + } + } + } + } } - ], + }, "responses": { - "200": { - "description": "Success", - "content": { - "application/json": { + "204": { + "description": "Authentication is complete.", + "headers": { + "Set-Cookie": { + "description": "Session cookie", "schema": { - "$ref": "#/components/schemas/Role" + "type": "string", + "example": "__session=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9Cg...; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" } } } @@ -10484,42 +11008,82 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "422": { - "$ref": "#/components/responses/UnprocessableEntity" + "405": { + "$ref": "#/components/responses/MethodNotAllowed" }, "500": { "$ref": "#/components/responses/InternalError" } }, "tags": [ - "rbac" - ] - }, - "patch": { - "description": "Update a role (custom roles only)", - "operationId": "UpdateRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/rbac_role_id" - } + "users" ], - "requestBody": { - "required": true, - "content": { + "security": [] + }, + "delete": { + "description": "Logout a session", + "operationId": "LogoutUser", + "responses": { + "204": { + "description": "Logout is complete.", + "headers": { + "Set-Cookie": { + "description": "Empty session cookie", + "schema": { + "type": "string", + "example": "__session=; HttpOnly; Secure; SameSite=None; Path=/; Max-Age=3600" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "405": { + "$ref": "#/components/responses/MethodNotAllowed" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "users" + ] + } + }, + "/v2/sync-destination-test-connections": { + "post": { + "description": "Create a test destination connection.", + "operationId": "CreateV2SyncDestinationTestConnection", + "tags": [ + "syncs" + ], + "requestBody": { + "required": true, + "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/RBACRoleUpdate" + "$ref": "#/components/schemas/CreateSyncDestinationTestConnectionV2" } } } }, "responses": { - "200": { - "description": "Success", + "201": { + "description": "Response", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/Role" + "$ref": "#/components/schemas/SyncDestinationTestConnectionV2" } } } @@ -10530,41 +11094,65 @@ "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "422": { "$ref": "#/components/responses/UnprocessableEntity" }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, "500": { "$ref": "#/components/responses/InternalError" } - }, + } + } + }, + "/v2/sync-destinations": { + "post": { + "description": "Create sync destination based on test connection.", + "operationId": "CreateV2SyncDestination", "tags": [ - "rbac" - ] - }, - "delete": { - "description": "Delete a role", - "operationId": "DeleteRBACRole", - "parameters": [ - { - "$ref": "#/components/parameters/rbac_role_id" - } + "syncs" ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateSyncDestinationV2" + } + } + } + }, "responses": { - "204": { - "description": "Success" + "200": { + "description": "Successful response indicating that an existing sync destination was replaced.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationV2" + } + } + } + }, + "201": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationV2" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, @@ -10574,22 +11162,29 @@ "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "rbac" - ] - } - }, - "/teams": { + } + }, "get": { - "description": "List all teams", - "operationId": "ListTeams", + "description": "List all sync destination definitions.", + "operationId": "GetV2SyncDestinations", + "tags": [ + "syncs" + ], "parameters": [ { "$ref": "#/components/parameters/per_page" }, { "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/sync_name_filter" + }, + { + "$ref": "#/components/parameters/sync_generic_sort_bys" + }, + { + "$ref": "#/components/parameters/sync_sort_dirs" } ], "responses": { @@ -10605,7 +11200,7 @@ "properties": { "items": { "items": { - "$ref": "#/components/schemas/Team" + "$ref": "#/components/schemas/SyncDestinationV2" }, "type": "array" }, @@ -10617,54 +11212,31 @@ } } }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, "401": { "$ref": "#/components/responses/RequiresAuthentication" }, - "403": { - "$ref": "#/components/responses/Forbidden" - }, "404": { "$ref": "#/components/responses/NotFound" }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "teams" - ] + } } }, - "/teams/{team_name}/plugins/{plugin_team}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { + "/v2/sync-destinations/{sync_destination_name}": { "get": { - "description": "Download an asset for a given plugin version as the current team.", - "operationId": "DownloadPluginAssetByTeam", + "description": "Get a single sync destination definition.", + "operationId": "GetV2SyncDestination", + "tags": [ + "syncs" + ], "parameters": [ { - "in": "header", - "name": "Accept", - "required": false, - "schema": { - "type": "string" - } - }, - { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/plugin_team" - }, - { - "$ref": "#/components/parameters/plugin_kind" - }, - { - "$ref": "#/components/parameters/plugin_name" - }, - { - "$ref": "#/components/parameters/version_name" - }, - { - "$ref": "#/components/parameters/target_name" + "$ref": "#/components/parameters/sync_destination_name" } ], "responses": { @@ -10673,17 +11245,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/PluginAsset" - } - } - } - }, - "302": { - "description": "Response", - "headers": { - "Location": { - "schema": { - "type": "string" + "$ref": "#/components/schemas/SyncDestinationV2" } } } @@ -10694,36 +11256,20 @@ "404": { "$ref": "#/components/responses/NotFound" }, - "429": { - "$ref": "#/components/responses/TooManyRequests" - }, "500": { "$ref": "#/components/responses/InternalError" } - }, - "tags": [ - "plugins" - ] - } - }, - "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/progress": { - "post": { - "description": "Deprecated. Create a new sync run progress update.", - "operationId": "CreateSyncRunProgressTeam", - "x-internal": true, - "deprecated": true, + } + }, + "patch": { + "description": "Update a Sync Destination definition.", + "operationId": "PatchV2SyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_name" - }, - { - "$ref": "#/components/parameters/sync_run_id" + "$ref": "#/components/parameters/sync_destination_name" } ], "requestBody": { @@ -10731,53 +11277,21 @@ "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "rows", - "warnings", - "errors" - ], - "properties": { - "rows": { - "type": "integer", - "format": "int64", - "description": "Number of rows synced so far" - }, - "warnings": { - "type": "integer", - "format": "int64", - "description": "Number of warnings encountered so far" - }, - "errors": { - "type": "integer", - "format": "int64", - "description": "Number of errors encountered so far" - }, - "status": { - "$ref": "#/components/schemas/SyncRunStatus" - }, - "shard_num": { - "type": "integer", - "format": "int32", - "description": "The shard number that this progress update is for" - }, - "shard_total": { - "type": "integer", - "format": "int32", - "description": "The total number of shards for this sync run" - }, - "table_progress": { - "$ref": "#/components/schemas/SyncRunTableProgress", - "description": "Table-specific progress information including error and row counts per table" - } - } + "$ref": "#/components/schemas/SyncDestinationUpdateV2" } } } }, "responses": { - "204": { - "description": "Progress was reported successfully" + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestination" + } + } + } }, "400": { "$ref": "#/components/responses/BadRequest" @@ -10795,59 +11309,131 @@ "$ref": "#/components/responses/InternalError" } } - } - }, - "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}": { - "patch": { - "description": "Deprecated. Update a sync source test connection.", - "operationId": "UpdateSyncTestConnectionForSyncSourceTeam", - "deprecated": true, - "x-internal": true, + }, + "delete": { + "description": "Delete a Sync Destination definition. Any syncs relying on this destination must be deleted first.", + "operationId": "DeleteV2SyncDestination", "tags": [ "syncs" ], "parameters": [ { - "$ref": "#/components/parameters/team_name" + "$ref": "#/components/parameters/sync_destination_name" + } + ], + "responses": { + "204": { + "description": "Deleted" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/rbac/permissions": { + "get": { + "description": "List all permissions", + "operationId": "ListAllRBACPermissions", + "parameters": [ + { + "$ref": "#/components/parameters/per_page" }, { - "$ref": "#/components/parameters/sync_source_test_connection_id" + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/rbac_permissions_sort_bys" + }, + { + "$ref": "#/components/parameters/rbac_permissions_sort_dirs" + }, + { + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter permissions by name or description." } ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/RBACPermission" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + }, + "post": { + "description": "Create a permission", + "operationId": "CreateRBACPermission", "requestBody": { + "required": true, "content": { "application/json": { "schema": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "#/components/schemas/SyncTestConnectionStatus" - }, - "failure_reason": { - "type": "string", - "description": "Reason for failure", - "example": "password authentication failed for user \"exampleuser\"" - }, - "failure_code": { - "example": "INVALID_CREDENTIALS", - "type": "string", - "description": "Code for failure" - } - } + "$ref": "#/components/schemas/RBACPermissionCreate" } } } }, "responses": { - "200": { - "description": "Updated", + "201": { + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnection" + "$ref": "#/components/schemas/RBACPermission" } } } @@ -10855,6 +11441,9 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -10867,60 +11456,28 @@ "500": { "$ref": "#/components/responses/InternalError" } - } + }, + "tags": [ + "rbac" + ] } }, - "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}": { - "patch": { - "description": "Deprecated. Update a sync destination test connection.", - "operationId": "UpdateSyncTestConnectionForSyncDestinationTeam", - "deprecated": true, - "x-internal": true, - "tags": [ - "syncs" - ], + "/rbac/permissions/{permission_id}": { + "get": { + "description": "Get a permission", + "operationId": "GetRBACPermission", "parameters": [ { - "$ref": "#/components/parameters/team_name" - }, - { - "$ref": "#/components/parameters/sync_destination_test_connection_id" + "$ref": "#/components/parameters/rbac_permission_id" } ], - "requestBody": { - "content": { - "application/json": { - "schema": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "$ref": "#/components/schemas/SyncTestConnectionStatus" - }, - "failure_reason": { - "type": "string", - "description": "Reason for failure", - "example": "password authentication failed for user \"exampleuser\"" - }, - "failure_code": { - "example": "INVALID_CREDENTIALS", - "type": "string", - "description": "Code for failure" - } - } - } - } - } - }, "responses": { "200": { - "description": "Updated", + "description": "Success", "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/SyncDestinationTestConnection" + "$ref": "#/components/schemas/RBACPermission" } } } @@ -10928,6 +11485,9 @@ "400": { "$ref": "#/components/responses/BadRequest" }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, "403": { "$ref": "#/components/responses/Forbidden" }, @@ -10940,33 +11500,741 @@ "500": { "$ref": "#/components/responses/InternalError" } - } - } - } - }, - "components": { - "securitySchemes": { - "bearerAuth": { - "scheme": "bearer", - "type": "http" - }, - "basicAuth": { - "scheme": "basic", - "type": "http" + }, + "tags": [ + "rbac" + ] }, - "cookieAuth": { - "scheme": "cookie", - "type": "http" - } - }, - "parameters": { - "per_page": { - "description": "The number of results per page (max 1000).", - "in": "query", - "name": "per_page", - "required": false, - "schema": { - "default": 100, + "patch": { + "description": "Update a permission", + "operationId": "UpdateRBACPermission", + "parameters": [ + { + "$ref": "#/components/parameters/rbac_permission_id" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACPermissionUpdate" + } + } + } + }, + "responses": { + "200": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACPermission" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + }, + "delete": { + "description": "Delete a permission", + "operationId": "DeleteRBACPermission", + "parameters": [ + { + "$ref": "#/components/parameters/rbac_permission_id" + } + ], + "responses": { + "204": { + "description": "Success" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + } + }, + "/rbac/roles": { + "get": { + "description": "List all roles", + "operationId": "ListAllRBACRoles", + "parameters": [ + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + }, + { + "$ref": "#/components/parameters/rbac_roles_sort_bys" + }, + { + "$ref": "#/components/parameters/rbac_roles_sort_dirs" + }, + { + "name": "search_term", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter roles by name or description." + }, + { + "name": "type", + "in": "query", + "schema": { + "type": "string" + }, + "description": "Filter roles by type." + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/Role" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + }, + "post": { + "description": "Create a role", + "operationId": "CreateRBACRole", + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACRoleCreate" + } + } + } + }, + "responses": { + "201": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Role" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + } + }, + "/rbac/roles/{role_id}": { + "get": { + "description": "Get a role", + "operationId": "GetRBACRole", + "parameters": [ + { + "$ref": "#/components/parameters/rbac_role_id" + } + ], + "responses": { + "200": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Role" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + }, + "patch": { + "description": "Update a role (custom roles only)", + "operationId": "UpdateRBACRole", + "parameters": [ + { + "$ref": "#/components/parameters/rbac_role_id" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/RBACRoleUpdate" + } + } + } + }, + "responses": { + "200": { + "description": "Success", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Role" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + }, + "delete": { + "description": "Delete a role", + "operationId": "DeleteRBACRole", + "parameters": [ + { + "$ref": "#/components/parameters/rbac_role_id" + } + ], + "responses": { + "204": { + "description": "Success" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "rbac" + ] + } + }, + "/teams": { + "get": { + "description": "List all teams", + "operationId": "ListTeams", + "parameters": [ + { + "$ref": "#/components/parameters/per_page" + }, + { + "$ref": "#/components/parameters/page" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "required": [ + "items", + "metadata" + ], + "properties": { + "items": { + "items": { + "$ref": "#/components/schemas/Team" + }, + "type": "array" + }, + "metadata": { + "$ref": "#/components/schemas/ListMetadata" + } + } + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "teams" + ] + } + }, + "/teams/{team_name}/plugins/{plugin_team}/{plugin_kind}/{plugin_name}/versions/{version_name}/assets/{target_name}": { + "get": { + "description": "Download an asset for a given plugin version as the current team.", + "operationId": "DownloadPluginAssetByTeam", + "parameters": [ + { + "in": "header", + "name": "Accept", + "required": false, + "schema": { + "type": "string" + } + }, + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/plugin_team" + }, + { + "$ref": "#/components/parameters/plugin_kind" + }, + { + "$ref": "#/components/parameters/plugin_name" + }, + { + "$ref": "#/components/parameters/version_name" + }, + { + "$ref": "#/components/parameters/target_name" + } + ], + "responses": { + "200": { + "description": "Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/PluginAsset" + } + } + } + }, + "302": { + "description": "Response", + "headers": { + "Location": { + "schema": { + "type": "string" + } + } + } + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + }, + "tags": [ + "plugins" + ] + } + }, + "/teams/{team_name}/syncs/{sync_name}/runs/{sync_run_id}/progress": { + "post": { + "description": "Deprecated. Create a new sync run progress update.", + "operationId": "CreateSyncRunProgressTeam", + "x-internal": true, + "deprecated": true, + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/sync_name" + }, + { + "$ref": "#/components/parameters/sync_run_id" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "rows", + "warnings", + "errors" + ], + "properties": { + "rows": { + "type": "integer", + "format": "int64", + "description": "Number of rows synced so far" + }, + "warnings": { + "type": "integer", + "format": "int64", + "description": "Number of warnings encountered so far" + }, + "errors": { + "type": "integer", + "format": "int64", + "description": "Number of errors encountered so far" + }, + "status": { + "$ref": "#/components/schemas/SyncRunStatus" + }, + "shard_num": { + "type": "integer", + "format": "int32", + "description": "The shard number that this progress update is for" + }, + "shard_total": { + "type": "integer", + "format": "int32", + "description": "The total number of shards for this sync run" + }, + "table_progress": { + "$ref": "#/components/schemas/SyncRunTableProgress", + "description": "Table-specific progress information including error and row counts per table" + } + } + } + } + } + }, + "responses": { + "204": { + "description": "Progress was reported successfully" + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/RequiresAuthentication" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/teams/{team_name}/sync-source-test-connections/{sync_source_test_connection_id}": { + "patch": { + "description": "Deprecated. Update a sync source test connection.", + "operationId": "UpdateSyncTestConnectionForSyncSourceTeam", + "deprecated": true, + "x-internal": true, + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/sync_source_test_connection_id" + } + ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" + }, + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Updated", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncSourceTestConnection" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + }, + "/teams/{team_name}/sync-destination-test-connections/{sync_destination_test_connection_id}": { + "patch": { + "description": "Deprecated. Update a sync destination test connection.", + "operationId": "UpdateSyncTestConnectionForSyncDestinationTeam", + "deprecated": true, + "x-internal": true, + "tags": [ + "syncs" + ], + "parameters": [ + { + "$ref": "#/components/parameters/team_name" + }, + { + "$ref": "#/components/parameters/sync_destination_test_connection_id" + } + ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "status" + ], + "properties": { + "status": { + "$ref": "#/components/schemas/SyncTestConnectionStatus" + }, + "failure_reason": { + "type": "string", + "description": "Reason for failure", + "example": "password authentication failed for user \"exampleuser\"" + }, + "failure_code": { + "example": "INVALID_CREDENTIALS", + "type": "string", + "description": "Code for failure" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Updated", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SyncDestinationTestConnection" + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "422": { + "$ref": "#/components/responses/UnprocessableEntity" + }, + "500": { + "$ref": "#/components/responses/InternalError" + } + } + } + } + }, + "components": { + "securitySchemes": { + "bearerAuth": { + "scheme": "bearer", + "type": "http" + }, + "basicAuth": { + "scheme": "basic", + "type": "http" + }, + "cookieAuth": { + "scheme": "cookie", + "type": "http" + } + }, + "parameters": { + "per_page": { + "description": "The number of results per page (max 1000).", + "in": "query", + "name": "per_page", + "required": false, + "schema": { + "default": 100, "maximum": 1000, "minimum": 1, "type": "integer", @@ -11349,13 +12617,26 @@ "in": "query", "description": "Alert enabled", "schema": { - "type": "boolean" + "type": "boolean" + } + }, + "query_column_filter": { + "name": "column_filter", + "in": "query", + "description": "Filter queries that return all specified columns", + "required": false, + "explode": true, + "schema": { + "type": "array", + "items": { + "type": "string" + } } }, "table_selects": { "name": "select", "in": "query", - "description": "Table selects. This filters the columns that are returned in the result set.", + "description": "Table selects. This filters the columns that are returned in the result set. If empty, all default columns + internal _cq_* columns are returned. To select all columns, use the `*` wildcard.", "allowEmptyValue": true, "explode": true, "schema": { @@ -11464,6 +12745,43 @@ }, "x-go-name": "QueryID" }, + "insight_column_name": { + "in": "path", + "name": "column_name", + "required": true, + "description": "Column for distinct values. Can be a standard column (severity, insight-category, source-category, source, resource-type, account, tag) or an arbitrary owner tag key when is_owner=true.", + "schema": { + "type": "string" + }, + "x-go-name": "InsightColumnName" + }, + "platform_insight_filter_id": { + "in": "path", + "name": "insight_filter_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/PlatformInsightFilterID" + }, + "x-go-name": "InsightFilterID" + }, + "insight_id": { + "in": "path", + "name": "insight_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/InsightID" + }, + "x-go-name": "InsightID" + }, + "asset_id": { + "in": "path", + "name": "asset_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/TableRowID" + }, + "x-go-name": "AssetID" + }, "report_sort_bys": { "name": "sort_by", "in": "query", @@ -11533,27 +12851,272 @@ }, "x-go-name": "SyncDestinationTestConnectionID" }, - "download_file": { - "description": "Whether to generate a downloadable file for the response.", + "download_file": { + "description": "Whether to generate a downloadable file for the response.", + "in": "query", + "name": "download", + "required": false, + "schema": { + "type": "boolean" + } + }, + "sync_name_filter": { + "name": "filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by name or display name", + "type": "string", + "pattern": "^[a-zA-Z\\p{L}\\p{N}_ \\-']*$", + "x-pattern-message": "can contain only letters, numbers, spaces, hyphens, underscores, and apostrophes" + } + }, + "sync_generic_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncGenericSortBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncGenericSortBys" + }, + "sync_sort_dirs": { + "name": "sort_dir", + "in": "query", + "description": "Sync sort direction options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncSortDirection" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncSortDirections" + }, + "sync_destination_name": { + "name": "sync_destination_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync destination", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncDestinationName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + } + }, + "sync_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncSortBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncSortBys" + }, + "migration_filter": { + "name": "migration_filter", + "in": "query", + "required": false, + "schema": { + "description": "Filter by migration", + "type": "boolean" + } + }, + "sync_test_connection_id": { + "name": "sync_test_connection_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncTestConnectionID" + } + }, + "sync_source_test_connection_id": { + "name": "sync_source_test_connection_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncSourceTestConnectionID" + }, + "x-go-name": "SyncSourceTestConnectionID" + }, + "sync_name": { + "name": "sync_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + } + }, + "sync_source_name": { + "name": "sync_source_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync source", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncSourceName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + } + }, + "sync_transformer_name": { + "name": "sync_transformer_name", + "in": "path", + "required": true, + "schema": { + "description": "Unique name of the sync transformer", + "type": "string", + "pattern": "^[a-zA-Z0-9_-]+$", + "x-go-name": "SyncTransformerName", + "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + } + }, + "sync_upgrades_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sort by options", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "kind", + "path", + "prev_version", + "new_version", + "created_at" + ] + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncUpgradesSortBys" + }, + "sync_upgrades_path_filter": { + "name": "path", + "in": "query", + "required": false, + "schema": { + "$ref": "#/components/schemas/SyncPluginPath", + "example": "cloudquery/aws", + "description": "Filter by plugin path" + } + }, + "sync_upgrades_kind_filter": { + "name": "kind", + "in": "query", + "required": false, + "schema": { + "$ref": "#/components/schemas/PluginKind", + "description": "Filter by plugin kind" + } + }, + "sync_upgrades_platform_version_filter": { + "name": "platform_version", + "in": "query", + "required": false, + "schema": { + "type": "string", + "example": "v1.1.0", + "description": "Filter by platform version" + } + }, + "sync_run_id": { + "name": "sync_run_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/SyncRunID" + } + }, + "sync_run_table_sort_bys": { + "name": "sort_by", + "in": "query", + "description": "Sync run table sort by options. This sorts the rows that are returned in the result set.", + "allowEmptyValue": true, + "explode": true, + "schema": { + "type": "array", + "items": { + "$ref": "#/components/schemas/SyncRunTableSortBy" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "SyncRunTableSortBys" + }, + "table_name": { + "in": "path", + "name": "table_name", + "required": true, + "schema": { + "$ref": "#/components/schemas/TableName" + } + }, + "table_row_id": { + "in": "path", + "name": "table_row_id", + "required": true, + "schema": { + "$ref": "#/components/schemas/TableRowID" + } + }, + "table_column_name_filter": { + "name": "filter", "in": "query", - "name": "download", "required": false, "schema": { - "type": "boolean" + "description": "Filter by column name", + "type": "string" } }, - "sync_name_filter": { + "column_name": { + "in": "path", + "name": "column_name", + "required": true, + "schema": { + "description": "The name of a table column.", + "type": "string" + } + }, + "table_column_value_filter": { "name": "filter", "in": "query", "required": false, "schema": { - "description": "Filter by name or display name", - "type": "string", - "pattern": "^[a-zA-Z\\p{L}\\p{N}_ \\-']*$", - "x-pattern-message": "can contain only letters, numbers, spaces, hyphens, underscores, and apostrophes" + "description": "Filter by column value.", + "type": "string" } }, - "sync_generic_sort_bys": { + "user_id": { + "name": "user_id", + "in": "path", + "required": true, + "schema": { + "$ref": "#/components/schemas/UserID" + }, + "x-go-name": "UserID" + }, + "rbac_permissions_sort_bys": { "name": "sort_by", "in": "query", "description": "Sort by options", @@ -11562,40 +13125,37 @@ "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncGenericSortBy" + "$ref": "#/components/schemas/RBACPermissionSortBy" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncGenericSortBys" + "x-go-name": "RBACPermissionSortBys" }, - "sync_sort_dirs": { + "rbac_permissions_sort_dirs": { "name": "sort_dir", "in": "query", - "description": "Sync sort direction options", + "description": "Sort direction options", "allowEmptyValue": true, "explode": true, "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncSortDirection" + "$ref": "#/components/schemas/RBACPermissionSortDirection" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncSortDirections" + "x-go-name": "RBACPermissionSortDirections" }, - "sync_destination_name": { - "name": "sync_destination_name", + "rbac_permission_id": { "in": "path", + "name": "permission_id", "required": true, "schema": { - "description": "Unique name of the sync destination", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncDestinationName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - } + "$ref": "#/components/schemas/RBACPermissionID" + }, + "x-go-name": "RBACPermissionID" }, - "sync_sort_bys": { + "rbac_roles_sort_bys": { "name": "sort_by", "in": "query", "description": "Sort by options", @@ -11604,366 +13164,507 @@ "schema": { "type": "array", "items": { - "$ref": "#/components/schemas/SyncSortBy" + "$ref": "#/components/schemas/RBACRoleSortBy" } }, "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncSortBys" + "x-go-name": "RBACRoleSortBys" }, - "migration_filter": { - "name": "migration_filter", + "rbac_roles_sort_dirs": { + "name": "sort_dir", "in": "query", - "required": false, - "schema": { - "description": "Filter by migration", - "type": "boolean" - } - }, - "sync_test_connection_id": { - "name": "sync_test_connection_id", - "in": "path", - "required": true, + "description": "Sort direction options", + "allowEmptyValue": true, + "explode": true, "schema": { - "$ref": "#/components/schemas/SyncTestConnectionID" - } + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACRoleSortDirection" + } + }, + "x-go-type-skip-optional-pointer": true, + "x-go-name": "RBACRoleSortDirections" }, - "sync_source_test_connection_id": { - "name": "sync_source_test_connection_id", + "rbac_role_id": { "in": "path", + "name": "role_id", "required": true, "schema": { - "$ref": "#/components/schemas/SyncSourceTestConnectionID" + "$ref": "#/components/schemas/RoleID" }, - "x-go-name": "SyncSourceTestConnectionID" + "x-go-name": "RoleID" }, - "sync_name": { - "name": "sync_name", + "plugin_team": { "in": "path", + "name": "plugin_team", "required": true, "schema": { - "description": "Unique name of the sync", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" + "$ref": "#/components/schemas/TeamName" } + } + }, + "schemas": { + "UserName": { + "description": "The unique name for the user.", + "minLength": 1, + "maxLength": 255, + "pattern": "^[a-zA-Z\\p{L}][a-zA-Z\\p{L} \\-']*$", + "x-pattern-message": "can contain only letters, spaces, hyphens, and apostrophes, starting with a letter", + "type": "string", + "example": "Sarah O'Connor" }, - "sync_source_name": { - "name": "sync_source_name", - "in": "path", - "required": true, - "schema": { - "description": "Unique name of the sync source", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncSourceName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - } + "UserProvider": { + "title": "LocalUserProvider", + "type": "string", + "enum": [ + "local", + "saml" + ], + "default": "local" }, - "sync_transformer_name": { - "name": "sync_transformer_name", - "in": "path", - "required": true, - "schema": { - "description": "Unique name of the sync transformer", - "type": "string", - "pattern": "^[a-zA-Z0-9_-]+$", - "x-go-name": "SyncTransformerName", - "x-pattern-message": "can contain only alphanumerical characters, dashes, and underscores" - } + "RBACPermissionID": { + "description": "The unique ID for the data permission.", + "type": "string", + "format": "uuid", + "x-go-name": "RBACPermissionID" }, - "sync_upgrades_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "kind", - "path", - "prev_version", - "new_version", - "created_at" - ] - } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncUpgradesSortBys" + "UserID": { + "description": "ID of the User", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "UserID" }, - "sync_upgrades_path_filter": { - "name": "path", - "in": "query", - "required": false, - "schema": { - "$ref": "#/components/schemas/SyncPluginPath", - "example": "cloudquery/aws", - "description": "Filter by plugin path" + "CreatedBy": { + "type": "object", + "required": [ + "id", + "name", + "email" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/UserID" + }, + "name": { + "$ref": "#/components/schemas/UserName" + }, + "email": { + "type": "string" + } } }, - "sync_upgrades_kind_filter": { - "name": "kind", - "in": "query", - "required": false, - "schema": { - "$ref": "#/components/schemas/PluginKind", - "description": "Filter by plugin kind" + "RBACPermission": { + "type": "object", + "required": [ + "id", + "name", + "description", + "query", + "created_by", + "created_at", + "updated_at", + "number_of_affected_roles", + "number_of_affected_users" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/RBACPermissionID" + }, + "name": { + "type": "string" + }, + "description": { + "type": "string" + }, + "query": { + "type": "string" + }, + "created_by": { + "$ref": "#/components/schemas/CreatedBy" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "number_of_affected_roles": { + "type": "integer" + }, + "number_of_affected_users": { + "type": "integer" + } } }, - "sync_upgrades_platform_version_filter": { - "name": "platform_version", - "in": "query", - "required": false, - "schema": { - "type": "string", - "example": "v1.1.0", - "description": "Filter by platform version" - } + "RoleType": { + "type": "string", + "enum": [ + "admin:write", + "admin:read", + "general:read", + "general:write", + "ci", + "schema-only", + "custom" + ], + "x-enum-varnames": [ + "AdminWrite", + "AdminRead", + "GeneralRead", + "GeneralWrite", + "CI", + "SchemaOnly", + "Custom" + ] }, - "sync_run_id": { - "name": "sync_run_id", - "in": "path", - "required": true, - "schema": { - "$ref": "#/components/schemas/SyncRunID" + "Role": { + "type": "object", + "description": "Role", + "required": [ + "id", + "name", + "description", + "permissions", + "created_by", + "created_at", + "updated_at", + "type" + ], + "properties": { + "id": { + "description": "The unique ID for the role.", + "type": "string", + "format": "uuid", + "x-go-name": "ID" + }, + "name": { + "type": "string" + }, + "description": { + "type": "string" + }, + "permissions": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RBACPermission" + } + }, + "created_by": { + "$ref": "#/components/schemas/CreatedBy" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "type": { + "$ref": "#/components/schemas/RoleType" + } } }, - "sync_run_table_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sync run table sort by options. This sorts the rows that are returned in the result set.", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SyncRunTableSortBy" + "User": { + "additionalProperties": false, + "description": "User", + "properties": { + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "id": { + "description": "ID of the User", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "ID" + }, + "email": { + "type": "string", + "example": "user@example.com" + }, + "name": { + "$ref": "#/components/schemas/UserName" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "type": "string", + "format": "date-time" + }, + "profile_image_url": { + "type": "string", + "description": "Profile image URL of user", + "x-go-name": "ProfileImageURL" + }, + "last_login_at": { + "type": "string", + "format": "date-time" + }, + "provider": { + "$ref": "#/components/schemas/UserProvider" + }, + "tracking_opted_in": { + "type": "boolean", + "description": "Whether anonymous user tracking was opted into" + }, + "mfa_configured": { + "type": "boolean", + "description": "Whether the user has MFA configured", + "x-go-name": "MFAConfigured" + }, + "roles": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Role" + } + }, + "enabled": { + "type": "boolean", + "description": "Whether the user is enabled" } }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "SyncRunTableSortBys" - }, - "table_name": { - "in": "path", - "name": "table_name", - "required": true, - "schema": { - "$ref": "#/components/schemas/TableName" - } - }, - "table_row_id": { - "in": "path", - "name": "table_row_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/TableRowID" - } - }, - "table_column_name_filter": { - "name": "filter", - "in": "query", - "required": false, - "schema": { - "description": "Filter by column name", - "type": "string" - } - }, - "column_name": { - "in": "path", - "name": "column_name", - "required": true, - "schema": { - "description": "The name of a table column.", - "type": "string" - } + "required": [ + "id", + "email", + "enabled", + "provider", + "mfa_configured", + "roles" + ], + "title": "User", + "type": "object" }, - "table_column_value_filter": { - "name": "filter", - "in": "query", - "required": false, - "schema": { - "description": "Filter by column value.", - "type": "string" + "AuditLogEvent": { + "type": "object", + "required": [ + "id", + "user", + "event_type", + "created_at", + "user_ip_address" + ], + "properties": { + "id": { + "type": "string", + "format": "uuid", + "description": "The unique identifier of the audit log event" + }, + "user": { + "$ref": "#/components/schemas/User", + "description": "The user who performed the action" + }, + "user_ip_address": { + "type": "string", + "description": "The IP address of the user who performed the action" + }, + "event_type": { + "type": "string", + "description": "The type of event that was logged" + }, + "entity_display_name": { + "type": "string", + "description": "The display name of the entity that was affected", + "nullable": true + }, + "event_details": { + "type": "object", + "description": "Additional details about the event", + "additionalProperties": true + }, + "is_success": { + "type": "boolean", + "description": "Whether the event was successful" + }, + "created_at": { + "type": "string", + "format": "date-time", + "description": "The timestamp when the event was created" + } } }, - "user_id": { - "name": "user_id", - "in": "path", - "required": true, - "schema": { - "$ref": "#/components/schemas/UserID" - }, - "x-go-name": "UserID" - }, - "rbac_permissions_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACPermissionSortBy" + "ListMetadata": { + "required": [ + "page_size" + ], + "properties": { + "total_count": { + "type": "integer" + }, + "last_page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "time_ms": { + "type": "integer" } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACPermissionSortBys" + } }, - "rbac_permissions_sort_dirs": { - "name": "sort_dir", - "in": "query", - "description": "Sort direction options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACPermissionSortDirection" + "BasicError": { + "additionalProperties": false, + "description": "Basic Error", + "required": [ + "message", + "status" + ], + "properties": { + "message": { + "type": "string" + }, + "status": { + "type": "integer" } }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACPermissionSortDirections" - }, - "rbac_permission_id": { - "in": "path", - "name": "permission_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/RBACPermissionID" - }, - "x-go-name": "RBACPermissionID" + "title": "Basic Error", + "type": "object" }, - "rbac_roles_sort_bys": { - "name": "sort_by", - "in": "query", - "description": "Sort by options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACRoleSortBy" + "FieldError": { + "allOf": [ + { + "$ref": "#/components/schemas/BasicError" + }, + { + "properties": { + "errors": { + "items": { + "type": "string" + }, + "type": "array" + }, + "field_errors": { + "additionalProperties": { + "type": "string" + }, + "type": "object" + } + }, + "type": "object" } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACRoleSortBys" + ] }, - "rbac_roles_sort_dirs": { - "name": "sort_dir", - "in": "query", - "description": "Sort direction options", - "allowEmptyValue": true, - "explode": true, - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACRoleSortDirection" + "PlatformVersion": { + "type": "object", + "required": [ + "name", + "created_at" + ], + "properties": { + "name": { + "type": "string", + "description": "Name of the version" + }, + "created_at": { + "type": "string", + "format": "date-time", + "description": "Time when the version was first installed" } - }, - "x-go-type-skip-optional-pointer": true, - "x-go-name": "RBACRoleSortDirections" + } }, - "rbac_role_id": { - "in": "path", - "name": "role_id", - "required": true, - "schema": { - "$ref": "#/components/schemas/RoleID" - }, - "x-go-name": "RoleID" + "PluginReleaseStage": { + "description": "Official plugins can go through three release stages: Coming Soon, Preview, and GA.\nThe Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready.\nBoth Preview and GA plugins follow semantic versioning. The main differences between the two stages are:\nPreview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage.", + "type": "string", + "enum": [ + "coming-soon", + "preview", + "ga", + "deprecated" + ] }, - "plugin_team": { - "in": "path", - "name": "plugin_team", - "required": true, - "schema": { - "$ref": "#/components/schemas/TeamName" - } - } - }, - "schemas": { - "UserName": { - "description": "The unique name for the user.", - "minLength": 1, + "TeamName": { + "description": "The unique name for the team.", "maxLength": 255, - "pattern": "^[a-zA-Z\\p{L}][a-zA-Z\\p{L} \\-']*$", - "x-pattern-message": "can contain only letters, spaces, hyphens, and apostrophes, starting with a letter", + "pattern": "^[a-z](-?[a-z0-9]+)+$", "type": "string", - "example": "Sarah O'Connor" + "example": "cloudquery", + "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" }, - "UserProvider": { - "title": "LocalUserProvider", + "PluginName": { + "description": "The unique name for the plugin.", + "maxLength": 255, + "pattern": "^[a-z](-?[a-z0-9]+)+$", "type": "string", + "example": "aws-source", + "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" + }, + "PluginKind": { + "description": "The kind of plugin, ie. source or destination.", + "type": "string", + "example": "source", "enum": [ - "local", - "saml" - ], - "default": "local" + "source", + "destination", + "transformer" + ] }, - "RBACPermissionID": { - "description": "The unique ID for the data permission.", + "PluginCategory": { + "description": "Supported categories for plugins", "type": "string", - "format": "uuid", - "x-go-name": "RBACPermissionID" + "enum": [ + "cloud-infrastructure", + "databases", + "sales-marketing", + "engineering-analytics", + "marketing-analytics", + "shipment-tracking", + "product-analytics", + "cloud-finops", + "project-management", + "fleet-management", + "security", + "data-warehouses", + "human-resources", + "finance", + "customer-support", + "other" + ] }, - "UserID": { - "description": "ID of the User", + "PluginPriceCategory": { + "description": "Supported price categories for billing", "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "UserID" + "enum": [ + "api", + "database", + "free" + ] }, - "CreatedBy": { - "type": "object", - "required": [ - "id", - "name", - "email" - ], - "properties": { - "id": { - "$ref": "#/components/schemas/UserID" - }, - "name": { - "$ref": "#/components/schemas/UserName" - }, - "email": { - "type": "string" - } - } + "PluginTier": { + "description": "This field is deprecated, refer to `price_category` instead.\nThis field is only kept for backward compatibility and may be removed in a future release.\nSupported tiers for plugins.\n - free: Free tier, with no paid tables.\n - paid: Paid tier. These plugins may have paid tables, but can also have free tables. They require login to access.\n - open-core: This option is deprecated, values will either be free or paid.\n", + "type": "string", + "deprecated": true, + "enum": [ + "free", + "paid", + "open-core" + ] }, - "RBACPermission": { - "type": "object", - "required": [ - "id", - "name", - "description", - "query", - "created_by", - "created_at", - "updated_at", - "number_of_affected_roles", - "number_of_affected_users" - ], + "Plugin": { + "additionalProperties": false, + "description": "CloudQuery Plugin", "properties": { - "id": { - "$ref": "#/components/schemas/RBACPermissionID" + "team_name": { + "$ref": "#/components/schemas/TeamName" }, "name": { - "type": "string" + "$ref": "#/components/schemas/PluginName" }, - "description": { - "type": "string" + "kind": { + "$ref": "#/components/schemas/PluginKind" }, - "query": { - "type": "string" + "category": { + "$ref": "#/components/schemas/PluginCategory" }, - "created_by": { - "$ref": "#/components/schemas/CreatedBy" + "price_category": { + "$ref": "#/components/schemas/PluginPriceCategory" }, "created_at": { "example": "2017-07-14T16:53:42Z", @@ -11975,378 +13676,544 @@ "format": "date-time", "type": "string" }, - "number_of_affected_roles": { - "type": "integer" + "homepage": { + "type": "string", + "example": "https://cloudquery.io" }, - "number_of_affected_users": { - "type": "integer" - } - } - }, - "RoleType": { - "type": "string", - "enum": [ - "admin:write", - "admin:read", - "general:read", - "general:write", - "ci", - "schema-only", - "custom" - ], - "x-enum-varnames": [ - "AdminWrite", - "AdminRead", - "GeneralRead", - "GeneralWrite", - "CI", - "SchemaOnly", - "Custom" - ] - }, - "Role": { - "type": "object", - "description": "Role", - "required": [ - "id", - "name", - "description", - "permissions", - "created_by", - "created_at", - "updated_at", - "type" - ], - "properties": { - "id": { - "description": "The unique ID for the role.", + "logo": { "type": "string", - "format": "uuid", - "x-go-name": "ID" + "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e" }, - "name": { - "type": "string" + "display_name": { + "description": "The plugin's display name", + "type": "string", + "minLength": 1, + "maxLength": 50, + "example": "AWS Source Plugin" }, - "description": { - "type": "string" + "official": { + "description": "True if the plugin is maintained by CloudQuery, false otherwise", + "type": "boolean" }, - "permissions": { - "type": "array", - "items": { - "$ref": "#/components/schemas/RBACPermission" - } + "release_stage": { + "$ref": "#/components/schemas/PluginReleaseStage" }, - "created_by": { - "$ref": "#/components/schemas/CreatedBy" + "repository": { + "type": "string", + "example": "https://github.com/cloudquery/cloudquery" }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "short_description": { + "type": "string", + "minLength": 1, + "maxLength": 512, + "example": "Sync data from AWS to any destination" }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "tier": { + "$ref": "#/components/schemas/PluginTier" }, - "type": { - "$ref": "#/components/schemas/RoleType" + "public": { + "description": "Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the plugin's team.", + "type": "boolean" + }, + "usd_per_row": { + "deprecated": true, + "type": "string", + "pattern": "^\\d+(?:\\.\\d{1,10})?$", + "description": "Deprecated. Refer to `price_category` instead.", + "example": "0.0001", + "x-go-name": "USDPerRow", + "x-pattern-message": "must be a valid decimal number with up to 10 decimal places." + }, + "free_rows_per_month": { + "deprecated": true, + "type": "integer", + "format": "int64", + "description": "Deprecated. Refer to `price_category` instead.", + "example": 1000 + } + }, + "required": [ + "team_name", + "name", + "kind", + "category", + "release_stage", + "created_at", + "updated_at", + "logo", + "display_name", + "official", + "short_description", + "tier", + "usd_per_row", + "free_rows_per_month" + ], + "title": "CloudQuery Plugin", + "type": "object" + }, + "VersionName": { + "type": "string", + "description": "The version in semantic version format.", + "pattern": "^v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", + "x-pattern-message": "should be in semantic version format" + }, + "ListPlugin": { + "allOf": [ + { + "$ref": "#/components/schemas/Plugin" + }, + { + "type": "object", + "properties": { + "latest_version": { + "$ref": "#/components/schemas/VersionName" + } + } + } + ] + }, + "ListPlugins": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ListPlugin" + }, + "example": [ + { + "name": "aws", + "kind": "source", + "team_name": "cloudquery", + "display_name": "AWS Source Plugin", + "category": "cloud-infrastructure", + "created_at": "2017-07-14T16:53:42Z", + "updated_at": "2017-07-14T16:53:42Z", + "homepage": "https://cloudquery.io", + "logo": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", + "official": true, + "short_description": "Sync data from AWS to any destination", + "repository": "https://github.com/cloudquery/cloudquery", + "tier": "paid", + "usd_per_row": "0.00123", + "free_rows_per_month": 10000, + "release_stage": "preview" } + ] + }, + "VersionFilter": { + "type": "string", + "description": "A version filter in semantic version format with prefix ranges.", + "pattern": "^[^~]?v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", + "x-pattern-message": "should be in semantic version format with prefix ranges" + }, + "PluginProtocols": { + "description": "The CloudQuery protocols supported by this plugin version (only protocol 3 is supported by new plugins).", + "type": "array", + "items": { + "type": "integer", + "enum": [ + 3 + ] } }, - "User": { + "PluginPackageType": { + "description": "The package type of the plugin assets", + "type": "string", + "enum": [ + "native", + "docker" + ] + }, + "PluginVersionBase": { "additionalProperties": false, - "description": "User", + "description": "CloudQuery Plugin Version", + "required": [ + "created_at", + "name", + "message", + "draft", + "retracted", + "protocols", + "supported_targets", + "checksums", + "package_type" + ], "properties": { "created_at": { "example": "2017-07-14T16:53:42Z", "format": "date-time", - "type": "string" - }, - "id": { - "description": "ID of the User", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "ID" - }, - "email": { "type": "string", - "example": "user@example.com" - }, - "name": { - "$ref": "#/components/schemas/UserName" + "description": "The date and time the plugin version was created." }, - "updated_at": { + "published_at": { "example": "2017-07-14T16:53:42Z", + "format": "date-time", "type": "string", - "format": "date-time" + "description": "The date and time the plugin version was set to non-draft (published)." }, - "profile_image_url": { - "type": "string", - "description": "Profile image URL of user", - "x-go-name": "ProfileImageURL" + "name": { + "$ref": "#/components/schemas/VersionName" }, - "last_login_at": { + "message": { "type": "string", - "format": "date-time" - }, - "provider": { - "$ref": "#/components/schemas/UserProvider" + "description": "Description of what's new or changed in this version (supports markdown)", + "example": "- Added support for AWS S3 - Added support for AWS EC2" }, - "tracking_opted_in": { + "draft": { "type": "boolean", - "description": "Whether anonymous user tracking was opted into" + "description": "If a plugin version is in draft, it will not show to members outside the team or be counted as the latest version." }, - "mfa_configured": { + "retracted": { "type": "boolean", - "description": "Whether the user has MFA configured", - "x-go-name": "MFAConfigured" + "description": "If a plugin version is retracted, assets will still be available for download, but the version will be marked as retracted to discourage use." }, - "roles": { + "protocols": { + "$ref": "#/components/schemas/PluginProtocols" + }, + "supported_targets": { "type": "array", + "description": "The targets supported by this plugin version, formatted as _", + "example": [ + "linux_arm64", + "darwin_amd64", + "windows_amd64" + ], "items": { - "$ref": "#/components/schemas/Role" + "type": "string" } }, - "enabled": { - "type": "boolean", - "description": "Whether the user is enabled" + "checksums": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The checksums of the plugin assets" + }, + "package_type": { + "$ref": "#/components/schemas/PluginPackageType" } }, + "title": "CloudQuery Plugin Version", + "type": "object" + }, + "PluginVersionList": { + "allOf": [ + { + "$ref": "#/components/schemas/PluginVersionBase" + } + ] + }, + "PluginSpecJSONSchema": { + "description": "The specification of the plugin. This is a JSON schema that describes the configuration of the plugin.", + "type": "string" + }, + "PluginVersion": { + "allOf": [ + { + "$ref": "#/components/schemas/PluginVersionBase" + }, + { + "type": "object", + "properties": { + "spec_json_schema": { + "$ref": "#/components/schemas/PluginSpecJSONSchema" + } + } + } + ] + }, + "PluginVersionDetails": { + "allOf": [ + { + "$ref": "#/components/schemas/PluginVersion" + }, + { + "type": "object", + "required": [ + "example_config" + ], + "properties": { + "example_config": { + "type": "string", + "description": "Example configuration for the plugin. This can be used in generated quickstart guides, for example. Markdown format." + }, + "ui_base_url": { + "type": "string", + "description": "Base URL for the plugin's UI. Only available for plugins with a UI and for logged in users.", + "x-go-name": "UIBaseURL" + }, + "ui_base_url_v2": { + "type": "string", + "description": "Base URL for the plugin's UI. Only available for plugins with a UI and for logged in users.", + "x-go-name": "UIBaseURLv2" + } + } + } + ] + }, + "PluginAsset": { + "additionalProperties": false, + "description": "CloudQuery Plugin Asset", "required": [ - "id", - "email", - "enabled", - "provider", - "mfa_configured", - "roles" + "checksum", + "location" ], - "title": "User", + "properties": { + "checksum": { + "type": "string", + "description": "The checksum of the plugin asset" + }, + "location": { + "type": "string", + "format": "uri", + "description": "The location to download the plugin asset from" + } + }, + "title": "CloudQuery Plugin Asset", "type": "object" }, - "AuditLogEvent": { - "type": "object", + "PluginTableName": { + "description": "Name of the table", + "maxLength": 255, + "pattern": "^[a-z](_?[a-z0-9]+)+$", + "type": "string", + "example": "aws_ec2_instances", + "x-pattern-message": "can contain only lowercase alphanumerical characters and underscores, starting with a letter" + }, + "PluginTable": { + "additionalProperties": false, + "description": "CloudQuery Plugin Table", "required": [ - "id", - "user", - "event_type", - "created_at", - "user_ip_address" + "description", + "is_incremental", + "name", + "relations", + "title" ], "properties": { - "id": { + "description": { + "description": "Description of the table", "type": "string", - "format": "uuid", - "description": "The unique identifier of the audit log event" - }, - "user": { - "$ref": "#/components/schemas/User", - "description": "The user who performed the action" + "example": "AWS S3 Buckets" }, - "user_ip_address": { - "type": "string", - "description": "The IP address of the user who performed the action" + "is_incremental": { + "description": "Whether the table is incremental", + "type": "boolean" }, - "event_type": { - "type": "string", - "description": "The type of event that was logged" + "name": { + "$ref": "#/components/schemas/PluginTableName" }, - "entity_display_name": { + "parent": { + "description": "Name of the parent table, if any", "type": "string", - "description": "The display name of the entity that was affected", - "nullable": true - }, - "event_details": { - "type": "object", - "description": "Additional details about the event", - "additionalProperties": true + "example": "nil" }, - "is_success": { - "type": "boolean", - "description": "Whether the event was successful" + "relations": { + "description": "Names of the tables that depend on this table", + "items": { + "type": "string" + }, + "type": "array", + "example": [ + "aws_s3_bucket_cors_rules" + ] }, - "created_at": { + "title": { + "description": "Title of the table", "type": "string", - "format": "date-time", - "description": "The timestamp when the event was created" + "example": "AWS S3 Buckets" + }, + "is_paid": { + "description": "Whether the table is paid", + "type": "boolean" } - } + }, + "title": "CloudQuery Plugin Table", + "type": "object" }, - "ListMetadata": { + "PluginTableColumn": { + "additionalProperties": false, + "description": "CloudQuery Plugin Column", "required": [ - "page_size" + "description", + "incremental_key", + "name", + "not_null", + "primary_key", + "type", + "unique" ], "properties": { - "total_count": { - "type": "integer" + "description": { + "description": "Description of the column", + "type": "string" + }, + "incremental_key": { + "description": "Whether the column is used as an incremental key", + "type": "boolean" + }, + "name": { + "description": "Name of the column", + "type": "string" }, - "last_page": { - "type": "integer" + "not_null": { + "description": "Whether the column is nullable", + "type": "boolean" }, - "page_size": { - "type": "integer" + "primary_key": { + "description": "Whether the column is part of the primary key", + "type": "boolean" }, - "time_ms": { - "type": "integer" - } - } - }, - "BasicError": { - "additionalProperties": false, - "description": "Basic Error", - "required": [ - "message", - "status" - ], - "properties": { - "message": { + "type": { + "description": "Arrow Type of the column", "type": "string" }, - "status": { - "type": "integer" + "type_schema": { + "description": "For columns of type JSON, the schema of the JSON object", + "type": "string" + }, + "unique": { + "description": "Whether the column has a unique constraint", + "type": "boolean" } }, - "title": "Basic Error", + "title": "CloudQuery Plugin Table Column", "type": "object" }, - "FieldError": { - "allOf": [ - { - "$ref": "#/components/schemas/BasicError" - }, - { - "properties": { - "errors": { - "items": { - "type": "string" - }, - "type": "array" - }, - "field_errors": { - "additionalProperties": { - "type": "string" - }, - "type": "object" - } - }, - "type": "object" - } - ] - }, - "PlatformVersion": { - "type": "object", + "PluginTableDetails": { + "additionalProperties": false, "required": [ + "columns", + "description", + "is_incremental", "name", - "created_at" + "relations", + "title", + "permissions_needed" ], "properties": { + "columns": { + "description": "List of columns", + "items": { + "$ref": "#/components/schemas/PluginTableColumn" + }, + "type": "array" + }, + "description": { + "description": "Description of the table", + "type": "string" + }, + "is_incremental": { + "description": "Whether the table is incremental", + "type": "boolean" + }, "name": { - "type": "string", - "description": "Name of the version" + "description": "Name of the table", + "type": "string" }, - "created_at": { - "type": "string", - "format": "date-time", - "description": "Time when the version was first installed" + "parent": { + "description": "Name of the parent table, if any", + "type": "string" + }, + "relations": { + "description": "Names of the tables that depend on this table", + "items": { + "type": "string" + }, + "type": "array" + }, + "title": { + "description": "Title of the table", + "type": "string" + }, + "is_paid": { + "description": "Whether the table is paid", + "type": "boolean" + }, + "permissions_needed": { + "description": "List of permissions needed to access this table, if any", + "items": { + "type": "string" + }, + "type": "array", + "example": [ + "storage.buckets.list" + ] } - } - }, - "PluginReleaseStage": { - "description": "Official plugins can go through three release stages: Coming Soon, Preview, and GA.\nThe Coming Soon stage is for plugins that are not yet ready for Preview, but users can subscribe to be notified when they are ready.\nBoth Preview and GA plugins follow semantic versioning. The main differences between the two stages are:\nPreview plugins are still experimental and may have frequent breaking changes. Preview plugins might get deprecated due to lack of usage. Long Term Support with community Discord and bug fixes is only guaranteed for GA plugins. Premium plugins are often discounted or free during the Preview stage.", - "type": "string", - "enum": [ - "coming-soon", - "preview", - "ga", - "deprecated" - ] - }, - "TeamName": { - "description": "The unique name for the team.", - "maxLength": 255, - "pattern": "^[a-z](-?[a-z0-9]+)+$", - "type": "string", - "example": "cloudquery", - "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" - }, - "PluginName": { - "description": "The unique name for the plugin.", - "maxLength": 255, - "pattern": "^[a-z](-?[a-z0-9]+)+$", - "type": "string", - "example": "aws-source", - "x-pattern-message": "can contain only lowercase alphanumerical characters and dashes, starting with a letter" + }, + "type": "object" }, - "PluginKind": { - "description": "The kind of plugin, ie. source or destination.", + "AlertState": { "type": "string", - "example": "source", "enum": [ - "source", - "destination", - "transformer" + "unknown", + "pending", + "inactive", + "triggered" ] }, - "PluginCategory": { - "description": "Supported categories for plugins", - "type": "string", - "enum": [ - "cloud-infrastructure", - "databases", - "sales-marketing", - "engineering-analytics", - "marketing-analytics", - "shipment-tracking", - "product-analytics", - "cloud-finops", - "project-management", - "fleet-management", - "security", - "data-warehouses", - "human-resources", - "finance", - "customer-support", - "other" - ] + "QueryTag": { + "description": "A saved query tag.", + "type": "string" }, - "PluginPriceCategory": { - "description": "Supported price categories for billing", + "AlertSeverity": { "type": "string", "enum": [ - "api", - "database", - "free" + "low", + "medium", + "high", + "critical" ] }, - "PluginTier": { - "description": "This field is deprecated, refer to `price_category` instead.\nThis field is only kept for backward compatibility and may be removed in a future release.\nSupported tiers for plugins.\n - free: Free tier, with no paid tables.\n - paid: Paid tier. These plugins may have paid tables, but can also have free tables. They require login to access.\n - open-core: This option is deprecated, values will either be free or paid.\n", + "NotificationDestinationID": { + "description": "The unique ID for the notification destination.", "type": "string", - "deprecated": true, - "enum": [ - "free", - "paid", - "open-core" - ] + "format": "uuid", + "x-go-name": "NotificationDestinationID" }, - "Plugin": { + "NotificationDestinationListItem": { + "title": "Notification Destination List Item", + "type": "object", + "description": "Notification Destination List Item", "additionalProperties": false, - "description": "CloudQuery Plugin", + "required": [ + "id", + "name", + "enabled", + "type", + "url", + "created_at", + "updated_at" + ], "properties": { - "team_name": { - "$ref": "#/components/schemas/TeamName" + "id": { + "$ref": "#/components/schemas/NotificationDestinationID" }, "name": { - "$ref": "#/components/schemas/PluginName" + "type": "string", + "example": "Send to Slack" }, - "kind": { - "$ref": "#/components/schemas/PluginKind" + "enabled": { + "type": "boolean" }, - "category": { - "$ref": "#/components/schemas/PluginCategory" + "type": { + "type": "string", + "enum": [ + "webhook", + "slack" + ], + "description": "Type of notification destination" }, - "price_category": { - "$ref": "#/components/schemas/PluginPriceCategory" + "url": { + "type": "string", + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXX", + "x-go-name": "URL" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel names (only for slack type)", + "x-go-name": "SlackChannels" }, "created_at": { "example": "2017-07-14T16:53:42Z", @@ -12357,2196 +14224,2085 @@ "example": "2017-07-14T16:53:42Z", "format": "date-time", "type": "string" - }, - "homepage": { + } + } + }, + "AlertDetail": { + "title": "Alert Detail", + "type": "object", + "description": "An alert instance that can be triggered by a query including notification destinations for the alert", + "additionalProperties": false, + "required": [ + "id", + "query_id", + "enabled", + "message", + "severity", + "state", + "total_violations", + "created_at", + "updated_at", + "notification_destinations" + ], + "properties": { + "id": { "type": "string", - "example": "https://cloudquery.io" + "format": "uuid", + "description": "Unique identifier for the alert", + "x-go-name": "ID" }, - "logo": { + "query_id": { "type": "string", - "example": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e" + "format": "uuid", + "description": "Reference to the associated query", + "x-go-name": "QueryID" }, - "display_name": { - "description": "The plugin's display name", + "enabled": { + "type": "boolean", + "description": "Indicates if the alert is enabled" + }, + "message": { "type": "string", - "minLength": 1, - "maxLength": 50, - "example": "AWS Source Plugin" + "description": "Alert message content" }, - "official": { - "description": "True if the plugin is maintained by CloudQuery, false otherwise", - "type": "boolean" + "severity": { + "$ref": "#/components/schemas/AlertSeverity" }, - "release_stage": { - "$ref": "#/components/schemas/PluginReleaseStage" + "state": { + "$ref": "#/components/schemas/AlertState" }, - "repository": { - "type": "string", - "example": "https://github.com/cloudquery/cloudquery" + "total_violations": { + "type": "integer", + "format": "int64", + "description": "Number of violations that triggered the alert" }, - "short_description": { + "last_evaluated_at": { "type": "string", - "minLength": 1, - "maxLength": 512, - "example": "Sync data from AWS to any destination" - }, - "tier": { - "$ref": "#/components/schemas/PluginTier" + "format": "date-time", + "description": "Timestamp when the alert was last evaluated" }, - "public": { - "description": "Whether the plugin is listed in the CloudQuery Hub. If false, the plugin will not be shown in the CloudQuery Hub and will only be visible to members of the plugin's team.", - "type": "boolean" + "triggered_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was triggered" }, - "usd_per_row": { - "deprecated": true, + "created_at": { "type": "string", - "pattern": "^\\d+(?:\\.\\d{1,10})?$", - "description": "Deprecated. Refer to `price_category` instead.", - "example": "0.0001", - "x-go-name": "USDPerRow", - "x-pattern-message": "must be a valid decimal number with up to 10 decimal places." + "format": "date-time", + "description": "Timestamp when the alert was created" }, - "free_rows_per_month": { - "deprecated": true, - "type": "integer", - "format": "int64", - "description": "Deprecated. Refer to `price_category` instead.", - "example": 1000 - } - }, - "required": [ - "team_name", - "name", - "kind", - "category", - "release_stage", - "created_at", - "updated_at", - "logo", - "display_name", - "official", - "short_description", - "tier", - "usd_per_row", - "free_rows_per_month" - ], - "title": "CloudQuery Plugin", - "type": "object" - }, - "VersionName": { - "type": "string", - "description": "The version in semantic version format.", - "pattern": "^v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", - "x-pattern-message": "should be in semantic version format" - }, - "ListPlugin": { - "allOf": [ - { - "$ref": "#/components/schemas/Plugin" + "updated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last updated" }, - { - "type": "object", - "properties": { - "latest_version": { - "$ref": "#/components/schemas/VersionName" - } - } - } - ] - }, - "ListPlugins": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ListPlugin" - }, - "example": [ - { - "name": "aws", - "kind": "source", - "team_name": "cloudquery", - "display_name": "AWS Source Plugin", - "category": "cloud-infrastructure", - "created_at": "2017-07-14T16:53:42Z", - "updated_at": "2017-07-14T16:53:42Z", - "homepage": "https://cloudquery.io", - "logo": "https://storage.googleapis.com/cq-cloud-images/9ac4cb31-e971-4879-8619-87dc22b0f98e", - "official": true, - "short_description": "Sync data from AWS to any destination", - "repository": "https://github.com/cloudquery/cloudquery", - "tier": "paid", - "usd_per_row": "0.00123", - "free_rows_per_month": 10000, - "release_stage": "preview" + "notification_destinations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/NotificationDestinationListItem" + }, + "description": "List of notification destinations this alert is configured to send to", + "x-go-type-skip-optional-pointer": true, + "allowEmptyValue": true, + "explode": true } - ] - }, - "VersionFilter": { - "type": "string", - "description": "A version filter in semantic version format with prefix ranges.", - "pattern": "^[^~]?v[0-9]+\\.[0-9]+\\.[0-9]+(-[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?(\\+[0-9A-Za-z-]+(\\.[0-9A-Za-z-]+)*)?$", - "x-pattern-message": "should be in semantic version format with prefix ranges" - }, - "PluginProtocols": { - "description": "The CloudQuery protocols supported by this plugin version (only protocol 3 is supported by new plugins).", - "type": "array", - "items": { - "type": "integer", - "enum": [ - 3 - ] } }, - "PluginPackageType": { - "description": "The package type of the plugin assets", + "QueryID": { + "description": "The unique ID for the query.", "type": "string", - "enum": [ - "native", - "docker" - ] + "format": "uuid", + "x-go-name": "QueryID" }, - "PluginVersionBase": { + "AlertCreate": { + "title": "Alert Create", + "type": "object", + "description": "Create an alert", "additionalProperties": false, - "description": "CloudQuery Plugin Version", "required": [ - "created_at", - "name", "message", - "draft", - "retracted", - "protocols", - "supported_targets", - "checksums", - "package_type" + "severity", + "enabled" ], "properties": { - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string", - "description": "The date and time the plugin version was created." - }, - "published_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string", - "description": "The date and time the plugin version was set to non-draft (published)." - }, - "name": { - "$ref": "#/components/schemas/VersionName" - }, "message": { "type": "string", - "description": "Description of what's new or changed in this version (supports markdown)", - "example": "- Added support for AWS S3 - Added support for AWS EC2" + "example": "All resources need to be tagged" }, - "draft": { - "type": "boolean", - "description": "If a plugin version is in draft, it will not show to members outside the team or be counted as the latest version." + "severity": { + "$ref": "#/components/schemas/AlertSeverity" }, - "retracted": { + "enabled": { "type": "boolean", - "description": "If a plugin version is retracted, assets will still be available for download, but the version will be marked as retracted to discourage use." - }, - "protocols": { - "$ref": "#/components/schemas/PluginProtocols" - }, - "supported_targets": { - "type": "array", - "description": "The targets supported by this plugin version, formatted as _", - "example": [ - "linux_arm64", - "darwin_amd64", - "windows_amd64" - ], - "items": { - "type": "string" - } + "description": "Indicates if the alert is enabled" }, - "checksums": { + "notification_destinations": { "type": "array", "items": { - "type": "string" + "$ref": "#/components/schemas/NotificationDestinationID" }, - "description": "The checksums of the plugin assets" - }, - "package_type": { - "$ref": "#/components/schemas/PluginPackageType" - } - }, - "title": "CloudQuery Plugin Version", - "type": "object" - }, - "PluginVersionList": { - "allOf": [ - { - "$ref": "#/components/schemas/PluginVersionBase" + "description": "List of notification destinations to send alerts to", + "x-go-type-skip-optional-pointer": true, + "allowEmptyValue": true, + "explode": true } - ] - }, - "PluginSpecJSONSchema": { - "description": "The specification of the plugin. This is a JSON schema that describes the configuration of the plugin.", - "type": "string" + } }, - "PluginVersion": { - "allOf": [ - { - "$ref": "#/components/schemas/PluginVersionBase" + "NotificationDestinationTestResponse": { + "title": "Notification Destination Test Response", + "type": "object", + "description": "Notification Destination Test Response", + "additionalProperties": false, + "required": [ + "is_success", + "http_status", + "http_status_code", + "http_body", + "http_headers" + ], + "properties": { + "is_success": { + "type": "boolean", + "description": "Indicates if the test was successful" }, - { - "type": "object", - "properties": { - "spec_json_schema": { - "$ref": "#/components/schemas/PluginSpecJSONSchema" - } - } - } - ] - }, - "PluginVersionDetails": { - "allOf": [ - { - "$ref": "#/components/schemas/PluginVersion" + "http_status_code": { + "type": "integer", + "description": "HTTP status code returned by the notification destination", + "x-go-name": "HTTPStatusCode" }, - { + "http_status": { + "type": "string", + "description": "HTTP status message returned by the notification destination", + "x-go-name": "HTTPStatus" + }, + "http_body": { + "type": "string", + "description": "Body of the HTTP response from the notification destination", + "x-go-name": "HTTPBody" + }, + "http_headers": { "type": "object", - "required": [ - "example_config" - ], - "properties": { - "example_config": { - "type": "string", - "description": "Example configuration for the plugin. This can be used in generated quickstart guides, for example. Markdown format." - }, - "ui_base_url": { - "type": "string", - "description": "Base URL for the plugin's UI. Only available for plugins with a UI and for logged in users.", - "x-go-name": "UIBaseURL" - }, - "ui_base_url_v2": { - "type": "string", - "description": "Base URL for the plugin's UI. Only available for plugins with a UI and for logged in users.", - "x-go-name": "UIBaseURLv2" - } - } + "additionalProperties": { + "type": "string" + }, + "description": "Headers returned by the notification destination", + "x-go-name": "HTTPHeaders" } - ] + } }, - "PluginAsset": { + "AlertTestResponse": { + "title": "Alert Test Response", + "type": "object", + "description": "Alert Test Response", "additionalProperties": false, - "description": "CloudQuery Plugin Asset", "required": [ - "checksum", - "location" + "destination_id", + "response" ], "properties": { - "checksum": { + "destination_id": { "type": "string", - "description": "The checksum of the plugin asset" + "description": "The ID of the notification destination.", + "x-go-name": "DestinationID" }, - "location": { + "error": { "type": "string", - "format": "uri", - "description": "The location to download the plugin asset from" + "description": "An error message if the test failed, otherwise null." + }, + "response": { + "$ref": "#/components/schemas/NotificationDestinationTestResponse" } - }, - "title": "CloudQuery Plugin Asset", - "type": "object" + } }, - "PluginTableName": { - "description": "Name of the table", - "maxLength": 255, - "pattern": "^[a-z](_?[a-z0-9]+)+$", + "PolicyStatus": { + "description": "Policy status", "type": "string", - "example": "aws_ec2_instances", - "x-pattern-message": "can contain only lowercase alphanumerical characters and underscores, starting with a letter" + "enum": [ + "paused", + "active" + ], + "x-go-name": "PolicyStatus" }, - "PluginTable": { + "PolicySeverity": { + "description": "Policy severity", + "type": "string", + "enum": [ + "low", + "medium", + "high", + "critical" + ], + "x-go-name": "PolicySeverity" + }, + "PolicyDomain": { + "description": "Policy domain", + "type": "string", + "enum": [ + "finops", + "security", + "compliance", + "governance", + "operations" + ], + "x-go-name": "PolicyDomain" + }, + "PolicyGroupID": { + "title": "Policy Group ID", + "type": "string", + "format": "uuid", + "x-go-name": "PolicyGroupID" + }, + "PolicyID": { + "description": "The unique ID for the policy.", + "type": "string", + "format": "uuid", + "x-go-name": "PolicyID" + }, + "PolicyGroup": { + "title": "Policy Group", + "type": "object", + "description": "Policy Group", "additionalProperties": false, - "description": "CloudQuery Plugin Table", "required": [ - "description", - "is_incremental", + "id", "name", - "relations", - "title" + "description", + "created_at", + "updated_at" ], "properties": { + "id": { + "type": "string", + "format": "uuid" + }, + "name": { + "type": "string", + "example": "Security Policies" + }, "description": { - "description": "Description of the table", "type": "string", - "example": "AWS S3 Buckets" + "example": "Group containing all security-related policies" }, - "is_incremental": { - "description": "Whether the table is incremental", - "type": "boolean" + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + } + } + }, + "Policy": { + "title": "Policy", + "type": "object", + "description": "Policy", + "additionalProperties": false, + "required": [ + "id", + "name", + "domain", + "severity", + "description", + "status", + "team_name", + "query_id", + "query", + "created_by", + "created_at", + "updated_at" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/PolicyID" }, "name": { - "$ref": "#/components/schemas/PluginTableName" + "type": "string", + "example": "Unencrypted S3 buckets" + }, + "domain": { + "$ref": "#/components/schemas/PolicyDomain" + }, + "severity": { + "$ref": "#/components/schemas/PolicySeverity" + }, + "description": { + "type": "string", + "example": "Policy to detect unencrypted S3 buckets" + }, + "status": { + "$ref": "#/components/schemas/PolicyStatus" }, - "parent": { - "description": "Name of the parent table, if any", + "team_name": { "type": "string", - "example": "nil" + "example": "my-team" }, - "relations": { - "description": "Names of the tables that depend on this table", - "items": { - "type": "string" - }, - "type": "array", - "example": [ - "aws_s3_bucket_cors_rules" - ] + "query_id": { + "$ref": "#/components/schemas/QueryID" }, - "title": { - "description": "Title of the table", + "query": { "type": "string", - "example": "AWS S3 Buckets" + "description": "The SQL query string for the policy", + "example": "SELECT * FROM aws_s3_buckets WHERE server_side_encryption_configuration IS NULL" }, - "is_paid": { - "description": "Whether the table is paid", - "type": "boolean" - } - }, - "title": "CloudQuery Plugin Table", - "type": "object" - }, - "PluginTableColumn": { - "additionalProperties": false, - "description": "CloudQuery Plugin Column", - "required": [ - "description", - "incremental_key", - "name", - "not_null", - "primary_key", - "type", - "unique" - ], - "properties": { - "description": { - "description": "Description of the column", - "type": "string" + "created_by": { + "type": "string", + "format": "uuid", + "x-go-name": "CreatedByUserID" }, - "incremental_key": { - "description": "Whether the column is used as an incremental key", - "type": "boolean" + "updated_by": { + "type": "string", + "format": "uuid", + "nullable": true, + "x-go-name": "UpdatedByUserID" }, - "name": { - "description": "Name of the column", + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", "type": "string" }, - "not_null": { - "description": "Whether the column is nullable", - "type": "boolean" + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" }, - "primary_key": { - "description": "Whether the column is part of the primary key", - "type": "boolean" + "violation_count": { + "type": "integer", + "nullable": true, + "description": "Number of violations from the last evaluation", + "example": 5 }, - "type": { - "description": "Arrow Type of the column", - "type": "string" + "run_at": { + "type": "string", + "format": "date-time", + "nullable": true, + "description": "Timestamp of the last evaluation run", + "example": "2017-07-14T16:53:42Z" }, - "type_schema": { - "description": "For columns of type JSON, the schema of the JSON object", - "type": "string" + "notification_destinations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/NotificationDestinationListItem" + }, + "description": "List of notification destinations configured for the policy's alert", + "example": [] }, - "unique": { - "description": "Whether the column has a unique constraint", - "type": "boolean" + "policy_groups": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PolicyGroup" + }, + "description": "List of policy groups this policy belongs to", + "example": [] } - }, - "title": "CloudQuery Plugin Table Column", - "type": "object" + } }, - "PluginTableDetails": { + "PolicyCreate": { + "title": "Policy Create", + "type": "object", + "description": "Create a policy (implicitly creates a query and an enabled alert)", "additionalProperties": false, "required": [ - "columns", - "description", - "is_incremental", "name", - "relations", - "title", - "permissions_needed" + "domain", + "severity", + "query" ], "properties": { - "columns": { - "description": "List of columns", - "items": { - "$ref": "#/components/schemas/PluginTableColumn" - }, - "type": "array" + "name": { + "type": "string", + "example": "Unencrypted S3 buckets" }, - "description": { - "description": "Description of the table", - "type": "string" + "domain": { + "$ref": "#/components/schemas/PolicyDomain" }, - "is_incremental": { - "description": "Whether the table is incremental", - "type": "boolean" + "severity": { + "$ref": "#/components/schemas/PolicySeverity" }, - "name": { - "description": "Name of the table", - "type": "string" + "description": { + "type": "string", + "default": "", + "example": "Policy to detect unencrypted S3 buckets" }, - "parent": { - "description": "Name of the parent table, if any", - "type": "string" + "query": { + "type": "string", + "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" }, - "relations": { - "description": "Names of the tables that depend on this table", + "notification_destination_ids": { + "type": "array", "items": { - "type": "string" + "type": "string", + "format": "uuid" }, - "type": "array" - }, - "title": { - "description": "Title of the table", - "type": "string" - }, - "is_paid": { - "description": "Whether the table is paid", - "type": "boolean" + "nullable": true, + "description": "Notification destination IDs to send alerts to" }, - "permissions_needed": { - "description": "List of permissions needed to access this table, if any", + "policy_group_ids": { + "type": "array", "items": { - "type": "string" + "type": "string", + "format": "uuid" }, - "type": "array", - "example": [ - "storage.buckets.list" - ] + "nullable": true, + "description": "Policy group IDs to add this policy to" } - }, - "type": "object" - }, - "AlertState": { - "type": "string", - "enum": [ - "unknown", - "pending", - "inactive", - "triggered" - ] - }, - "QueryTag": { - "description": "A saved query tag.", - "type": "string" - }, - "AlertSeverity": { - "type": "string", - "enum": [ - "low", - "medium", - "high", - "critical" - ] - }, - "NotificationDestinationID": { - "description": "The unique ID for the notification destination.", - "type": "string", - "format": "uuid", - "x-go-name": "NotificationDestinationID" + } }, - "NotificationDestinationListItem": { - "title": "Notification Destination List Item", + "PolicyUpdate": { + "title": "Policy Update", "type": "object", - "description": "Notification Destination List Item", + "description": "Update a policy", "additionalProperties": false, - "required": [ - "id", - "name", - "enabled", - "type", - "url", - "created_at", - "updated_at" - ], "properties": { - "id": { - "$ref": "#/components/schemas/NotificationDestinationID" - }, "name": { - "type": "string", - "example": "Send to Slack" + "type": "string" }, - "enabled": { - "type": "boolean" + "domain": { + "$ref": "#/components/schemas/PolicyDomain" }, - "type": { - "type": "string", - "enum": [ - "webhook", - "slack" - ], - "description": "Type of notification destination" + "severity": { + "$ref": "#/components/schemas/PolicySeverity" + }, + "description": { + "type": "string" }, - "url": { + "query": { "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXX", - "x-go-name": "URL" + "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "notification_destination_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" + }, + "nullable": true, + "description": "Notification destination IDs to send alerts to" }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "policy_group_ids": { + "type": "array", + "items": { + "type": "string", + "format": "uuid" + }, + "nullable": true, + "description": "Policy group IDs to set for this policy" } } }, - "AlertDetail": { - "title": "Alert Detail", + "PolicyViolation": { + "title": "Policy Violation", "type": "object", - "description": "An alert instance that can be triggered by a query including notification destinations for the alert", + "description": "Policy violation resource information", "additionalProperties": false, "required": [ - "id", - "query_id", - "enabled", - "message", - "severity", - "state", - "total_violations", - "created_at", - "updated_at", - "notification_destinations" + "cloud", + "resource_type_label", + "_cq_account_name", + "name", + "region", + "_cq_platform_id" ], "properties": { - "id": { - "type": "string", - "format": "uuid", - "description": "Unique identifier for the alert", - "x-go-name": "ID" - }, - "query_id": { + "cloud": { "type": "string", - "format": "uuid", - "description": "Reference to the associated query", - "x-go-name": "QueryID" - }, - "enabled": { - "type": "boolean", - "description": "Indicates if the alert is enabled" + "example": "aws" }, - "message": { + "resource_type_label": { "type": "string", - "description": "Alert message content" - }, - "severity": { - "$ref": "#/components/schemas/AlertSeverity" - }, - "state": { - "$ref": "#/components/schemas/AlertState" - }, - "total_violations": { - "type": "integer", - "format": "int64", - "description": "Number of violations that triggered the alert" + "example": "EC2 Instance" }, - "last_evaluated_at": { + "_cq_account_name": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was last evaluated" + "example": "my-account" }, - "triggered_at": { + "name": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was triggered" + "example": "my-resource" }, - "created_at": { + "region": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was created" + "example": "us-east-1" }, - "updated_at": { + "_cq_platform_id": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was last updated" + "example": "aws_ec2_instances_12345678-1234-1234-1234-123456789abc" }, - "notification_destinations": { + "tags": { "type": "array", "items": { - "$ref": "#/components/schemas/NotificationDestinationListItem" + "type": "string" }, - "description": "List of notification destinations this alert is configured to send to", - "x-go-type-skip-optional-pointer": true, - "allowEmptyValue": true, - "explode": true + "description": "Tags associated with the resource (e.g. for insights)" } } }, - "QueryID": { - "description": "The unique ID for the query.", - "type": "string", - "format": "uuid", - "x-go-name": "QueryID" - }, - "AlertCreate": { - "title": "Alert Create", + "PolicyEvaluationLog": { + "title": "Policy Evaluation Log", "type": "object", - "description": "Create an alert", + "description": "Policy evaluation log entry", "additionalProperties": false, "required": [ - "message", - "severity", - "enabled" + "id", + "policy_id", + "violation_count", + "run_at" ], "properties": { - "message": { + "id": { "type": "string", - "example": "All resources need to be tagged" + "format": "uuid" }, - "severity": { - "$ref": "#/components/schemas/AlertSeverity" + "policy_id": { + "$ref": "#/components/schemas/PolicyID" }, - "enabled": { - "type": "boolean", - "description": "Indicates if the alert is enabled" + "violation_count": { + "type": "integer", + "example": 5 }, - "notification_destinations": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationDestinationID" - }, - "description": "List of notification destinations to send alerts to", - "x-go-type-skip-optional-pointer": true, - "allowEmptyValue": true, - "explode": true + "run_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" } } }, - "NotificationDestinationTestResponse": { - "title": "Notification Destination Test Response", + "PolicyMetrics": { + "title": "Policy Metrics", "type": "object", - "description": "Notification Destination Test Response", + "description": "Policy metrics summary", "additionalProperties": false, "required": [ - "is_success", - "http_status", - "http_status_code", - "http_body", - "http_headers" + "total_active_violations", + "high_severity_violations", + "violations_this_week" ], "properties": { - "is_success": { - "type": "boolean", - "description": "Indicates if the test was successful" + "total_active_violations": { + "type": "integer", + "description": "Total violations from active policies", + "example": 28 }, - "http_status_code": { + "high_severity_violations": { "type": "integer", - "description": "HTTP status code returned by the notification destination", - "x-go-name": "HTTPStatusCode" + "description": "Total violations from high or critical severity policies", + "example": 10 }, - "http_status": { - "type": "string", - "description": "HTTP status message returned by the notification destination", - "x-go-name": "HTTPStatus" + "violations_this_week": { + "type": "integer", + "description": "Total violations from evaluations in the last 7 days", + "example": 7 + } + } + }, + "ViolationsByDomainItem": { + "title": "Violations By Domain Item", + "type": "object", + "description": "Violation count for a specific domain", + "additionalProperties": false, + "required": [ + "domain", + "violation_count" + ], + "properties": { + "domain": { + "$ref": "#/components/schemas/PolicyDomain" }, - "http_body": { - "type": "string", - "description": "Body of the HTTP response from the notification destination", - "x-go-name": "HTTPBody" + "violation_count": { + "type": "integer", + "description": "Number of violations for this domain", + "example": 15 + } + } + }, + "ViolationsByDomain": { + "title": "Violations By Domain", + "type": "object", + "description": "Violations grouped by domain", + "additionalProperties": false, + "required": [ + "items", + "total_violations" + ], + "properties": { + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ViolationsByDomainItem" + } }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "Headers returned by the notification destination", - "x-go-name": "HTTPHeaders" + "total_violations": { + "type": "integer", + "description": "Total violations across all domains", + "example": 28 + } + } + }, + "ViolationsHistoryItem": { + "title": "Violations History Item", + "type": "object", + "description": "Violation count for a specific date", + "additionalProperties": false, + "required": [ + "date", + "violation_count" + ], + "properties": { + "date": { + "type": "string", + "format": "date", + "description": "Date of the violations", + "example": "2026-01-06" + }, + "violation_count": { + "type": "integer", + "description": "Number of violations on this date", + "example": 3 } } }, - "AlertTestResponse": { - "title": "Alert Test Response", + "ViolationsHistoryMetadata": { + "title": "Violations History Metadata", "type": "object", - "description": "Alert Test Response", + "description": "Metadata for violations history query", "additionalProperties": false, "required": [ - "destination_id", - "response" + "interval", + "start_date", + "end_date" ], "properties": { - "destination_id": { + "interval": { "type": "string", - "description": "The ID of the notification destination.", - "x-go-name": "DestinationID" + "description": "Interval in days used for grouping", + "example": "30" }, - "error": { + "start_date": { "type": "string", - "description": "An error message if the test failed, otherwise null." + "format": "date", + "description": "Start date of the query range", + "example": "2025-05-01" }, - "response": { - "$ref": "#/components/schemas/NotificationDestinationTestResponse" + "end_date": { + "type": "string", + "format": "date", + "description": "End date of the query range", + "example": "2026-12-01" } } }, - "PolicyStatus": { - "description": "Policy status", - "type": "string", - "enum": [ - "paused", - "active" - ], - "x-go-name": "PolicyStatus" - }, - "PolicySeverity": { - "description": "Policy severity", - "type": "string", - "enum": [ - "low", - "medium", - "high", - "critical" - ], - "x-go-name": "PolicySeverity" - }, - "PolicyDomain": { - "description": "Policy domain", - "type": "string", - "enum": [ - "finops", - "security", - "compliance", - "governance", - "operations" - ], - "x-go-name": "PolicyDomain" - }, - "PolicyGroupID": { - "title": "Policy Group ID", - "type": "string", - "format": "uuid", - "x-go-name": "PolicyGroupID" - }, - "PolicyID": { - "description": "The unique ID for the policy.", - "type": "string", - "format": "uuid", - "x-go-name": "PolicyID" - }, - "PolicyGroup": { - "title": "Policy Group", + "ViolationsHistory": { + "title": "Violations History", "type": "object", - "description": "Policy Group", + "description": "Violations history over time", "additionalProperties": false, "required": [ - "id", - "name", - "description", - "created_at", - "updated_at" + "items", + "metadata" ], "properties": { - "id": { - "type": "string", - "format": "uuid" - }, - "name": { - "type": "string", - "example": "Security Policies" - }, - "description": { - "type": "string", - "example": "Group containing all security-related policies" - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "items": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ViolationsHistoryItem" + } }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "metadata": { + "$ref": "#/components/schemas/ViolationsHistoryMetadata" } } }, - "Policy": { - "title": "Policy", + "PolicyGroupWithCounts": { + "title": "Policy Group With Counts", "type": "object", - "description": "Policy", + "description": "Policy Group with policy count and violation counts by severity", "additionalProperties": false, "required": [ "id", "name", - "domain", - "severity", "description", - "status", - "team_name", - "query_id", - "query", - "created_by", + "policy_count", + "violation_count_low", + "violation_count_medium", + "violation_count_high", + "violation_count_critical", "created_at", "updated_at" ], - "properties": { - "id": { - "$ref": "#/components/schemas/PolicyID" - }, - "name": { - "type": "string", - "example": "Unencrypted S3 buckets" - }, - "domain": { - "$ref": "#/components/schemas/PolicyDomain" - }, - "severity": { - "$ref": "#/components/schemas/PolicySeverity" - }, - "description": { - "type": "string", - "example": "Policy to detect unencrypted S3 buckets" - }, - "status": { - "$ref": "#/components/schemas/PolicyStatus" - }, - "team_name": { - "type": "string", - "example": "my-team" - }, - "query_id": { - "$ref": "#/components/schemas/QueryID" - }, - "query": { - "type": "string", - "description": "The SQL query string for the policy", - "example": "SELECT * FROM aws_s3_buckets WHERE server_side_encryption_configuration IS NULL" - }, - "created_by": { - "type": "string", - "format": "uuid", - "x-go-name": "CreatedByUserID" - }, - "updated_by": { - "type": "string", - "format": "uuid", - "nullable": true, - "x-go-name": "UpdatedByUserID" - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "violation_count": { - "type": "integer", - "nullable": true, - "description": "Number of violations from the last evaluation", - "example": 5 - }, - "run_at": { - "type": "string", - "format": "date-time", - "nullable": true, - "description": "Timestamp of the last evaluation run", - "example": "2017-07-14T16:53:42Z" - }, - "notification_destinations": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationDestinationListItem" - }, - "description": "List of notification destinations configured for the policy's alert", - "example": [] + "allOf": [ + { + "$ref": "#/components/schemas/PolicyGroup" }, - "policy_groups": { - "type": "array", - "items": { - "$ref": "#/components/schemas/PolicyGroup" - }, - "description": "List of policy groups this policy belongs to", - "example": [] + { + "type": "object", + "properties": { + "policy_count": { + "type": "integer", + "description": "Number of policies in this group", + "example": 5, + "default": 0 + }, + "violation_count_low": { + "type": "integer", + "description": "Total violations from low severity policies in this group", + "example": 10, + "default": 0 + }, + "violation_count_medium": { + "type": "integer", + "description": "Total violations from medium severity policies in this group", + "example": 25, + "default": 0 + }, + "violation_count_high": { + "type": "integer", + "description": "Total violations from high severity policies in this group", + "example": 15, + "default": 0 + }, + "violation_count_critical": { + "type": "integer", + "description": "Total violations from critical severity policies in this group", + "example": 3, + "default": 0 + } + } } - } + ] }, - "PolicyCreate": { - "title": "Policy Create", + "PolicyGroupCreate": { + "title": "Policy Group Create", "type": "object", - "description": "Create a policy (implicitly creates a query and an enabled alert)", + "description": "Create a policy group", "additionalProperties": false, "required": [ - "name", - "domain", - "severity", - "query" + "name" ], "properties": { "name": { "type": "string", - "example": "Unencrypted S3 buckets" - }, - "domain": { - "$ref": "#/components/schemas/PolicyDomain" - }, - "severity": { - "$ref": "#/components/schemas/PolicySeverity" + "example": "Security Policies" }, "description": { "type": "string", "default": "", - "example": "Policy to detect unencrypted S3 buckets" - }, - "query": { - "type": "string", - "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" - }, - "notification_destination_ids": { - "type": "array", - "items": { - "type": "string", - "format": "uuid" - }, - "nullable": true, - "description": "Notification destination IDs to send alerts to" + "example": "Group containing all security-related policies" }, - "policy_group_ids": { + "policy_ids": { "type": "array", "items": { "type": "string", "format": "uuid" }, "nullable": true, - "description": "Policy group IDs to add this policy to" + "description": "Optional array of policy IDs to add to this group" } } }, - "PolicyUpdate": { - "title": "Policy Update", + "PolicyGroupUpdate": { + "title": "Policy Group Update", "type": "object", - "description": "Update a policy", + "description": "Update a policy group", "additionalProperties": false, "properties": { "name": { "type": "string" }, - "domain": { - "$ref": "#/components/schemas/PolicyDomain" - }, - "severity": { - "$ref": "#/components/schemas/PolicySeverity" - }, "description": { "type": "string" }, - "query": { - "type": "string", - "example": "SELECT account_id, bucket_name, region FROM aws_s3_buckets WHERE encryption_status IS NULL" - }, - "notification_destination_ids": { - "type": "array", - "items": { - "type": "string", - "format": "uuid" - }, - "nullable": true, - "description": "Notification destination IDs to send alerts to" - }, - "policy_group_ids": { + "policy_ids": { "type": "array", "items": { "type": "string", "format": "uuid" }, "nullable": true, - "description": "Policy group IDs to set for this policy" + "description": "Policy IDs to set for this group" } } }, - "PolicyViolation": { - "title": "Policy Violation", + "APIKeyName": { + "description": "Name of the API key", + "type": "string", + "example": "cli-api-key", + "maxLength": 255, + "minLength": 1, + "pattern": "^(?:[a-zA-Z0-9][a-zA-Z0-9- ]*)?[a-zA-Z0-9]$", + "x-pattern-message": "can contain only letters, numbers, spaces, and hyphens, starting and ending with a letter or number" + }, + "APIKeyID": { + "description": "ID of the API key", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "APIKeyID" + }, + "APIKey": { + "description": "API Key to interact with CloudQuery Platform", "type": "object", - "description": "Policy violation resource information", - "additionalProperties": false, "required": [ - "cloud", - "resource_type_label", - "_cq_account_name", + "id", "name", - "region", - "_cq_platform_id" + "expires_at", + "expired", + "roles" ], "properties": { - "cloud": { - "type": "string", - "example": "aws" + "name": { + "$ref": "#/components/schemas/APIKeyName" }, - "resource_type_label": { + "created_by": { "type": "string", - "example": "EC2 Instance" + "example": "user@example.com", + "description": "email of the user that created the API key" }, - "_cq_account_name": { + "id": { + "$ref": "#/components/schemas/APIKeyID" + }, + "key": { "type": "string", - "example": "my-account" + "description": "API key. Will be shown only in the response when creating the key.", + "example": "1234567890abcdef1234567890abcdef" }, - "name": { + "created_at": { "type": "string", - "example": "my-resource" + "format": "date-time", + "example": "2017-07-14T16:53:42Z" }, - "region": { + "expires_at": { "type": "string", - "example": "us-east-1" + "description": "Timestamp at which API key will stop working", + "format": "date-time", + "example": "2017-07-14T16:53:42Z" }, - "_cq_platform_id": { + "last_access_at": { "type": "string", - "example": "aws_ec2_instances_12345678-1234-1234-1234-123456789abc" + "format": "date-time", + "example": "2017-07-14T16:53:42Z", + "description": "Timestamp at which API key was last used - accurate to the day only." + }, + "expired": { + "type": "boolean", + "description": "Whether the API key has expired or not", + "example": false + }, + "roles": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Role" + } } } }, - "PolicyEvaluationLog": { - "title": "Policy Evaluation Log", + "RoleID": { + "description": "The unique ID for the role.", + "type": "string", + "format": "uuid", + "x-go-name": "RoleID" + }, + "ConversationCreate": { "type": "object", - "description": "Policy evaluation log entry", - "additionalProperties": false, "required": [ - "id", - "policy_id", - "violation_count", - "run_at" + "message" ], "properties": { - "id": { + "message": { "type": "string", - "format": "uuid" - }, - "policy_id": { - "$ref": "#/components/schemas/PolicyID" + "description": "The initial message to start the conversation." }, - "violation_count": { - "type": "integer", - "example": 5 + "current_query": { + "type": "string", + "description": "An optional current query to provide context for the conversation." }, - "run_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "mode": { + "type": "string", + "description": "The mode of the conversation, which can influence the behavior of the AI.", + "default": "sql", + "enum": [ + "ask", + "sql" + ] } } }, - "PolicyMetrics": { - "title": "Policy Metrics", + "ConversationMessage": { "type": "object", - "description": "Policy metrics summary", - "additionalProperties": false, "required": [ - "total_active_violations", - "high_severity_violations", - "violations_this_week" + "id", + "role", + "content", + "created_at", + "message_type", + "end_turn", + "mode" ], "properties": { - "total_active_violations": { - "type": "integer", - "description": "Total violations from active policies", - "example": 28 + "id": { + "type": "string", + "format": "uuid", + "description": "Unique identifier of the message", + "x-go-name": "ID" }, - "high_severity_violations": { - "type": "integer", - "description": "Total violations from high or critical severity policies", - "example": 10 + "role": { + "type": "string", + "enum": [ + "user", + "assistant", + "system" + ], + "description": "Role of the message sender" }, - "violations_this_week": { - "type": "integer", - "description": "Total violations from evaluations in the last 7 days", - "example": 7 - } - } - }, - "ViolationsByDomainItem": { - "title": "Violations By Domain Item", - "type": "object", - "description": "Violation count for a specific domain", - "additionalProperties": false, - "required": [ - "domain", - "violation_count" - ], - "properties": { - "domain": { - "$ref": "#/components/schemas/PolicyDomain" + "content": { + "type": "string", + "description": "Content of the message. In the case of tool use or tool result, this will contain JSON data." + }, + "query_context": { + "type": "string", + "description": "The current query context when the message was sent, if applicable" + }, + "message_type": { + "type": "string", + "enum": [ + "error", + "message", + "tool_use", + "tool_result" + ], + "description": "Type of the message content" }, - "violation_count": { - "type": "integer", - "description": "Number of violations for this domain", - "example": 15 + "created_at": { + "type": "string", + "format": "date-time" + }, + "end_turn": { + "type": "boolean", + "description": "Whether this message ends the conversation turn", + "default": false + }, + "mode": { + "type": "string", + "description": "The mode of the conversation when this message was sent, which can influence the behavior of the AI.", + "default": "sql", + "enum": [ + "ask", + "sql" + ] } } }, - "ViolationsByDomain": { - "title": "Violations By Domain", + "Conversation": { "type": "object", - "description": "Violations grouped by domain", - "additionalProperties": false, "required": [ - "items", - "total_violations" + "id", + "messages", + "created_at", + "updated_at" ], "properties": { - "items": { + "id": { + "type": "string", + "format": "uuid", + "description": "Unique identifier of the conversation", + "x-go-name": "ID" + }, + "title": { + "type": "string", + "description": "Optional title of the conversation" + }, + "messages": { "type": "array", "items": { - "$ref": "#/components/schemas/ViolationsByDomainItem" + "$ref": "#/components/schemas/ConversationMessage" } }, - "total_violations": { - "type": "integer", - "description": "Total violations across all domains", - "example": 28 - } - } - }, - "ViolationsHistoryItem": { - "title": "Violations History Item", - "type": "object", - "description": "Violation count for a specific date", - "additionalProperties": false, - "required": [ - "date", - "violation_count" - ], - "properties": { - "date": { + "created_at": { "type": "string", - "format": "date", - "description": "Date of the violations", - "example": "2026-01-06" + "format": "date-time" }, - "violation_count": { - "type": "integer", - "description": "Number of violations on this date", - "example": 3 + "updated_at": { + "type": "string", + "format": "date-time" } } }, - "ViolationsHistoryMetadata": { - "title": "Violations History Metadata", + "ConversationSendMessage": { + "title": "Conversation Send Message", "type": "object", - "description": "Metadata for violations history query", + "description": "Send a message in a conversation", "additionalProperties": false, "required": [ - "interval", - "start_date", - "end_date" + "message" ], "properties": { - "interval": { + "message": { "type": "string", - "description": "Interval in days used for grouping", - "example": "30" + "example": "Help me find all EC2 instances with open ports", + "description": "The message content to be sent" }, - "start_date": { + "query_context": { "type": "string", - "format": "date", - "description": "Start date of the query range", - "example": "2025-05-01" + "example": "SELECT * FROM ec2_instances WHERE open_ports IS NOT NULL", + "default": "", + "description": "Optional context for the message, such as the current SQL query being edited" }, - "end_date": { + "mode": { "type": "string", - "format": "date", - "description": "End date of the query range", - "example": "2026-12-01" + "description": "The mode of the conversation, which can influence the behavior of the AI.", + "default": "sql", + "enum": [ + "ask", + "sql" + ] } } }, - "ViolationsHistory": { - "title": "Violations History", - "type": "object", - "description": "Violations history over time", - "additionalProperties": false, - "required": [ - "items", - "metadata" + "CustomColumnSortBy": { + "title": "CustomColumnSortBy", + "type": "string", + "enum": [ + "id", + "description", + "column_name", + "label", + "value_expr", + "created_by", + "created_at", + "updated_at" + ] + }, + "CustomColumnSortDirection": { + "title": "CustomColumnSortDirection", + "type": "string", + "enum": [ + "asc", + "desc" ], - "properties": { - "items": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ViolationsHistoryItem" - } - }, - "metadata": { - "$ref": "#/components/schemas/ViolationsHistoryMetadata" - } - } + "default": "asc" }, - "PolicyGroupWithCounts": { - "title": "Policy Group With Counts", + "CustomColumnID": { + "description": "The unique ID for the custom column.", + "type": "string", + "format": "uuid", + "x-go-name": "CustomColumnID" + }, + "CustomColumnColumnName": { + "type": "string", + "description": "The name for the custom column.", + "pattern": "^[a-zA-Z_][a-zA-Z0-9_]*$", + "example": "tags_v1_region", + "x-pattern-message": "Letters, numbers, and underscores only. Must start with a letter.", + "minLength": 1, + "maxLength": 63 + }, + "CustomColumnValueExpr": { + "type": "string", + "description": "The SQL expression for the custom column." + }, + "CustomColumn": { + "title": "Custom Column", "type": "object", - "description": "Policy Group with policy count and violation counts by severity", + "description": "A custom column that is configured manually by the user.", "additionalProperties": false, "required": [ "id", - "name", - "description", - "policy_count", - "violation_count_low", - "violation_count_medium", - "violation_count_high", - "violation_count_critical", - "created_at", - "updated_at" + "column_name", + "label", + "value_expr", + "created_by", + "created_at" ], - "allOf": [ - { - "$ref": "#/components/schemas/PolicyGroup" + "properties": { + "id": { + "$ref": "#/components/schemas/CustomColumnID" }, - { - "type": "object", - "properties": { - "policy_count": { - "type": "integer", - "description": "Number of policies in this group", - "example": 5, - "default": 0 - }, - "violation_count_low": { - "type": "integer", - "description": "Total violations from low severity policies in this group", - "example": 10, - "default": 0 - }, - "violation_count_medium": { - "type": "integer", - "description": "Total violations from medium severity policies in this group", - "example": 25, - "default": 0 - }, - "violation_count_high": { - "type": "integer", - "description": "Total violations from high severity policies in this group", - "example": 15, - "default": 0 - }, - "violation_count_critical": { - "type": "integer", - "description": "Total violations from critical severity policies in this group", - "example": 3, - "default": 0 - } - } + "description": { + "type": "string" + }, + "column_name": { + "$ref": "#/components/schemas/CustomColumnColumnName" + }, + "label": { + "type": "string", + "example": "Environment name" + }, + "value_expr": { + "$ref": "#/components/schemas/CustomColumnValueExpr" + }, + "created_by": { + "$ref": "#/components/schemas/CreatedBy" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" } - ] + } }, - "PolicyGroupCreate": { - "title": "Policy Group Create", + "CustomColumnCreateOrUpdate": { + "title": "Custom Column Create or Update", "type": "object", - "description": "Create a policy group", + "description": "Create or update a custom column", "additionalProperties": false, "required": [ - "name" + "column_name", + "label", + "value_expr" + ], + "properties": { + "description": { + "type": "string" + }, + "column_name": { + "$ref": "#/components/schemas/CustomColumnColumnName" + }, + "label": { + "type": "string", + "example": "Environment name" + }, + "value_expr": { + "$ref": "#/components/schemas/CustomColumnValueExpr" + } + } + }, + "FilterTag": { + "description": "A table column filter tag.", + "type": "string" + }, + "FilterExpression": { + "description": "A table column filter.", + "type": "string", + "example": "resource_type=aws_s3_buckets" + }, + "TableName": { + "description": "The name of the table.", + "type": "string", + "example": "cloud_assets" + }, + "Filter": { + "title": "Filter", + "type": "object", + "description": "Saved filter", + "additionalProperties": false, + "required": [ + "id", + "name", + "expression", + "created_at" ], "properties": { + "id": { + "description": "ID of the Filter", + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "ID" + }, "name": { "type": "string", - "example": "Security Policies" + "example": "t2.micro EC2 instances" + }, + "expression": { + "$ref": "#/components/schemas/FilterExpression" }, "description": { "type": "string", - "default": "", - "example": "Group containing all security-related policies" + "example": "Filter to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" }, - "policy_ids": { + "table": { + "$ref": "#/components/schemas/TableName" + }, + "query_id": { + "$ref": "#/components/schemas/QueryID" + }, + "user_id": { + "$ref": "#/components/schemas/UserID" + }, + "tags": { "type": "array", "items": { - "type": "string", - "format": "uuid" + "$ref": "#/components/schemas/FilterTag" }, - "nullable": true, - "description": "Optional array of policy IDs to add to this group" + "x-go-type-skip-optional-pointer": true + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" } } }, - "PolicyGroupUpdate": { - "title": "Policy Group Update", + "FilterID": { + "description": "The unique ID for the filter.", + "type": "string", + "format": "uuid", + "x-go-name": "FilterID" + }, + "FilterUpdate": { + "title": "Filter definition for updating a filter", + "description": "Filter Update Definition", "type": "object", - "description": "Update a policy group", - "additionalProperties": false, "properties": { "name": { - "type": "string" + "type": "string", + "example": "t2.micro EC2 instances" }, "description": { "type": "string" }, - "policy_ids": { + "expression": { + "$ref": "#/components/schemas/FilterExpression" + }, + "tags": { "type": "array", "items": { - "type": "string", - "format": "uuid" - }, - "nullable": true, - "description": "Policy IDs to set for this group" + "$ref": "#/components/schemas/FilterTag" + } } } }, - "APIKeyName": { - "description": "Name of the API key", - "type": "string", - "example": "cli-api-key", - "maxLength": 255, - "minLength": 1, - "pattern": "^(?:[a-zA-Z0-9][a-zA-Z0-9- ]*)?[a-zA-Z0-9]$", - "x-pattern-message": "can contain only letters, numbers, spaces, and hyphens, starting and ending with a letter or number" - }, - "APIKeyID": { - "description": "ID of the API key", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "APIKeyID" - }, - "APIKey": { - "description": "API Key to interact with CloudQuery Platform", + "NotificationDetail": { + "title": "Notification Detail", "type": "object", + "description": "A notification instance for a triggered alert, including one notification destination. Each notification destination for an alert will result in a separate notification item.", + "additionalProperties": false, "required": [ "id", - "name", - "expires_at", - "expired", - "roles" + "query_id", + "policy_id", + "message", + "severity", + "state", + "total_violations", + "created_at", + "updated_at" ], "properties": { - "name": { - "$ref": "#/components/schemas/APIKeyName" + "id": { + "type": "string", + "format": "uuid", + "description": "Unique identifier for the alert", + "x-go-name": "ID" }, - "created_by": { + "query_id": { "type": "string", - "example": "user@example.com", - "description": "email of the user that created the API key" + "format": "uuid", + "description": "Reference to the associated query", + "x-go-name": "QueryID" }, - "id": { - "$ref": "#/components/schemas/APIKeyID" + "policy_id": { + "type": "string", + "format": "uuid", + "description": "Reference to the associated policy", + "x-go-name": "PolicyID" }, - "key": { + "message": { "type": "string", - "description": "API key. Will be shown only in the response when creating the key.", - "example": "1234567890abcdef1234567890abcdef" + "description": "Alert message content" }, - "created_at": { + "severity": { + "$ref": "#/components/schemas/AlertSeverity" + }, + "state": { + "$ref": "#/components/schemas/AlertState" + }, + "total_violations": { + "type": "integer", + "format": "int64", + "description": "Number of violations that triggered the alert" + }, + "last_evaluated_at": { "type": "string", "format": "date-time", - "example": "2017-07-14T16:53:42Z" + "description": "Timestamp when the alert was last evaluated" }, - "expires_at": { + "triggered_at": { "type": "string", - "description": "Timestamp at which API key will stop working", "format": "date-time", - "example": "2017-07-14T16:53:42Z" + "description": "Timestamp when the alert was triggered" }, - "last_access_at": { + "created_at": { "type": "string", "format": "date-time", - "example": "2017-07-14T16:53:42Z", - "description": "Timestamp at which API key was last used - accurate to the day only." + "description": "Timestamp when the alert was created" }, - "expired": { - "type": "boolean", - "description": "Whether the API key has expired or not", - "example": false + "updated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last updated" }, - "roles": { - "type": "array", - "items": { - "$ref": "#/components/schemas/Role" - } + "notification_destination": { + "$ref": "#/components/schemas/NotificationDestinationListItem", + "description": "The notification destination for this notification item (null if no destinations configured)", + "nullable": true } } }, - "RoleID": { - "description": "The unique ID for the role.", - "type": "string", - "format": "uuid", - "x-go-name": "RoleID" - }, - "ConversationCreate": { + "NotificationDestinationData": { + "title": "Notification Destination Data", "type": "object", - "required": [ - "message" - ], + "description": "Notification Destination Data", "properties": { - "message": { + "type": { + "type": "string", + "enum": [ + "webhook", + "slack" + ], + "default": "webhook", + "description": "Type of notification destination" + }, + "slack_connection_id": { + "type": "string", + "format": "uuid", + "description": "Slack connection ID (required for slack type)", + "x-go-name": "SlackConnectionID" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs to send notifications to (required for slack type)", + "x-go-name": "SlackChannels" + }, + "custom_message": { "type": "string", - "description": "The initial message to start the conversation." + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", + "x-go-name": "CustomMessage" }, - "current_query": { + "url": { "type": "string", - "description": "An optional current query to provide context for the conversation." + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "description": "Webhook URL (required for webhook type, must not be set for slack type)", + "x-go-name": "URL" }, - "mode": { + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "description": "HTTP headers (required for webhook type, must not be set for slack type)", + "x-go-name": "HTTPHeaders", + "x-go-type-skip-optional-pointer": true + }, + "http_body": { "type": "string", - "description": "The mode of the conversation, which can influence the behavior of the AI.", - "default": "sql", - "enum": [ - "ask", - "sql" - ] + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", + "x-go-name": "HTTPBody" } } }, - "ConversationMessage": { + "NotificationDestinationCreate": { + "title": "Create Notification Destination", + "type": "object", + "description": "Create Notification Destination", + "allOf": [ + { + "$ref": "#/components/schemas/NotificationDestinationData" + }, + { + "type": "object", + "required": [ + "name", + "enabled" + ], + "properties": { + "name": { + "type": "string", + "example": "Send to Slack" + }, + "enabled": { + "type": "boolean" + } + } + } + ] + }, + "NotificationDestination": { + "title": "Notification Destination", "type": "object", + "description": "Notification Destination", + "additionalProperties": false, "required": [ "id", - "role", - "content", + "name", + "enabled", + "type", + "url", "created_at", - "message_type", - "end_turn", - "mode" + "updated_at" ], "properties": { "id": { + "$ref": "#/components/schemas/NotificationDestinationID" + }, + "name": { "type": "string", - "format": "uuid", - "description": "Unique identifier of the message", - "x-go-name": "ID" + "example": "Send to Slack" }, - "role": { + "enabled": { + "type": "boolean" + }, + "type": { "type": "string", "enum": [ - "user", - "assistant", - "system" + "webhook", + "slack" ], - "description": "Role of the message sender" + "description": "Type of notification destination" }, - "content": { + "url": { "type": "string", - "description": "Content of the message. In the case of tool use or tool result, this will contain JSON data." + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "x-go-name": "URL" }, - "query_context": { + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "x-go-name": "HTTPHeaders", + "x-go-type-skip-optional-pointer": true + }, + "http_body": { "type": "string", - "description": "The current query context when the message was sent, if applicable" + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", + "x-go-name": "HTTPBody" }, - "message_type": { + "slack_connection_id": { "type": "string", - "enum": [ - "error", - "message", - "tool_use", - "tool_result" - ], - "description": "Type of the message content" + "format": "uuid", + "nullable": true, + "description": "Slack connection ID (only for slack type)", + "x-go-name": "SlackConnectionID" }, - "created_at": { + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs (only for slack type)", + "x-go-name": "SlackChannels" + }, + "custom_message": { "type": "string", - "format": "date-time" + "nullable": true, + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type)", + "x-go-name": "CustomMessage" }, - "end_turn": { - "type": "boolean", - "description": "Whether this message ends the conversation turn", - "default": false + "last_notification_error_timestamp": { + "type": "string", + "format": "date-time", + "nullable": true, + "description": "Timestamp of the last notification error", + "x-go-name": "LastNotificationErrorTimestamp" }, - "mode": { + "last_notification_error_code": { "type": "string", - "description": "The mode of the conversation when this message was sent, which can influence the behavior of the AI.", - "default": "sql", - "enum": [ - "ask", - "sql" - ] + "nullable": true, + "description": "Error code of the last notification error", + "x-go-name": "LastNotificationErrorCode" + }, + "last_notification_error_message": { + "type": "string", + "nullable": true, + "description": "Error message of the last notification error", + "x-go-name": "LastNotificationErrorMessage" + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" } } }, - "Conversation": { + "NotificationDestinationUpdate": { + "title": "Update Notification Destination", "type": "object", - "required": [ - "id", - "messages", - "created_at", - "updated_at" - ], + "description": "Update Notification Destination", + "additionalProperties": false, "properties": { - "id": { + "name": { "type": "string", - "format": "uuid", - "description": "Unique identifier of the conversation", - "x-go-name": "ID" + "example": "Send to Slack" }, - "title": { + "enabled": { + "type": "boolean" + }, + "url": { "type": "string", - "description": "Optional title of the conversation" + "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", + "x-go-name": "URL" }, - "messages": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ConversationMessage" - } + "http_headers": { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "x-go-name": "HTTPHeaders" }, - "created_at": { + "http_body": { "type": "string", - "format": "date-time" + "example": "{\"text\": \"Alert: {{alert_message}}\"}", + "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", + "x-go-name": "HTTPBody" }, - "updated_at": { + "custom_message": { "type": "string", - "format": "date-time" + "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", + "x-go-name": "CustomMessage" + }, + "slack_connection_id": { + "type": "string", + "format": "uuid", + "description": "Slack connection ID (only for slack type, must not be set for webhook)", + "x-go-name": "SlackConnectionID" + }, + "slack_channels": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of Slack channel IDs to send notifications to (only for slack type, must not be set for webhook)", + "x-go-name": "SlackChannels" } } }, - "ConversationSendMessage": { - "title": "Conversation Send Message", + "SlackConnectionCreate": { + "title": "Create Slack Connection", "type": "object", - "description": "Send a message in a conversation", + "description": "Create Slack Connection", "additionalProperties": false, "required": [ - "message" + "code" ], "properties": { - "message": { - "type": "string", - "example": "Help me find all EC2 instances with open ports", - "description": "The message content to be sent" - }, - "query_context": { + "code": { "type": "string", - "example": "SELECT * FROM ec2_instances WHERE open_ports IS NOT NULL", - "default": "", - "description": "Optional context for the message, such as the current SQL query being edited" + "description": "OAuth code from Slack authorization" }, - "mode": { + "redirect_uri": { "type": "string", - "description": "The mode of the conversation, which can influence the behavior of the AI.", - "default": "sql", - "enum": [ - "ask", - "sql" - ] + "description": "Redirect URI that was used when obtaining the OAuth code (required by Slack when exchanging the code)" } } }, - "CustomColumnSortBy": { - "title": "CustomColumnSortBy", - "type": "string", - "enum": [ - "id", - "description", - "column_name", - "label", - "value_expr", - "created_by", - "created_at", - "updated_at" - ] - }, - "CustomColumnSortDirection": { - "title": "CustomColumnSortDirection", - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - }, - "CustomColumnID": { - "description": "The unique ID for the custom column.", - "type": "string", - "format": "uuid", - "x-go-name": "CustomColumnID" - }, - "CustomColumnColumnName": { - "type": "string", - "description": "The name for the custom column.", - "pattern": "^[a-zA-Z_][a-zA-Z0-9_]*$", - "example": "tags_v1_region", - "x-pattern-message": "Letters, numbers, and underscores only. Must start with a letter.", - "minLength": 1, - "maxLength": 63 - }, - "CustomColumnValueExpr": { - "type": "string", - "description": "The SQL expression for the custom column." - }, - "CustomColumn": { - "title": "Custom Column", + "SlackConnection": { + "title": "Slack Connection", "type": "object", - "description": "A custom column that is configured manually by the user.", + "description": "Slack Connection", "additionalProperties": false, "required": [ "id", - "column_name", - "label", - "value_expr", - "created_by", - "created_at" + "slack_workspace_id", + "team_name", + "created_at", + "updated_at" ], "properties": { "id": { - "$ref": "#/components/schemas/CustomColumnID" - }, - "description": { - "type": "string" - }, - "column_name": { - "$ref": "#/components/schemas/CustomColumnColumnName" - }, - "label": { "type": "string", - "example": "Environment name" + "format": "uuid", + "description": "Slack connection ID" }, - "value_expr": { - "$ref": "#/components/schemas/CustomColumnValueExpr" + "slack_workspace_id": { + "type": "string", + "description": "Slack workspace (team) ID", + "x-go-name": "SlackWorkspaceID" }, - "created_by": { - "$ref": "#/components/schemas/CreatedBy" + "team_name": { + "type": "string", + "description": "Slack workspace (team) name", + "x-go-name": "TeamName" }, "created_at": { "example": "2017-07-14T16:53:42Z", "format": "date-time", "type": "string" + }, + "updated_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" } } }, - "CustomColumnCreateOrUpdate": { - "title": "Custom Column Create or Update", + "SlackChannel": { + "title": "Slack Channel", "type": "object", - "description": "Create or update a custom column", + "description": "Slack Channel", "additionalProperties": false, "required": [ - "column_name", - "label", - "value_expr" + "id", + "name" ], "properties": { - "description": { - "type": "string" - }, - "column_name": { - "$ref": "#/components/schemas/CustomColumnColumnName" + "id": { + "type": "string", + "description": "Channel ID" }, - "label": { + "name": { "type": "string", - "example": "Environment name" + "description": "Channel name" }, - "value_expr": { - "$ref": "#/components/schemas/CustomColumnValueExpr" + "is_private": { + "type": "boolean", + "description": "Whether the channel is private", + "x-go-name": "IsPrivate" + }, + "is_archived": { + "type": "boolean", + "description": "Whether the channel is archived", + "x-go-name": "IsArchived" } } }, - "FilterTag": { - "description": "A table column filter tag.", - "type": "string" - }, - "FilterExpression": { - "description": "A table column filter.", - "type": "string", - "example": "resource_type=aws_s3_buckets" - }, - "TableName": { - "description": "The name of the table.", + "OnboardingID": { + "description": "ID of the cloud provider onboarding session", "type": "string", - "example": "cloud_assets" + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab", + "x-go-name": "OnboardingID" }, - "Filter": { - "title": "Filter", + "OnboardingAWSCreateResponse": { "type": "object", - "description": "Saved filter", + "description": "AWS OpenID onboarding", "additionalProperties": false, "required": [ "id", - "name", - "expression", - "created_at" + "issuer_url", + "audience", + "subject", + "template_url", + "notify_path", + "notify_token" ], "properties": { "id": { - "description": "ID of the Filter", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "ID" + "$ref": "#/components/schemas/OnboardingID" }, - "name": { + "region": { "type": "string", - "example": "t2.micro EC2 instances" - }, - "expression": { - "$ref": "#/components/schemas/FilterExpression" + "description": "An AWS region (such as 'us-east-1') where stack is deployed" }, - "description": { + "stack_name": { "type": "string", - "example": "Filter to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" - }, - "table": { - "$ref": "#/components/schemas/TableName" - }, - "query_id": { - "$ref": "#/components/schemas/QueryID" + "description": "Stack name that should be used", + "maxLength": 128 }, - "user_id": { - "$ref": "#/components/schemas/UserID" + "issuer_url": { + "type": "string", + "description": "URL of the OpenID server to use when setting up a trust relationship", + "x-go-name": "IssuerURL" }, - "tags": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - }, - "x-go-type-skip-optional-pointer": true + "audience": { + "type": "string", + "description": "OpenID audience claim for the trust realshionship", + "x-go-name": "Audience" }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - } - } - }, - "FilterID": { - "description": "The unique ID for the filter.", - "type": "string", - "format": "uuid", - "x-go-name": "FilterID" - }, - "FilterUpdate": { - "title": "Filter definition for updating a filter", - "description": "Filter Update Definition", - "type": "object", - "properties": { - "name": { + "subject": { "type": "string", - "example": "t2.micro EC2 instances" + "description": "OpenID subject claim for the trust relationship", + "x-go-name": "Subject" }, - "description": { - "type": "string" + "notify_path": { + "type": "string", + "description": "Path of the notify endpoint to use for status updates", + "x-go-name": "NotifyPath" }, - "expression": { - "$ref": "#/components/schemas/FilterExpression" + "template_url": { + "type": "string", + "description": "URL of the CloudFormation template to use for the authentication", + "x-go-name": "TemplateURL" }, - "tags": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FilterTag" - } + "notify_token": { + "type": "string", + "description": "An authentication token that should be used for notifications" } } }, - "NotificationDetail": { - "title": "Notification Detail", + "OnboardingAWS": { "type": "object", - "description": "A notification instance for a triggered alert, including one notification destination. Each notification destination for an alert will result in a separate notification item.", - "additionalProperties": false, - "required": [ - "id", - "query_id", - "policy_id", - "message", - "severity", - "state", - "total_violations", + "description": "AWS OpenID onboarding", + "additionalProperties": false, + "required": [ + "id", + "stage", "created_at", - "updated_at" + "updated_at", + "issuer_url", + "audience", + "subject" ], "properties": { "id": { - "type": "string", - "format": "uuid", - "description": "Unique identifier for the alert", - "x-go-name": "ID" + "$ref": "#/components/schemas/OnboardingID" }, - "query_id": { + "stage": { "type": "string", - "format": "uuid", - "description": "Reference to the associated query", - "x-go-name": "QueryID" + "description": "Stage of the onboarding process", + "x-go-name": "OnboardingStage" }, - "policy_id": { + "created_at": { "type": "string", - "format": "uuid", - "description": "Reference to the associated policy", - "x-go-name": "PolicyID" + "format": "date-time", + "example": "2017-07-14T16:53:42Z" }, - "message": { + "updated_at": { "type": "string", - "description": "Alert message content" - }, - "severity": { - "$ref": "#/components/schemas/AlertSeverity" + "format": "date-time", + "example": "2017-07-14T16:53:42Z" }, - "state": { - "$ref": "#/components/schemas/AlertState" + "issuer_url": { + "type": "string", + "description": "URL of the OpenID server to use when setting up a trust relationship", + "x-go-name": "IssuerURL" }, - "total_violations": { - "type": "integer", - "format": "int64", - "description": "Number of violations that triggered the alert" + "audience": { + "type": "string", + "description": "OpenID audience claim for the trust realshionship", + "x-go-name": "Audience" }, - "last_evaluated_at": { + "subject": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was last evaluated" + "description": "OpenID subject claim for the trust relationship", + "x-go-name": "Subject" }, - "triggered_at": { + "management_role_arn": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was triggered" + "description": "Role used to manage the platform onboarding", + "x-go-name": "ManagementRoleARN" }, - "created_at": { + "failure_reason": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was created" + "description": "CloudFormation stack errors", + "x-go-name": "FailureReason" }, - "updated_at": { + "sync_role_name": { "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was last updated" + "x-go-name": "SyncRoleName", + "description": "(organization mode) The name of the sync role used to sync a specific account within the organization.\nNote: This is the role name only, not the full ARN.\n" }, - "notification_destination": { - "$ref": "#/components/schemas/NotificationDestinationListItem", - "description": "The notification destination for this notification item (null if no destinations configured)", - "nullable": true + "organizational_units": { + "type": "array", + "x-go-name": "OrganizationalUnitIDs", + "description": "(organization mode) A list of Organizational Unit (OU) IDs included in this onboarding.\n", + "items": { + "type": "string" + } } } }, - "NotificationDestinationData": { - "title": "Notification Destination Data", + "BaseNotification": { "type": "object", - "description": "Notification Destination Data", + "required": [ + "status" + ], "properties": { - "type": { - "type": "string", - "enum": [ - "webhook", - "slack" - ], - "default": "webhook", - "description": "Type of notification destination" - }, - "slack_connection_id": { - "type": "string", - "format": "uuid", - "description": "Slack connection ID (required for slack type)", - "x-go-name": "SlackConnectionID" + "status": { + "type": "string" + } + } + }, + "StartedNotification": { + "allOf": [ + { + "$ref": "#/components/schemas/BaseNotification" }, - "slack_channels": { - "type": "array", - "items": { - "type": "string" - }, - "description": "List of Slack channel IDs to send notifications to (required for slack type)", - "x-go-name": "SlackChannels" + { + "type": "object", + "properties": { + "status": { + "enum": [ + "started" + ] + } + } + } + ] + }, + "RevokedNotification": { + "allOf": [ + { + "$ref": "#/components/schemas/BaseNotification" }, - "custom_message": { - "type": "string", - "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", - "x-go-name": "CustomMessage" + { + "type": "object", + "properties": { + "status": { + "enum": [ + "revoked" + ] + } + } + } + ] + }, + "FailedNotification": { + "allOf": [ + { + "$ref": "#/components/schemas/BaseNotification" }, - "url": { - "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", - "description": "Webhook URL (required for webhook type, must not be set for slack type)", - "x-go-name": "URL" + { + "type": "object", + "required": [ + "reason" + ], + "properties": { + "status": { + "enum": [ + "failed" + ] + }, + "reason": { + "type": "string" + } + } + } + ] + }, + "DeployedNotification": { + "allOf": [ + { + "$ref": "#/components/schemas/BaseNotification" }, - "http_headers": { + { "type": "object", - "additionalProperties": { - "type": "string" - }, - "description": "HTTP headers (required for webhook type, must not be set for slack type)", - "x-go-name": "HTTPHeaders", - "x-go-type-skip-optional-pointer": true + "required": [ + "management_role_arn", + "deployment_mode", + "stack_id" + ], + "properties": { + "status": { + "enum": [ + "deployed" + ] + }, + "management_role_arn": { + "type": "string" + }, + "deployment_mode": { + "type": "string" + }, + "stack_id": { + "type": "string" + } + } + } + ] + }, + "CompletedNotification": { + "allOf": [ + { + "$ref": "#/components/schemas/BaseNotification" }, - "http_body": { - "type": "string", - "example": "{\"text\": \"Alert: {{alert_message}}\"}", - "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", - "x-go-name": "HTTPBody" + { + "type": "object", + "required": [ + "admin_role_arn", + "sync_role_name", + "organizational_units", + "skipped_accounts" + ], + "properties": { + "status": { + "enum": [ + "completed" + ] + }, + "admin_role_arn": { + "type": "string" + }, + "sync_role_name": { + "type": "string" + }, + "organizational_units": { + "type": "array", + "items": { + "type": "string" + } + }, + "skipped_accounts": { + "type": "array", + "items": { + "type": "string" + } + }, + "failed_accounts": { + "type": "number" + }, + "additional_stack_ids": { + "type": "array", + "items": { + "type": "string" + } + } + } } - } + ] }, - "NotificationDestinationCreate": { - "title": "Create Notification Destination", - "type": "object", - "description": "Create Notification Destination", + "CompletedSingleAccountNotification": { "allOf": [ { - "$ref": "#/components/schemas/NotificationDestinationData" + "$ref": "#/components/schemas/BaseNotification" }, { "type": "object", "required": [ - "name", - "enabled" + "sync_role_arn", + "stack_id" ], "properties": { - "name": { - "type": "string", - "example": "Send to Slack" + "status": { + "enum": [ + "completed_account" + ] }, - "enabled": { - "type": "boolean" + "sync_role_arn": { + "type": "string" + }, + "stack_id": { + "type": "string" } } } ] }, - "NotificationDestination": { - "title": "Notification Destination", - "type": "object", - "description": "Notification Destination", - "additionalProperties": false, - "required": [ - "id", - "name", - "enabled", - "type", - "url", - "created_at", - "updated_at" - ], - "properties": { - "id": { - "$ref": "#/components/schemas/NotificationDestinationID" - }, - "name": { - "type": "string", - "example": "Send to Slack" - }, - "enabled": { - "type": "boolean" - }, - "type": { - "type": "string", - "enum": [ - "webhook", - "slack" - ], - "description": "Type of notification destination" - }, - "url": { - "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", - "x-go-name": "URL" - }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "x-go-name": "HTTPHeaders", - "x-go-type-skip-optional-pointer": true - }, - "http_body": { - "type": "string", - "example": "{\"text\": \"Alert: {{alert_message}}\"}", - "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", - "x-go-name": "HTTPBody" - }, - "slack_connection_id": { - "type": "string", - "format": "uuid", - "nullable": true, - "description": "Slack connection ID (only for slack type)", - "x-go-name": "SlackConnectionID" - }, - "slack_channels": { - "type": "array", - "items": { - "type": "string" - }, - "description": "List of Slack channel IDs (only for slack type)", - "x-go-name": "SlackChannels" - }, - "custom_message": { - "type": "string", - "nullable": true, - "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type)", - "x-go-name": "CustomMessage" - }, - "last_notification_error_timestamp": { - "type": "string", - "format": "date-time", - "nullable": true, - "description": "Timestamp of the last notification error", - "x-go-name": "LastNotificationErrorTimestamp" - }, - "last_notification_error_code": { - "type": "string", - "nullable": true, - "description": "Error code of the last notification error", - "x-go-name": "LastNotificationErrorCode" - }, - "last_notification_error_message": { - "type": "string", - "nullable": true, - "description": "Error message of the last notification error", - "x-go-name": "LastNotificationErrorMessage" - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" - } - } - }, - "NotificationDestinationUpdate": { - "title": "Update Notification Destination", - "type": "object", - "description": "Update Notification Destination", - "additionalProperties": false, - "properties": { - "name": { - "type": "string", - "example": "Send to Slack" - }, - "enabled": { - "type": "boolean" - }, - "url": { - "type": "string", - "example": "https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", - "x-go-name": "URL" + "OnboardingAWSNotification": { + "oneOf": [ + { + "$ref": "#/components/schemas/StartedNotification" }, - "http_headers": { - "type": "object", - "additionalProperties": { - "type": "string" - }, - "x-go-name": "HTTPHeaders" + { + "$ref": "#/components/schemas/RevokedNotification" }, - "http_body": { - "type": "string", - "example": "{\"text\": \"Alert: {{alert_message}}\"}", - "description": "HTTP body template (required for webhook type, must not be set for slack type). Supports simple variable interpolation using {{variable}} syntax. Available variables: {{query_name}}, {{query_url}}, {{alert_status}}, {{alert_message}}, {{alert_severity}}, {{alert_violations}}.", - "x-go-name": "HTTPBody" + { + "$ref": "#/components/schemas/FailedNotification" }, - "custom_message": { - "type": "string", - "description": "Optional custom message prepended to the alert when sending to Slack (only for slack type, must not be set for webhook)", - "x-go-name": "CustomMessage" + { + "$ref": "#/components/schemas/DeployedNotification" }, - "slack_connection_id": { - "type": "string", - "format": "uuid", - "description": "Slack connection ID (only for slack type, must not be set for webhook)", - "x-go-name": "SlackConnectionID" + { + "$ref": "#/components/schemas/CompletedNotification" }, - "slack_channels": { - "type": "array", - "items": { - "type": "string" - }, - "description": "List of Slack channel IDs to send notifications to (only for slack type, must not be set for webhook)", - "x-go-name": "SlackChannels" + { + "$ref": "#/components/schemas/CompletedSingleAccountNotification" } - } - }, - "SlackConnectionCreate": { - "title": "Create Slack Connection", - "type": "object", - "description": "Create Slack Connection", - "additionalProperties": false, - "required": [ - "code" ], - "properties": { - "code": { - "type": "string", - "description": "OAuth code from Slack authorization" - }, - "redirect_uri": { - "type": "string", - "description": "Redirect URI that was used when obtaining the OAuth code (required by Slack when exchanging the code)" + "discriminator": { + "propertyName": "status", + "mapping": { + "started": "#/components/schemas/StartedNotification", + "revoked": "#/components/schemas/RevokedNotification", + "failed": "#/components/schemas/FailedNotification", + "deployed": "#/components/schemas/DeployedNotification", + "completed": "#/components/schemas/CompletedNotification", + "completed_account": "#/components/schemas/CompletedSingleAccountNotification" } } }, - "SlackConnection": { - "title": "Slack Connection", + "OnboardingAWSAccounts": { "type": "object", - "description": "Slack Connection", + "description": "AWS OpenID onboarding account structure", "additionalProperties": false, "required": [ "id", - "slack_workspace_id", - "team_name", - "created_at", - "updated_at" + "type" ], "properties": { "id": { "type": "string", - "format": "uuid", - "description": "Slack connection ID" + "description": "ID of the account or OU", + "x-go-name": "ID" }, - "slack_workspace_id": { + "arn": { "type": "string", - "description": "Slack workspace (team) ID", - "x-go-name": "SlackWorkspaceID" + "description": "ARN of the account or OU", + "x-go-name": "ARN" + }, + "type": { + "type": "string", + "description": "Type of the account", + "enum": [ + "OU", + "account", + "root" + ] }, - "team_name": { + "name": { "type": "string", - "description": "Slack workspace (team) name", - "x-go-name": "TeamName" - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "description": "Display name of the account or OU" }, - "updated_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "children": { + "type": "array", + "description": "Children accounts and OUs of the target account", + "items": { + "$ref": "#/components/schemas/OnboardingAWSAccounts" + } } } }, - "SlackChannel": { - "title": "Slack Channel", + "OrganizationalUnitID": { + "description": "ID of an organizational unit in AWS", + "type": "string", + "example": "ou-7f3s-j8zfa1ao", + "pattern": "^ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}$", + "x-pattern-message": "must start with \"ou-\" followed by 4 to 32 lowercase letters or digits, then a second \"-\" dash, and finally 8 to 32 additional lowercase letters or digits", + "x-go-name": "OrganizationalUnitID" + }, + "OnboardingAWSProvision": { "type": "object", - "description": "Slack Channel", - "additionalProperties": false, + "description": "Stackset provisioning configuration", "required": [ - "id", - "name" + "notify_url", + "organizational_units" ], "properties": { - "id": { - "type": "string", - "description": "Channel ID" - }, - "name": { + "notify_url": { "type": "string", - "description": "Channel name" + "description": "URL that should be used for provisioning notifications (including scheme, hostname, and path)" }, - "is_private": { - "type": "boolean", - "description": "Whether the channel is private", - "x-go-name": "IsPrivate" + "organizational_units": { + "type": "array", + "description": "OUs to provision roles into", + "items": { + "type": "string", + "pattern": "^(r-[0-9a-z]{4,32}|ou-[a-z0-9]{4,32}-[a-z0-9]{8,32})$", + "example": "r-xvfz", + "x-pattern-message": "must start with either \"r-\" followed by 4 to 32 lowercase letters or digits, or \"ou-\" followed by 4 to 32 lowercase letters or digits, a hyphen, and then 8 to 32 lowercase letters or digits, with no additional characters before or after." + } }, - "is_archived": { - "type": "boolean", - "description": "Whether the channel is archived", - "x-go-name": "IsArchived" + "skip_accounts": { + "type": "array", + "description": "Account IDs to skip onboarding", + "items": { + "description": "ID of an account in AWS", + "type": "string", + "example": "615713231484", + "pattern": "^\\d{12}$", + "x-pattern-message": "account ID must be exactly 12 digits" + } } } }, - "OnboardingID": { - "description": "ID of the cloud provider onboarding session", - "type": "string", - "format": "uuid", - "example": "12345678-1234-1234-1234-1234567890ab", - "x-go-name": "OnboardingID" - }, - "OnboardingAWSCreateResponse": { + "OnboardingAWSCURCreateResponse": { "type": "object", - "description": "AWS OpenID onboarding", + "description": "AWS CUR onboarding create response", "additionalProperties": false, "required": [ "id", + "region", "issuer_url", "audience", "subject", @@ -14560,7 +16316,7 @@ }, "region": { "type": "string", - "description": "An AWS region (such as 'us-east-1') where stack is deployed" + "description": "AWS region where the CUR stack must be deployed. Always 'us-east-1' because AWS Cost and Usage Reports are only available in that region." }, "stack_name": { "type": "string", @@ -14574,7 +16330,7 @@ }, "audience": { "type": "string", - "description": "OpenID audience claim for the trust realshionship", + "description": "OpenID audience claim for the trust relationship", "x-go-name": "Audience" }, "subject": { @@ -14589,7 +16345,7 @@ }, "template_url": { "type": "string", - "description": "URL of the CloudFormation template to use for the authentication", + "description": "URL of the CloudFormation template to use for the CUR setup", "x-go-name": "TemplateURL" }, "notify_token": { @@ -14598,9 +16354,9 @@ } } }, - "OnboardingAWS": { + "OnboardingAWSCUR": { "type": "object", - "description": "AWS OpenID onboarding", + "description": "AWS CUR onboarding", "additionalProperties": false, "required": [ "id", @@ -14637,7 +16393,7 @@ }, "audience": { "type": "string", - "description": "OpenID audience claim for the trust realshionship", + "description": "OpenID audience claim for the trust relationship", "x-go-name": "Audience" }, "subject": { @@ -14645,100 +16401,34 @@ "description": "OpenID subject claim for the trust relationship", "x-go-name": "Subject" }, - "management_role_arn": { + "sync_role_arn": { "type": "string", - "description": "Role used to manage the platform onboarding", - "x-go-name": "ManagementRoleARN" + "description": "Role used to access the S3 bucket with CUR reports", + "x-go-name": "SyncRoleARN" }, - "failure_reason": { + "s3_bucket_name": { "type": "string", - "description": "CloudFormation stack errors", - "x-go-name": "FailureReason" + "description": "Name of the S3 bucket containing CUR reports", + "x-go-name": "S3BucketName" }, - "sync_role_name": { + "s3_report_prefix": { "type": "string", - "x-go-name": "SyncRoleName", - "description": "(organization mode) The name of the sync role used to sync a specific account within the organization.\nNote: This is the role name only, not the full ARN.\n" - }, - "organizational_units": { - "type": "array", - "x-go-name": "OrganizationalUnitIDs", - "description": "(organization mode) A list of Organizational Unit (OU) IDs included in this onboarding.\n", - "items": { - "type": "string" - } - } - } - }, - "BaseNotification": { - "type": "object", - "required": [ - "status" - ], - "properties": { - "status": { - "type": "string" - } - } - }, - "StartedNotification": { - "allOf": [ - { - "$ref": "#/components/schemas/BaseNotification" - }, - { - "type": "object", - "properties": { - "status": { - "enum": [ - "started" - ] - } - } - } - ] - }, - "RevokedNotification": { - "allOf": [ - { - "$ref": "#/components/schemas/BaseNotification" + "description": "Prefix path for CUR reports in the S3 bucket", + "x-go-name": "S3ReportPrefix" }, - { - "type": "object", - "properties": { - "status": { - "enum": [ - "revoked" - ] - } - } - } - ] - }, - "FailedNotification": { - "allOf": [ - { - "$ref": "#/components/schemas/BaseNotification" + "cur_report_name": { + "type": "string", + "description": "Name of the CUR report", + "x-go-name": "CURReportName" }, - { - "type": "object", - "required": [ - "reason" - ], - "properties": { - "status": { - "enum": [ - "failed" - ] - }, - "reason": { - "type": "string" - } - } + "failure_reason": { + "type": "string", + "description": "Error details if the onboarding failed", + "x-go-name": "FailureReason" } - ] + } }, - "DeployedNotification": { + "DeployedCURNotification": { "allOf": [ { "$ref": "#/components/schemas/BaseNotification" @@ -14746,97 +16436,32 @@ { "type": "object", "required": [ - "management_role_arn", - "deployment_mode", + "main_role_arn", + "sync_role_arn", + "s3_bucket_name", + "s3_report_prefix", + "cur_report_name", "stack_id" ], "properties": { "status": { "enum": [ - "deployed" + "deployed_cur" ] }, - "management_role_arn": { - "type": "string" - }, - "deployment_mode": { + "main_role_arn": { "type": "string" }, - "stack_id": { + "sync_role_arn": { "type": "string" - } - } - } - ] - }, - "CompletedNotification": { - "allOf": [ - { - "$ref": "#/components/schemas/BaseNotification" - }, - { - "type": "object", - "required": [ - "admin_role_arn", - "sync_role_name", - "organizational_units", - "skipped_accounts" - ], - "properties": { - "status": { - "enum": [ - "completed" - ] }, - "admin_role_arn": { + "s3_bucket_name": { "type": "string" }, - "sync_role_name": { + "s3_report_prefix": { "type": "string" }, - "organizational_units": { - "type": "array", - "items": { - "type": "string" - } - }, - "skipped_accounts": { - "type": "array", - "items": { - "type": "string" - } - }, - "failed_accounts": { - "type": "number" - }, - "additional_stack_ids": { - "type": "array", - "items": { - "type": "string" - } - } - } - } - ] - }, - "CompletedSingleAccountNotification": { - "allOf": [ - { - "$ref": "#/components/schemas/BaseNotification" - }, - { - "type": "object", - "required": [ - "sync_role_arn", - "stack_id" - ], - "properties": { - "status": { - "enum": [ - "completed_account" - ] - }, - "sync_role_arn": { + "cur_report_name": { "type": "string" }, "stack_id": { @@ -14846,7 +16471,7 @@ } ] }, - "OnboardingAWSNotification": { + "OnboardingAWSCURNotification": { "oneOf": [ { "$ref": "#/components/schemas/StartedNotification" @@ -14858,508 +16483,936 @@ "$ref": "#/components/schemas/FailedNotification" }, { - "$ref": "#/components/schemas/DeployedNotification" + "$ref": "#/components/schemas/DeployedCURNotification" + } + ], + "discriminator": { + "propertyName": "status", + "mapping": { + "started": "#/components/schemas/StartedNotification", + "revoked": "#/components/schemas/RevokedNotification", + "failed": "#/components/schemas/FailedNotification", + "deployed_cur": "#/components/schemas/DeployedCURNotification" + } + } + }, + "QueryExpression": { + "title": "QueryExpression", + "type": "string", + "description": "Query expression", + "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" + }, + "Alert": { + "title": "Alert", + "type": "object", + "description": "An alert instance that can be triggered by a query", + "additionalProperties": false, + "required": [ + "id", + "query_id", + "enabled", + "message", + "severity", + "state", + "total_violations", + "created_at", + "updated_at", + "num_destinations" + ], + "properties": { + "id": { + "type": "string", + "format": "uuid", + "description": "Unique identifier for the alert", + "x-go-name": "ID" + }, + "query_id": { + "type": "string", + "format": "uuid", + "description": "Reference to the associated query", + "x-go-name": "QueryID" + }, + "enabled": { + "type": "boolean", + "description": "Indicates if the alert is enabled" + }, + "message": { + "type": "string", + "description": "Alert message content" + }, + "severity": { + "$ref": "#/components/schemas/AlertSeverity" + }, + "state": { + "$ref": "#/components/schemas/AlertState" + }, + "total_violations": { + "type": "integer", + "format": "int64", + "description": "Number of violations that triggered the alert" + }, + "last_evaluated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last evaluated" + }, + "triggered_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was triggered" + }, + "created_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was created" + }, + "updated_at": { + "type": "string", + "format": "date-time", + "description": "Timestamp when the alert was last updated" + }, + "num_destinations": { + "type": "integer", + "description": "Number of notification destinations this alert is configured to send to" + } + } + }, + "QueryViewName": { + "description": "The name of the view the query is saved to in the warehouse", + "type": "string", + "pattern": "^(saved_query_view_[a-zA-Z0-9_]+|)$", + "x-pattern-message": "can contain only alphanumerical characters and underscores. must start with `saved_query_view_`" + }, + "Query": { + "title": "Query", + "type": "object", + "description": "Saved query", + "additionalProperties": false, + "required": [ + "id", + "name", + "query", + "created_at", + "alert_configured" + ], + "properties": { + "id": { + "$ref": "#/components/schemas/QueryID" + }, + "name": { + "type": "string", + "example": "Find all t2.micro EC2 instances" + }, + "query": { + "$ref": "#/components/schemas/QueryExpression" + }, + "description": { + "type": "string", + "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" + }, + "user_id": { + "$ref": "#/components/schemas/UserID" + }, + "tags": { + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryTag" + }, + "x-go-type-skip-optional-pointer": true + }, + "columns": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Columns returned by this query", + "x-go-type-skip-optional-pointer": true + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "alert_configured": { + "type": "boolean", + "description": "Indicates if the query has an alert configured" + }, + "alert": { + "$ref": "#/components/schemas/Alert" + }, + "view_name": { + "$ref": "#/components/schemas/QueryViewName" + } + } + }, + "TableSelect": { + "title": "TableSelect", + "type": "string" + }, + "TableSortBy": { + "title": "TableSortBy", + "type": "string" + }, + "TableSortDirection": { + "title": "TableSortDirection", + "type": "string", + "enum": [ + "asc", + "desc" + ], + "default": "asc" + }, + "TableGroupBy": { + "title": "TableGroupBy", + "type": "string" + }, + "TableData": { + "additionalProperties": false, + "properties": { + "query": { + "$ref": "#/components/schemas/QueryExpression" + }, + "columns": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "name", + "type" + ] + } + }, + "rows": { + "type": "array", + "items": { + "type": "array", + "items": {} + } + } + }, + "required": [ + "columns", + "rows" + ], + "title": "TableData", + "type": "object" + }, + "QueryCreate": { + "title": "Query Create", + "type": "object", + "description": "Create a saved query", + "additionalProperties": false, + "required": [ + "name", + "query" + ], + "properties": { + "name": { + "type": "string", + "example": "Find all t2.micro EC2 instances" + }, + "query": { + "type": "string", + "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" + }, + "public": { + "type": "boolean", + "default": true, + "x-omitempty": false, + "x-go-type-skip-optional-pointer": true + }, + "tags": { + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryTag" + }, + "x-go-type-skip-optional-pointer": true + }, + "description": { + "type": "string", + "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" }, - { - "$ref": "#/components/schemas/CompletedNotification" + "view_name": { + "$ref": "#/components/schemas/QueryViewName" }, - { - "$ref": "#/components/schemas/CompletedSingleAccountNotification" - } - ], - "discriminator": { - "propertyName": "status", - "mapping": { - "started": "#/components/schemas/StartedNotification", - "revoked": "#/components/schemas/RevokedNotification", - "failed": "#/components/schemas/FailedNotification", - "deployed": "#/components/schemas/DeployedNotification", - "completed": "#/components/schemas/CompletedNotification", - "completed_account": "#/components/schemas/CompletedSingleAccountNotification" + "alert": { + "$ref": "#/components/schemas/AlertCreate" } } }, - "OnboardingAWSAccounts": { + "QueryDetail": { + "title": "Query Detail", "type": "object", - "description": "AWS OpenID onboarding account structure", + "description": "Query Detail", "additionalProperties": false, "required": [ "id", - "type" + "name", + "query", + "created_at", + "alert_configured" ], "properties": { "id": { + "$ref": "#/components/schemas/QueryID" + }, + "name": { "type": "string", - "description": "ID of the account or OU", - "x-go-name": "ID" + "example": "Find all t2.micro EC2 instances" }, - "arn": { + "query": { + "$ref": "#/components/schemas/QueryExpression" + }, + "description": { "type": "string", - "description": "ARN of the account or OU", - "x-go-name": "ARN" + "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" }, - "type": { + "user_id": { + "$ref": "#/components/schemas/UserID" + }, + "tags": { + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryTag" + }, + "x-go-type-skip-optional-pointer": true + }, + "columns": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Columns returned by this query", + "x-go-type-skip-optional-pointer": true + }, + "created_at": { + "example": "2017-07-14T16:53:42Z", + "format": "date-time", + "type": "string" + }, + "alert_configured": { + "type": "boolean", + "description": "Indicates if the query has an alert configured. When this is set, the alert field will be populated with the alert details." + }, + "alert": { + "$ref": "#/components/schemas/AlertDetail" + }, + "view_name": { + "$ref": "#/components/schemas/QueryViewName" + } + } + }, + "AlertUpdate": { + "title": "Alert Update", + "description": "Alert Update Definition", + "type": "object", + "properties": { + "message": { "type": "string", - "description": "Type of the account", - "enum": [ - "OU", - "account", - "root" - ] + "example": "All resources need to be tagged" + }, + "severity": { + "$ref": "#/components/schemas/AlertSeverity" + }, + "enabled": { + "type": "boolean", + "description": "Indicates if the alert is enabled" }, + "notification_destinations": { + "type": "array", + "items": { + "$ref": "#/components/schemas/NotificationDestinationID" + }, + "description": "List of notification destinations to send alerts to", + "allowEmptyValue": true, + "explode": true + } + } + }, + "QueryUpdate": { + "title": "Query Update", + "type": "object", + "description": "Update a saved query", + "additionalProperties": false, + "properties": { "name": { "type": "string", - "description": "Display name of the account or OU" + "example": "Find all t2.micro EC2 instances" }, - "children": { + "query": { + "type": "string", + "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instances WHERE instance_type = 't2.micro'" + }, + "public": { + "type": "boolean" + }, + "tags": { "type": "array", - "description": "Children accounts and OUs of the target account", "items": { - "$ref": "#/components/schemas/OnboardingAWSAccounts" + "$ref": "#/components/schemas/QueryTag" } + }, + "description": { + "type": "string", + "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instances raw table" + }, + "view_name": { + "$ref": "#/components/schemas/QueryViewName" + }, + "alert": { + "$ref": "#/components/schemas/AlertUpdate" } } }, - "OrganizationalUnitID": { - "description": "ID of an organizational unit in AWS", - "type": "string", - "example": "ou-7f3s-j8zfa1ao", - "pattern": "^ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}$", - "x-pattern-message": "must start with \"ou-\" followed by 4 to 32 lowercase letters or digits, then a second \"-\" dash, and finally 8 to 32 additional lowercase letters or digits", - "x-go-name": "OrganizationalUnitID" - }, - "OnboardingAWSProvision": { + "FilterCreate": { + "title": "Filter definition for creating a filter", "type": "object", - "description": "Stackset provisioning configuration", + "description": "Saved filter", + "additionalProperties": false, "required": [ - "notify_url", - "organizational_units" + "name", + "expression" ], "properties": { - "notify_url": { + "name": { "type": "string", - "description": "URL that should be used for provisioning notifications (including scheme, hostname, and path)" + "example": "t2.micro EC2 instances" }, - "organizational_units": { - "type": "array", - "description": "OUs to provision roles into", - "items": { - "type": "string", - "pattern": "^(r-[0-9a-z]{4,32}|ou-[a-z0-9]{4,32}-[a-z0-9]{8,32})$", - "example": "r-xvfz", - "x-pattern-message": "must start with either \"r-\" followed by 4 to 32 lowercase letters or digits, or \"ou-\" followed by 4 to 32 lowercase letters or digits, a hyphen, and then 8 to 32 lowercase letters or digits, with no additional characters before or after." - } + "expression": { + "$ref": "#/components/schemas/FilterExpression" }, - "skip_accounts": { + "public": { + "type": "boolean", + "default": true, + "x-omitempty": false, + "x-go-type-skip-optional-pointer": true, + "description": "Whether the filter is visible to all users, or only to the user who created it" + }, + "tags": { "type": "array", - "description": "Account IDs to skip onboarding", "items": { - "description": "ID of an account in AWS", - "type": "string", - "example": "615713231484", - "pattern": "^\\d{12}$", - "x-pattern-message": "account ID must be exactly 12 digits" - } + "$ref": "#/components/schemas/FilterTag" + }, + "x-go-type-skip-optional-pointer": true + }, + "description": { + "type": "string", + "example": "Filter to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" } } }, - "QueryExpression": { - "title": "QueryExpression", + "InsightSeverity": { + "description": "Insight severity level", "type": "string", - "description": "Query expression", - "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" + "enum": [ + "Low", + "Medium", + "High", + "Critical" + ], + "x-go-name": "InsightSeverity" }, - "Alert": { - "title": "Alert", + "InsightID": { + "description": "Unique identifier for the insight", + "type": "string", + "x-go-name": "InsightID" + }, + "Insight": { + "title": "Insight", "type": "object", - "description": "An alert instance that can be triggered by a query", + "description": "Security or compliance insight summary", "additionalProperties": false, "required": [ "id", - "query_id", - "enabled", - "message", + "title", "severity", - "state", - "total_violations", + "insight_category", + "source", + "source_category", + "resource_types", + "resources_count", + "accounts_count", "created_at", - "updated_at", - "num_destinations" + "detected_at", + "last_synced_at" ], "properties": { "id": { - "type": "string", - "format": "uuid", - "description": "Unique identifier for the alert", - "x-go-name": "ID" + "$ref": "#/components/schemas/InsightID" }, - "query_id": { + "title": { "type": "string", - "format": "uuid", - "description": "Reference to the associated query", - "x-go-name": "QueryID" + "description": "Title of the insight" }, - "enabled": { - "type": "boolean", - "description": "Indicates if the alert is enabled" + "evidence": { + "type": "string", + "description": "Detailed evidence (description) of the insight (Markdown)" }, - "message": { + "mitigation": { "type": "string", - "description": "Alert message content" + "description": "Mitigation steps for the insight (Markdown)" }, "severity": { - "$ref": "#/components/schemas/AlertSeverity" + "$ref": "#/components/schemas/InsightSeverity" }, - "state": { - "$ref": "#/components/schemas/AlertState" + "insight_category": { + "type": "string", + "description": "Category (e.g. Security, Cost Optimization)" }, - "total_violations": { + "source": { + "type": "string", + "description": "Source (e.g. Platform, Wiz, Lacework)" + }, + "source_category": { + "type": "string", + "description": "Source category (e.g. Platform, Third Party, Custom)" + }, + "subcategory": { + "type": "string", + "nullable": true + }, + "resource_types": { + "type": "string", + "description": "Resource types affected" + }, + "resources_count": { "type": "integer", "format": "int64", - "description": "Number of violations that triggered the alert" + "description": "Number of resources affected" }, - "last_evaluated_at": { - "type": "string", - "format": "date-time", - "description": "Timestamp when the alert was last evaluated" + "accounts_count": { + "type": "integer", + "format": "int64", + "description": "Number of accounts affected" + }, + "tags": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Tags associated with the insight" }, - "triggered_at": { + "created_at": { "type": "string", "format": "date-time", - "description": "Timestamp when the alert was triggered" + "description": "When the insight record was created" }, - "created_at": { + "detected_at": { "type": "string", "format": "date-time", - "description": "Timestamp when the alert was created" + "description": "When the insight was first detected" }, - "updated_at": { + "last_synced_at": { "type": "string", "format": "date-time", - "description": "Timestamp when the alert was last updated" - }, - "num_destinations": { - "type": "integer", - "description": "Number of notification destinations this alert is configured to send to" + "description": "When the insight was last synced" } } }, - "QueryViewName": { - "description": "The name of the view the query is saved to in the warehouse", - "type": "string", - "pattern": "^(saved_query_view_[a-zA-Z0-9_]+|)$", - "x-pattern-message": "can contain only alphanumerical characters and underscores. must start with `saved_query_view_`" + "InsightsListMetadata": { + "required": [ + "page_size" + ], + "properties": { + "total_count": { + "type": "integer" + }, + "resource_count": { + "type": "integer" + }, + "resource_types": { + "type": "integer" + }, + "last_page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "time_ms": { + "type": "integer" + } + } }, - "Query": { - "title": "Query", + "PlatformInsightFilter": { + "title": "Insight Filter", "type": "object", - "description": "Saved query", + "description": "Saved insight filter details", "additionalProperties": false, "required": [ "id", "name", - "query", "created_at", - "alert_configured" + "updated_at" ], "properties": { "id": { - "$ref": "#/components/schemas/QueryID" + "type": "string", + "format": "uuid", + "example": "12345678-1234-1234-1234-1234567890ab" }, "name": { "type": "string", - "example": "Find all t2.micro EC2 instances" - }, - "query": { - "$ref": "#/components/schemas/QueryExpression" + "example": "My Saved Security Filter" }, "description": { "type": "string", - "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" + "example": "Filters for critical security insights in AWS" }, - "user_id": { - "$ref": "#/components/schemas/UserID" + "search": { + "type": "string", + "example": "s3 bucket" }, - "tags": { + "insight_category": { "type": "array", "items": { - "$ref": "#/components/schemas/QueryTag" + "type": "string" }, - "x-go-type-skip-optional-pointer": true - }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "example": [ + "Security", + "Compliance" + ] }, - "alert_configured": { - "type": "boolean", - "description": "Indicates if the query has an alert configured" + "severities": { + "type": "array", + "items": { + "$ref": "#/components/schemas/InsightSeverity" + }, + "example": [ + "Critical", + "High" + ] }, - "alert": { - "$ref": "#/components/schemas/Alert" + "resource_types": { + "type": "array", + "items": { + "type": "string" + }, + "example": [ + "aws_s3_bucket", + "aws_ec2_instance" + ] }, - "view_name": { - "$ref": "#/components/schemas/QueryViewName" - } - } - }, - "TableSelect": { - "title": "TableSelect", - "type": "string" - }, - "TableSortBy": { - "title": "TableSortBy", - "type": "string" - }, - "TableSortDirection": { - "title": "TableSortDirection", - "type": "string", - "enum": [ - "asc", - "desc" - ], - "default": "asc" - }, - "TableGroupBy": { - "title": "TableGroupBy", - "type": "string" - }, - "TableData": { - "additionalProperties": false, - "properties": { - "query": { - "$ref": "#/components/schemas/QueryExpression" + "source": { + "type": "array", + "items": { + "type": "string" + }, + "example": [ + "Platform", + "Wiz" + ] }, - "columns": { + "source_category": { "type": "array", "items": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "name", - "type" - ] - } + "type": "string" + }, + "example": [ + "Platform", + "Third Party" + ] }, - "rows": { + "clouds": { "type": "array", "items": { - "type": "array", - "items": {} - } - } - }, - "required": [ - "columns", - "rows" - ], - "title": "TableData", - "type": "object" - }, - "QueryCreate": { - "title": "Query Create", - "type": "object", - "description": "Create a saved query", - "additionalProperties": false, - "required": [ - "name", - "query" - ], - "properties": { - "name": { - "type": "string", - "example": "Find all t2.micro EC2 instances" + "type": "string" + }, + "example": [ + "aws", + "azure" + ] }, - "query": { - "type": "string", - "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instance WHERE instance_type = 't2.micro'" + "accounts": { + "type": "array", + "items": { + "type": "string" + }, + "example": [ + "prod-account", + "staging-account" + ] }, - "public": { - "type": "boolean", - "default": true, - "x-omitempty": false, - "x-go-type-skip-optional-pointer": true + "regions": { + "type": "array", + "items": { + "type": "string" + }, + "example": [ + "us-east-1", + "eu-west-1" + ] }, "tags": { "type": "array", "items": { - "$ref": "#/components/schemas/QueryTag" + "type": "string" }, - "x-go-type-skip-optional-pointer": true + "example": [ + "production", + "critical" + ] }, - "description": { - "type": "string", - "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" + "ownership_tags": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + }, + "description": "Ownership tag filters keyed by tag name", + "example": { + "team": [ + "engineering", + "platform" + ], + "org": [ + "cloud" + ] + } }, - "view_name": { - "$ref": "#/components/schemas/QueryViewName" + "group_by": { + "type": "array", + "items": { + "type": "string" + }, + "example": [ + "severity" + ] }, - "alert": { - "$ref": "#/components/schemas/AlertCreate" + "user_id": { + "$ref": "#/components/schemas/UserID" + }, + "created_at": { + "type": "string", + "format": "date-time", + "example": "2017-07-14T16:53:42Z" + }, + "updated_at": { + "type": "string", + "format": "date-time", + "example": "2017-07-14T16:53:42Z" } } }, - "QueryDetail": { - "title": "Query Detail", + "PlatformInsightFilterCreate": { + "title": "Insight Filter Create", "type": "object", - "description": "Query Detail", + "description": "Definition for creating a new saved insight filter", "additionalProperties": false, "required": [ - "id", - "name", - "query", - "created_at", - "alert_configured" + "name" ], "properties": { - "id": { - "$ref": "#/components/schemas/QueryID" - }, "name": { "type": "string", - "example": "Find all t2.micro EC2 instances" - }, - "query": { - "$ref": "#/components/schemas/QueryExpression" + "example": "My Saved Security Filter" }, "description": { "type": "string", - "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" + "example": "Filters for critical security insights in AWS" }, - "user_id": { - "$ref": "#/components/schemas/UserID" + "search": { + "type": "string", + "example": "s3 bucket" + }, + "insight_category": { + "type": "array", + "items": { + "type": "string" + } }, - "tags": { + "severities": { "type": "array", "items": { - "$ref": "#/components/schemas/QueryTag" - }, - "x-go-type-skip-optional-pointer": true + "$ref": "#/components/schemas/InsightSeverity" + } }, - "created_at": { - "example": "2017-07-14T16:53:42Z", - "format": "date-time", - "type": "string" + "resource_types": { + "type": "array", + "items": { + "type": "string" + } }, - "alert_configured": { - "type": "boolean", - "description": "Indicates if the query has an alert configured. When this is set, the alert field will be populated with the alert details." + "source": { + "type": "array", + "items": { + "type": "string" + } }, - "alert": { - "$ref": "#/components/schemas/AlertDetail" + "source_category": { + "type": "array", + "items": { + "type": "string" + } }, - "view_name": { - "$ref": "#/components/schemas/QueryViewName" - } - } - }, - "AlertUpdate": { - "title": "Alert Update", - "description": "Alert Update Definition", - "type": "object", - "properties": { - "message": { - "type": "string", - "example": "All resources need to be tagged" + "clouds": { + "type": "array", + "items": { + "type": "string" + } }, - "severity": { - "$ref": "#/components/schemas/AlertSeverity" + "accounts": { + "type": "array", + "items": { + "type": "string" + } }, - "enabled": { - "type": "boolean", - "description": "Indicates if the alert is enabled" + "regions": { + "type": "array", + "items": { + "type": "string" + } }, - "notification_destinations": { + "tags": { "type": "array", "items": { - "$ref": "#/components/schemas/NotificationDestinationID" + "type": "string" + } + }, + "ownership_tags": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } }, - "description": "List of notification destinations to send alerts to", - "allowEmptyValue": true, - "explode": true + "description": "Ownership tag filters keyed by tag name", + "example": { + "team": [ + "engineering", + "platform" + ], + "org": [ + "cloud" + ] + } + }, + "group_by": { + "type": "array", + "items": { + "type": "string" + } } } }, - "QueryUpdate": { - "title": "Query Update", + "PlatformInsightFilterID": { + "description": "The unique ID for the insight filter", + "type": "string", + "format": "uuid", + "x-go-name": "InsightFilterID" + }, + "PlatformInsightFilterUpdate": { + "title": "Insight Filter Update", "type": "object", - "description": "Update a saved query", + "description": "Definition for updating an existing saved insight filter", "additionalProperties": false, "properties": { "name": { - "type": "string", - "example": "Find all t2.micro EC2 instances" + "type": "string" }, - "query": { - "type": "string", - "example": "SELECT account_id, instance_id, instance_type, region, name, tags FROM aws_ec2_instances WHERE instance_type = 't2.micro'" + "description": { + "type": "string" }, - "public": { - "type": "boolean" + "search": { + "type": "string" }, - "tags": { + "insight_category": { "type": "array", "items": { - "$ref": "#/components/schemas/QueryTag" + "type": "string" } }, - "description": { - "type": "string", - "example": "Query to find all EC2 instances of type t2.micro from the aws_ec2_instances raw table" + "severities": { + "type": "array", + "items": { + "$ref": "#/components/schemas/InsightSeverity" + } }, - "view_name": { - "$ref": "#/components/schemas/QueryViewName" + "resource_types": { + "type": "array", + "items": { + "type": "string" + } }, - "alert": { - "$ref": "#/components/schemas/AlertUpdate" - } - } - }, - "FilterCreate": { - "title": "Filter definition for creating a filter", - "type": "object", - "description": "Saved filter", - "additionalProperties": false, - "required": [ - "name", - "expression" - ], - "properties": { - "name": { - "type": "string", - "example": "t2.micro EC2 instances" + "source": { + "type": "array", + "items": { + "type": "string" + } }, - "expression": { - "$ref": "#/components/schemas/FilterExpression" + "source_category": { + "type": "array", + "items": { + "type": "string" + } }, - "public": { - "type": "boolean", - "default": true, - "x-omitempty": false, - "x-go-type-skip-optional-pointer": true, - "description": "Whether the filter is visible to all users, or only to the user who created it" + "clouds": { + "type": "array", + "items": { + "type": "string" + } + }, + "accounts": { + "type": "array", + "items": { + "type": "string" + } + }, + "regions": { + "type": "array", + "items": { + "type": "string" + } }, "tags": { "type": "array", "items": { - "$ref": "#/components/schemas/FilterTag" + "type": "string" + } + }, + "ownership_tags": { + "type": "object", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } }, - "x-go-type-skip-optional-pointer": true + "description": "Ownership tag filters keyed by tag name", + "example": { + "team": [ + "engineering", + "platform" + ], + "org": [ + "cloud" + ] + } }, - "description": { - "type": "string", - "example": "Filter to find all EC2 instances of type t2.micro from the aws_ec2_instance raw table" + "group_by": { + "type": "array", + "items": { + "type": "string" + } } } }, + "TableRowID": { + "description": "ID of the Resource", + "type": "string", + "example": "table_12345678-1234-1234-1234-1234567890ab" + }, "ReportSortBy": { "title": "ReportSortBy", "type": "string", @@ -16498,8 +18551,7 @@ "title": "Sync Integration Test Connection creation definition", "type": "object", "required": [ - "path", - "version" + "path" ], "properties": { "path": { @@ -17525,18 +19577,18 @@ "description": "Sync with its associated tables", "type": "object", "required": [ - "sync_name", + "source_name", "tables" ], "properties": { - "sync_name": { + "source_name": { "type": "string", - "description": "The unique name of the sync (source_name from synced_tables)", + "description": "The unique name of the source (source_name from synced_tables)", "example": "aws-integration" }, "display_name": { "type": "string", - "description": "Human-readable display name of the sync", + "description": "Human-readable display name of the source", "example": "AWS Integration" }, "plugin": { @@ -17576,7 +19628,7 @@ } }, "example": { - "sync_name": "aws-integration", + "source_name": "aws-integration", "display_name": "AWS Integration", "plugin": "cloudquery/aws", "tables": [ @@ -17600,7 +19652,7 @@ "type": "object", "required": [ "action", - "syncs" + "sources" ], "properties": { "action": { @@ -17610,9 +19662,9 @@ ], "description": "The action to perform on the table data" }, - "syncs": { + "sources": { "type": "object", - "description": "Map of sync names to arrays of table names", + "description": "Map of source names to arrays of table names", "additionalProperties": { "type": "array", "items": { @@ -17624,22 +19676,17 @@ }, "example": { "action": "delete", - "syncs": { - "sync_name_1": [ + "sources": { + "source_name_1": [ "table_1", "table_2" ], - "sync_name_2": [ + "source_name_2": [ "table_3" ] } } }, - "TableRowID": { - "description": "ID of the Resource", - "type": "string", - "example": "table_12345678-1234-1234-1234-1234567890ab" - }, "TableRow": { "additionalProperties": true, "title": "TableRow", @@ -17740,6 +19787,61 @@ "title": "TableSchema", "type": "array" }, + "RelationColumnDef": { + "type": "object", + "required": [ + "field", + "label" + ], + "properties": { + "field": { + "type": "string", + "description": "Column field name in the query result." + }, + "label": { + "type": "string", + "description": "Display label for the column." + }, + "type": { + "type": "string", + "description": "Column render type (e.g. text, tags, boolean, json, code)." + }, + "hidden": { + "type": "boolean", + "description": "Whether the column is present for navigation but not displayed." + } + } + }, + "RelationDef": { + "type": "object", + "required": [ + "title", + "resource_type", + "columns", + "sql_query" + ], + "properties": { + "title": { + "type": "string", + "description": "Display title for the relation tab/section." + }, + "resource_type": { + "type": "string", + "description": "Target CloudQuery table name." + }, + "columns": { + "type": "array", + "items": { + "$ref": "#/components/schemas/RelationColumnDef" + }, + "description": "Column definitions for the relation view." + }, + "sql_query": { + "type": "string", + "description": "ClickHouse SQL template with {{field_name}} placeholders." + } + } + }, "BatchTableSchemaItem": { "title": "BatchTableSchemaItem", "type": "object", @@ -18066,6 +20168,24 @@ "can_enable": { "type": "boolean", "description": "Whether SAML can be enabled" + }, + "certificate_fingerprint": { + "type": "string", + "description": "Fingerprint of the current SAML certificate" + }, + "certificate_expires_at": { + "type": "string", + "format": "date-time", + "description": "Expiration time of the current SAML certificate" + }, + "rollover_certificate_fingerprint": { + "type": "string", + "description": "Fingerprint of the SAML certificate that will be used after rollover" + }, + "rollover_certificate_expires_at": { + "type": "string", + "format": "date-time", + "description": "Expiration time of the SAML certificate that will be used after rollover" } } }, @@ -18182,8 +20302,7 @@ "title": "Sync Destination Test Connection creation definition", "type": "object", "required": [ - "path", - "version" + "path" ], "properties": { "path": { @@ -18571,6 +20690,16 @@ } }, "description": "Method not allowed" + }, + "Conflict": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/FieldError" + } + } + }, + "description": "Conflict" } } }