From 0e58e0946110ac08210612f8c584c8852e8882b5 Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Wed, 12 Jul 2023 18:18:22 +0000 Subject: [PATCH] Regenerate client from commit 6da63bde of spec repo --- .apigentools-info | 8 +- .generator/schemas/v2/openapi.yaml | 16 ++ ...workload_security_agent_rule_attributes.go | 164 ++++++++++++++++-- 3 files changed, 172 insertions(+), 16 deletions(-) diff --git a/.apigentools-info b/.apigentools-info index 3bf30c24b7b..2f3038064f3 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.6.5", - "regenerated": "2023-07-11 16:39:35.936049", - "spec_repo_commit": "824086bb" + "regenerated": "2023-07-12 18:16:56.996946", + "spec_repo_commit": "6da63bde" }, "v2": { "apigentools_version": "1.6.5", - "regenerated": "2023-07-11 16:39:35.952370", - "spec_repo_commit": "824086bb" + "regenerated": "2023-07-12 18:16:57.011787", + "spec_repo_commit": "6da63bde" } } } \ No newline at end of file diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 0193b8aeaa8..8288ef9f7eb 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -2756,10 +2756,17 @@ components: CloudWorkloadSecurityAgentRuleAttributes: description: A Cloud Workload Security Agent rule returned by the API. properties: + agentConstraint: + description: The version of the agent. + type: string category: description: The category of the Agent rule. example: Process Activity type: string + creationAuthorUuId: + description: The ID of the user who created the rule. + example: e51c9744-d158-11ec-ad23-da7ad0900002 + type: string creationDate: description: When the Agent rule was created, timestamp in milliseconds. example: 1624366480320 @@ -2787,6 +2794,15 @@ components: description: The name of the Agent rule. example: my_agent_rule type: string + updateAuthorUuId: + description: The ID of the user who updated the rule. + example: e51c9744-d158-11ec-ad23-da7ad0900002 + type: string + updateDate: + description: When the Agent rule was last updated, timestamp in milliseconds. + example: 1624366480320 + format: int64 + type: integer updatedAt: description: When the Agent rule was last updated, timestamp in milliseconds. example: 1624366480320 diff --git a/api/datadogV2/model_cloud_workload_security_agent_rule_attributes.go b/api/datadogV2/model_cloud_workload_security_agent_rule_attributes.go index f9613d4e933..f87cd97c1d5 100644 --- a/api/datadogV2/model_cloud_workload_security_agent_rule_attributes.go +++ b/api/datadogV2/model_cloud_workload_security_agent_rule_attributes.go @@ -12,8 +12,12 @@ import ( // CloudWorkloadSecurityAgentRuleAttributes A Cloud Workload Security Agent rule returned by the API. type CloudWorkloadSecurityAgentRuleAttributes struct { + // The version of the agent. + AgentConstraint *string `json:"agentConstraint,omitempty"` // The category of the Agent rule. Category *string `json:"category,omitempty"` + // The ID of the user who created the rule. + CreationAuthorUuId *string `json:"creationAuthorUuId,omitempty"` // When the Agent rule was created, timestamp in milliseconds. CreationDate *int64 `json:"creationDate,omitempty"` // The attributes of the user who created the Agent rule. @@ -28,6 +32,10 @@ type CloudWorkloadSecurityAgentRuleAttributes struct { Expression *string `json:"expression,omitempty"` // The name of the Agent rule. Name *string `json:"name,omitempty"` + // The ID of the user who updated the rule. + UpdateAuthorUuId *string `json:"updateAuthorUuId,omitempty"` + // When the Agent rule was last updated, timestamp in milliseconds. + UpdateDate *int64 `json:"updateDate,omitempty"` // When the Agent rule was last updated, timestamp in milliseconds. UpdatedAt *int64 `json:"updatedAt,omitempty"` // The attributes of the user who last updated the Agent rule. @@ -56,6 +64,34 @@ func NewCloudWorkloadSecurityAgentRuleAttributesWithDefaults() *CloudWorkloadSec return &this } +// GetAgentConstraint returns the AgentConstraint field value if set, zero value otherwise. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetAgentConstraint() string { + if o == nil || o.AgentConstraint == nil { + var ret string + return ret + } + return *o.AgentConstraint +} + +// GetAgentConstraintOk returns a tuple with the AgentConstraint field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetAgentConstraintOk() (*string, bool) { + if o == nil || o.AgentConstraint == nil { + return nil, false + } + return o.AgentConstraint, true +} + +// HasAgentConstraint returns a boolean if a field has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) HasAgentConstraint() bool { + return o != nil && o.AgentConstraint != nil +} + +// SetAgentConstraint gets a reference to the given string and assigns it to the AgentConstraint field. +func (o *CloudWorkloadSecurityAgentRuleAttributes) SetAgentConstraint(v string) { + o.AgentConstraint = &v +} + // GetCategory returns the Category field value if set, zero value otherwise. func (o *CloudWorkloadSecurityAgentRuleAttributes) GetCategory() string { if o == nil || o.Category == nil { @@ -84,6 +120,34 @@ func (o *CloudWorkloadSecurityAgentRuleAttributes) SetCategory(v string) { o.Category = &v } +// GetCreationAuthorUuId returns the CreationAuthorUuId field value if set, zero value otherwise. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetCreationAuthorUuId() string { + if o == nil || o.CreationAuthorUuId == nil { + var ret string + return ret + } + return *o.CreationAuthorUuId +} + +// GetCreationAuthorUuIdOk returns a tuple with the CreationAuthorUuId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetCreationAuthorUuIdOk() (*string, bool) { + if o == nil || o.CreationAuthorUuId == nil { + return nil, false + } + return o.CreationAuthorUuId, true +} + +// HasCreationAuthorUuId returns a boolean if a field has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) HasCreationAuthorUuId() bool { + return o != nil && o.CreationAuthorUuId != nil +} + +// SetCreationAuthorUuId gets a reference to the given string and assigns it to the CreationAuthorUuId field. +func (o *CloudWorkloadSecurityAgentRuleAttributes) SetCreationAuthorUuId(v string) { + o.CreationAuthorUuId = &v +} + // GetCreationDate returns the CreationDate field value if set, zero value otherwise. func (o *CloudWorkloadSecurityAgentRuleAttributes) GetCreationDate() int64 { if o == nil || o.CreationDate == nil { @@ -280,6 +344,62 @@ func (o *CloudWorkloadSecurityAgentRuleAttributes) SetName(v string) { o.Name = &v } +// GetUpdateAuthorUuId returns the UpdateAuthorUuId field value if set, zero value otherwise. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetUpdateAuthorUuId() string { + if o == nil || o.UpdateAuthorUuId == nil { + var ret string + return ret + } + return *o.UpdateAuthorUuId +} + +// GetUpdateAuthorUuIdOk returns a tuple with the UpdateAuthorUuId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetUpdateAuthorUuIdOk() (*string, bool) { + if o == nil || o.UpdateAuthorUuId == nil { + return nil, false + } + return o.UpdateAuthorUuId, true +} + +// HasUpdateAuthorUuId returns a boolean if a field has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) HasUpdateAuthorUuId() bool { + return o != nil && o.UpdateAuthorUuId != nil +} + +// SetUpdateAuthorUuId gets a reference to the given string and assigns it to the UpdateAuthorUuId field. +func (o *CloudWorkloadSecurityAgentRuleAttributes) SetUpdateAuthorUuId(v string) { + o.UpdateAuthorUuId = &v +} + +// GetUpdateDate returns the UpdateDate field value if set, zero value otherwise. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetUpdateDate() int64 { + if o == nil || o.UpdateDate == nil { + var ret int64 + return ret + } + return *o.UpdateDate +} + +// GetUpdateDateOk returns a tuple with the UpdateDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) GetUpdateDateOk() (*int64, bool) { + if o == nil || o.UpdateDate == nil { + return nil, false + } + return o.UpdateDate, true +} + +// HasUpdateDate returns a boolean if a field has been set. +func (o *CloudWorkloadSecurityAgentRuleAttributes) HasUpdateDate() bool { + return o != nil && o.UpdateDate != nil +} + +// SetUpdateDate gets a reference to the given int64 and assigns it to the UpdateDate field. +func (o *CloudWorkloadSecurityAgentRuleAttributes) SetUpdateDate(v int64) { + o.UpdateDate = &v +} + // GetUpdatedAt returns the UpdatedAt field value if set, zero value otherwise. func (o *CloudWorkloadSecurityAgentRuleAttributes) GetUpdatedAt() int64 { if o == nil || o.UpdatedAt == nil { @@ -370,9 +490,15 @@ func (o CloudWorkloadSecurityAgentRuleAttributes) MarshalJSON() ([]byte, error) if o.UnparsedObject != nil { return json.Marshal(o.UnparsedObject) } + if o.AgentConstraint != nil { + toSerialize["agentConstraint"] = o.AgentConstraint + } if o.Category != nil { toSerialize["category"] = o.Category } + if o.CreationAuthorUuId != nil { + toSerialize["creationAuthorUuId"] = o.CreationAuthorUuId + } if o.CreationDate != nil { toSerialize["creationDate"] = o.CreationDate } @@ -394,6 +520,12 @@ func (o CloudWorkloadSecurityAgentRuleAttributes) MarshalJSON() ([]byte, error) if o.Name != nil { toSerialize["name"] = o.Name } + if o.UpdateAuthorUuId != nil { + toSerialize["updateAuthorUuId"] = o.UpdateAuthorUuId + } + if o.UpdateDate != nil { + toSerialize["updateDate"] = o.UpdateDate + } if o.UpdatedAt != nil { toSerialize["updatedAt"] = o.UpdatedAt } @@ -414,17 +546,21 @@ func (o CloudWorkloadSecurityAgentRuleAttributes) MarshalJSON() ([]byte, error) func (o *CloudWorkloadSecurityAgentRuleAttributes) UnmarshalJSON(bytes []byte) (err error) { raw := map[string]interface{}{} all := struct { - Category *string `json:"category,omitempty"` - CreationDate *int64 `json:"creationDate,omitempty"` - Creator *CloudWorkloadSecurityAgentRuleCreatorAttributes `json:"creator,omitempty"` - DefaultRule *bool `json:"defaultRule,omitempty"` - Description *string `json:"description,omitempty"` - Enabled *bool `json:"enabled,omitempty"` - Expression *string `json:"expression,omitempty"` - Name *string `json:"name,omitempty"` - UpdatedAt *int64 `json:"updatedAt,omitempty"` - Updater *CloudWorkloadSecurityAgentRuleUpdaterAttributes `json:"updater,omitempty"` - Version *int64 `json:"version,omitempty"` + AgentConstraint *string `json:"agentConstraint,omitempty"` + Category *string `json:"category,omitempty"` + CreationAuthorUuId *string `json:"creationAuthorUuId,omitempty"` + CreationDate *int64 `json:"creationDate,omitempty"` + Creator *CloudWorkloadSecurityAgentRuleCreatorAttributes `json:"creator,omitempty"` + DefaultRule *bool `json:"defaultRule,omitempty"` + Description *string `json:"description,omitempty"` + Enabled *bool `json:"enabled,omitempty"` + Expression *string `json:"expression,omitempty"` + Name *string `json:"name,omitempty"` + UpdateAuthorUuId *string `json:"updateAuthorUuId,omitempty"` + UpdateDate *int64 `json:"updateDate,omitempty"` + UpdatedAt *int64 `json:"updatedAt,omitempty"` + Updater *CloudWorkloadSecurityAgentRuleUpdaterAttributes `json:"updater,omitempty"` + Version *int64 `json:"version,omitempty"` }{} if err = json.Unmarshal(bytes, &all); err != nil { err = json.Unmarshal(bytes, &raw) @@ -436,11 +572,13 @@ func (o *CloudWorkloadSecurityAgentRuleAttributes) UnmarshalJSON(bytes []byte) ( } additionalProperties := make(map[string]interface{}) if err = json.Unmarshal(bytes, &additionalProperties); err == nil { - datadog.DeleteKeys(additionalProperties, &[]string{"category", "creationDate", "creator", "defaultRule", "description", "enabled", "expression", "name", "updatedAt", "updater", "version"}) + datadog.DeleteKeys(additionalProperties, &[]string{"agentConstraint", "category", "creationAuthorUuId", "creationDate", "creator", "defaultRule", "description", "enabled", "expression", "name", "updateAuthorUuId", "updateDate", "updatedAt", "updater", "version"}) } else { return err } + o.AgentConstraint = all.AgentConstraint o.Category = all.Category + o.CreationAuthorUuId = all.CreationAuthorUuId o.CreationDate = all.CreationDate if all.Creator != nil && all.Creator.UnparsedObject != nil && o.UnparsedObject == nil { err = json.Unmarshal(bytes, &raw) @@ -455,6 +593,8 @@ func (o *CloudWorkloadSecurityAgentRuleAttributes) UnmarshalJSON(bytes []byte) ( o.Enabled = all.Enabled o.Expression = all.Expression o.Name = all.Name + o.UpdateAuthorUuId = all.UpdateAuthorUuId + o.UpdateDate = all.UpdateDate o.UpdatedAt = all.UpdatedAt if all.Updater != nil && all.Updater.UnparsedObject != nil && o.UnparsedObject == nil { err = json.Unmarshal(bytes, &raw)