From 56215e94e1641b4cfca7dca937033c93929d7095 Mon Sep 17 00:00:00 2001 From: svix-lucho Date: Wed, 7 Aug 2024 17:46:03 -0300 Subject: [PATCH] Update OpenAPI spec and regenerate libs --- .../openapi/model_event_type_from_open_api.go | 31 +++++++++++++- go/internal/openapi/model_event_type_in.go | 40 +++++++++++++++++++ go/internal/openapi/model_event_type_out.go | 31 +++++++++++++- go/internal/openapi/model_event_type_patch.go | 36 +++++++++++++++++ .../openapi/model_event_type_update.go | 40 +++++++++++++++++++ openapi.json | 19 +++++++++ 6 files changed, 195 insertions(+), 2 deletions(-) diff --git a/go/internal/openapi/model_event_type_from_open_api.go b/go/internal/openapi/model_event_type_from_open_api.go index 358e5948f..6aee51cd1 100644 --- a/go/internal/openapi/model_event_type_from_open_api.go +++ b/go/internal/openapi/model_event_type_from_open_api.go @@ -16,6 +16,7 @@ import ( // EventTypeFromOpenApi struct for EventTypeFromOpenApi type EventTypeFromOpenApi struct { + Deprecated bool `json:"deprecated"` Description string `json:"description"` // The event type's name Name string `json:"name"` @@ -26,8 +27,9 @@ type EventTypeFromOpenApi struct { // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewEventTypeFromOpenApi(description string, name string) *EventTypeFromOpenApi { +func NewEventTypeFromOpenApi(deprecated bool, description string, name string) *EventTypeFromOpenApi { this := EventTypeFromOpenApi{} + this.Deprecated = deprecated this.Description = description this.Name = name return &this @@ -41,6 +43,30 @@ func NewEventTypeFromOpenApiWithDefaults() *EventTypeFromOpenApi { return &this } +// GetDeprecated returns the Deprecated field value +func (o *EventTypeFromOpenApi) GetDeprecated() bool { + if o == nil { + var ret bool + return ret + } + + return o.Deprecated +} + +// GetDeprecatedOk returns a tuple with the Deprecated field value +// and a boolean to check if the value has been set. +func (o *EventTypeFromOpenApi) GetDeprecatedOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.Deprecated, true +} + +// SetDeprecated sets field value +func (o *EventTypeFromOpenApi) SetDeprecated(v bool) { + o.Deprecated = v +} + // GetDescription returns the Description field value func (o *EventTypeFromOpenApi) GetDescription() string { if o == nil { @@ -124,6 +150,9 @@ func (o *EventTypeFromOpenApi) SetSchemas(v map[string]map[string]interface{}) { func (o EventTypeFromOpenApi) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} + if true { + toSerialize["deprecated"] = o.Deprecated + } if true { toSerialize["description"] = o.Description } diff --git a/go/internal/openapi/model_event_type_in.go b/go/internal/openapi/model_event_type_in.go index 60d13bdc2..c6bc9f3bc 100644 --- a/go/internal/openapi/model_event_type_in.go +++ b/go/internal/openapi/model_event_type_in.go @@ -17,6 +17,7 @@ import ( // EventTypeIn struct for EventTypeIn type EventTypeIn struct { Archived *bool `json:"archived,omitempty"` + Deprecated *bool `json:"deprecated,omitempty"` Description string `json:"description"` FeatureFlag NullableString `json:"featureFlag,omitempty"` // The event type group's name @@ -35,6 +36,8 @@ func NewEventTypeIn(description string, name string) *EventTypeIn { this := EventTypeIn{} var archived bool = false this.Archived = &archived + var deprecated bool = false + this.Deprecated = &deprecated this.Description = description this.Name = name return &this @@ -47,6 +50,8 @@ func NewEventTypeInWithDefaults() *EventTypeIn { this := EventTypeIn{} var archived bool = false this.Archived = &archived + var deprecated bool = false + this.Deprecated = &deprecated return &this } @@ -82,6 +87,38 @@ func (o *EventTypeIn) SetArchived(v bool) { o.Archived = &v } +// GetDeprecated returns the Deprecated field value if set, zero value otherwise. +func (o *EventTypeIn) GetDeprecated() bool { + if o == nil || o.Deprecated == nil { + var ret bool + return ret + } + return *o.Deprecated +} + +// GetDeprecatedOk returns a tuple with the Deprecated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *EventTypeIn) GetDeprecatedOk() (*bool, bool) { + if o == nil || o.Deprecated == nil { + return nil, false + } + return o.Deprecated, true +} + +// HasDeprecated returns a boolean if a field has been set. +func (o *EventTypeIn) HasDeprecated() bool { + if o != nil && o.Deprecated != nil { + return true + } + + return false +} + +// SetDeprecated gets a reference to the given bool and assigns it to the Deprecated field. +func (o *EventTypeIn) SetDeprecated(v bool) { + o.Deprecated = &v +} + // GetDescription returns the Description field value func (o *EventTypeIn) GetDescription() string { if o == nil { @@ -252,6 +289,9 @@ func (o EventTypeIn) MarshalJSON() ([]byte, error) { if o.Archived != nil { toSerialize["archived"] = o.Archived } + if o.Deprecated != nil { + toSerialize["deprecated"] = o.Deprecated + } if true { toSerialize["description"] = o.Description } diff --git a/go/internal/openapi/model_event_type_out.go b/go/internal/openapi/model_event_type_out.go index c15c5d625..1e8fd1af8 100644 --- a/go/internal/openapi/model_event_type_out.go +++ b/go/internal/openapi/model_event_type_out.go @@ -19,6 +19,7 @@ import ( type EventTypeOut struct { Archived *bool `json:"archived,omitempty"` CreatedAt time.Time `json:"createdAt"` + Deprecated bool `json:"deprecated"` Description string `json:"description"` FeatureFlag NullableString `json:"featureFlag,omitempty"` // The event type group's name @@ -34,11 +35,12 @@ type EventTypeOut struct { // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewEventTypeOut(createdAt time.Time, description string, name string, updatedAt time.Time) *EventTypeOut { +func NewEventTypeOut(createdAt time.Time, deprecated bool, description string, name string, updatedAt time.Time) *EventTypeOut { this := EventTypeOut{} var archived bool = false this.Archived = &archived this.CreatedAt = createdAt + this.Deprecated = deprecated this.Description = description this.Name = name this.UpdatedAt = updatedAt @@ -111,6 +113,30 @@ func (o *EventTypeOut) SetCreatedAt(v time.Time) { o.CreatedAt = v } +// GetDeprecated returns the Deprecated field value +func (o *EventTypeOut) GetDeprecated() bool { + if o == nil { + var ret bool + return ret + } + + return o.Deprecated +} + +// GetDeprecatedOk returns a tuple with the Deprecated field value +// and a boolean to check if the value has been set. +func (o *EventTypeOut) GetDeprecatedOk() (*bool, bool) { + if o == nil { + return nil, false + } + return &o.Deprecated, true +} + +// SetDeprecated sets field value +func (o *EventTypeOut) SetDeprecated(v bool) { + o.Deprecated = v +} + // GetDescription returns the Description field value func (o *EventTypeOut) GetDescription() string { if o == nil { @@ -308,6 +334,9 @@ func (o EventTypeOut) MarshalJSON() ([]byte, error) { if true { toSerialize["createdAt"] = o.CreatedAt } + if true { + toSerialize["deprecated"] = o.Deprecated + } if true { toSerialize["description"] = o.Description } diff --git a/go/internal/openapi/model_event_type_patch.go b/go/internal/openapi/model_event_type_patch.go index 476dfbf39..f35941aab 100644 --- a/go/internal/openapi/model_event_type_patch.go +++ b/go/internal/openapi/model_event_type_patch.go @@ -17,6 +17,7 @@ import ( // EventTypePatch struct for EventTypePatch type EventTypePatch struct { Archived *bool `json:"archived,omitempty"` + Deprecated *bool `json:"deprecated,omitempty"` Description *string `json:"description,omitempty"` FeatureFlag NullableString `json:"featureFlag,omitempty"` // The event type group's name @@ -73,6 +74,38 @@ func (o *EventTypePatch) SetArchived(v bool) { o.Archived = &v } +// GetDeprecated returns the Deprecated field value if set, zero value otherwise. +func (o *EventTypePatch) GetDeprecated() bool { + if o == nil || o.Deprecated == nil { + var ret bool + return ret + } + return *o.Deprecated +} + +// GetDeprecatedOk returns a tuple with the Deprecated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *EventTypePatch) GetDeprecatedOk() (*bool, bool) { + if o == nil || o.Deprecated == nil { + return nil, false + } + return o.Deprecated, true +} + +// HasDeprecated returns a boolean if a field has been set. +func (o *EventTypePatch) HasDeprecated() bool { + if o != nil && o.Deprecated != nil { + return true + } + + return false +} + +// SetDeprecated gets a reference to the given bool and assigns it to the Deprecated field. +func (o *EventTypePatch) SetDeprecated(v bool) { + o.Deprecated = &v +} + // GetDescription returns the Description field value if set, zero value otherwise. func (o *EventTypePatch) GetDescription() string { if o == nil || o.Description == nil { @@ -227,6 +260,9 @@ func (o EventTypePatch) MarshalJSON() ([]byte, error) { if o.Archived != nil { toSerialize["archived"] = o.Archived } + if o.Deprecated != nil { + toSerialize["deprecated"] = o.Deprecated + } if o.Description != nil { toSerialize["description"] = o.Description } diff --git a/go/internal/openapi/model_event_type_update.go b/go/internal/openapi/model_event_type_update.go index ba6e1141f..9ece0ec95 100644 --- a/go/internal/openapi/model_event_type_update.go +++ b/go/internal/openapi/model_event_type_update.go @@ -17,6 +17,7 @@ import ( // EventTypeUpdate struct for EventTypeUpdate type EventTypeUpdate struct { Archived *bool `json:"archived,omitempty"` + Deprecated *bool `json:"deprecated,omitempty"` Description string `json:"description"` FeatureFlag NullableString `json:"featureFlag,omitempty"` // The event type group's name @@ -33,6 +34,8 @@ func NewEventTypeUpdate(description string) *EventTypeUpdate { this := EventTypeUpdate{} var archived bool = false this.Archived = &archived + var deprecated bool = false + this.Deprecated = &deprecated this.Description = description return &this } @@ -44,6 +47,8 @@ func NewEventTypeUpdateWithDefaults() *EventTypeUpdate { this := EventTypeUpdate{} var archived bool = false this.Archived = &archived + var deprecated bool = false + this.Deprecated = &deprecated return &this } @@ -79,6 +84,38 @@ func (o *EventTypeUpdate) SetArchived(v bool) { o.Archived = &v } +// GetDeprecated returns the Deprecated field value if set, zero value otherwise. +func (o *EventTypeUpdate) GetDeprecated() bool { + if o == nil || o.Deprecated == nil { + var ret bool + return ret + } + return *o.Deprecated +} + +// GetDeprecatedOk returns a tuple with the Deprecated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *EventTypeUpdate) GetDeprecatedOk() (*bool, bool) { + if o == nil || o.Deprecated == nil { + return nil, false + } + return o.Deprecated, true +} + +// HasDeprecated returns a boolean if a field has been set. +func (o *EventTypeUpdate) HasDeprecated() bool { + if o != nil && o.Deprecated != nil { + return true + } + + return false +} + +// SetDeprecated gets a reference to the given bool and assigns it to the Deprecated field. +func (o *EventTypeUpdate) SetDeprecated(v bool) { + o.Deprecated = &v +} + // GetDescription returns the Description field value func (o *EventTypeUpdate) GetDescription() string { if o == nil { @@ -225,6 +262,9 @@ func (o EventTypeUpdate) MarshalJSON() ([]byte, error) { if o.Archived != nil { toSerialize["archived"] = o.Archived } + if o.Deprecated != nil { + toSerialize["deprecated"] = o.Deprecated + } if true { toSerialize["description"] = o.Description } diff --git a/openapi.json b/openapi.json index 4eedfca1d..580cb4abc 100644 --- a/openapi.json +++ b/openapi.json @@ -1817,6 +1817,9 @@ }, "EventTypeFromOpenApi": { "properties": { + "deprecated": { + "type": "boolean" + }, "description": { "type": "string" }, @@ -1855,6 +1858,7 @@ } }, "required": [ + "deprecated", "description", "name" ], @@ -2013,6 +2017,10 @@ "example": false, "type": "boolean" }, + "deprecated": { + "default": false, + "type": "boolean" + }, "description": { "example": "A user has signed up", "type": "string" @@ -2086,6 +2094,9 @@ "format": "date-time", "type": "string" }, + "deprecated": { + "type": "boolean" + }, "description": { "example": "A user has signed up", "type": "string" @@ -2148,6 +2159,7 @@ }, "required": [ "createdAt", + "deprecated", "description", "name", "updatedAt" @@ -2159,6 +2171,9 @@ "archived": { "type": "boolean" }, + "deprecated": { + "type": "boolean" + }, "description": { "type": "string" }, @@ -2243,6 +2258,10 @@ "example": false, "type": "boolean" }, + "deprecated": { + "default": false, + "type": "boolean" + }, "description": { "example": "A user has signed up", "type": "string"