// Code generated by Fern. DO NOT EDIT.

package management

import (
	json "encoding/json"
	fmt "fmt"
	internal "github.com/auth0/go-auth0/v2/management/internal"
	big "math/big"
)

var (
	createLogStreamDatadogRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamDatadogRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamDatadogRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamDatadogRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamDatadogRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamDatadogRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamDatadogRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamDatadogRequestBody struct {
	// log stream name
	Name *string              `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamDatadogEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter    `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig   `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamDatadogSink `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamDatadogRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamDatadogRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamDatadogRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamDatadogRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamDatadogRequestBody) GetSink() *LogStreamDatadogSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamDatadogRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamDatadogRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamDatadogRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamDatadogRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetType(type_ LogStreamDatadogEnum) {
	c.Type = type_
	c.require(createLogStreamDatadogRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamDatadogRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamDatadogRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamDatadogRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetSink(sink *LogStreamDatadogSink) {
	c.Sink = sink
	c.require(createLogStreamDatadogRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamDatadogRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamDatadogRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamDatadogRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamDatadogRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamDatadogRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamDatadogRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamDatadogRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamDatadogRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamEventBridgeRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamEventBridgeRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamEventBridgeRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamEventBridgeRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamEventBridgeRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamEventBridgeRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamEventBridgeRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamEventBridgeRequestBody struct {
	// log stream name
	Name *string                  `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamEventBridgeEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter        `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig       `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamEventBridgeSink `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamEventBridgeRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamEventBridgeRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamEventBridgeRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamEventBridgeRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamEventBridgeRequestBody) GetSink() *LogStreamEventBridgeSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamEventBridgeRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamEventBridgeRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamEventBridgeRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamEventBridgeRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetType(type_ LogStreamEventBridgeEnum) {
	c.Type = type_
	c.require(createLogStreamEventBridgeRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamEventBridgeRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamEventBridgeRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamEventBridgeRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetSink(sink *LogStreamEventBridgeSink) {
	c.Sink = sink
	c.require(createLogStreamEventBridgeRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventBridgeRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamEventBridgeRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamEventBridgeRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamEventBridgeRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamEventBridgeRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamEventBridgeRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamEventBridgeRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamEventBridgeRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamEventGridRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamEventGridRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamEventGridRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamEventGridRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamEventGridRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamEventGridRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamEventGridRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamEventGridRequestBody struct {
	// log stream name
	Name *string                `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamEventGridEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter      `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig     `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamEventGridSink `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamEventGridRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamEventGridRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamEventGridRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamEventGridRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamEventGridRequestBody) GetSink() *LogStreamEventGridSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamEventGridRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamEventGridRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamEventGridRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamEventGridRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetType(type_ LogStreamEventGridEnum) {
	c.Type = type_
	c.require(createLogStreamEventGridRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamEventGridRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamEventGridRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamEventGridRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetSink(sink *LogStreamEventGridSink) {
	c.Sink = sink
	c.require(createLogStreamEventGridRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamEventGridRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamEventGridRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamEventGridRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamEventGridRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamEventGridRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamEventGridRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamEventGridRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamEventGridRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamHTTPRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamHTTPRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamHTTPRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamHTTPRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamHTTPRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamHTTPRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamHTTPRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamHTTPRequestBody struct {
	// log stream name
	Name *string           `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamHTTPEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter  `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamHTTPSink  `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamHTTPRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamHTTPRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamHTTPRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamHTTPRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamHTTPRequestBody) GetSink() *LogStreamHTTPSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamHTTPRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamHTTPRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamHTTPRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamHTTPRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetType(type_ LogStreamHTTPEnum) {
	c.Type = type_
	c.require(createLogStreamHTTPRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamHTTPRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamHTTPRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamHTTPRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetSink(sink *LogStreamHTTPSink) {
	c.Sink = sink
	c.require(createLogStreamHTTPRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamHTTPRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamHTTPRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamHTTPRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamHTTPRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamHTTPRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamHTTPRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamHTTPRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamHTTPRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamMixpanelRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamMixpanelRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamMixpanelRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamMixpanelRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamMixpanelRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamMixpanelRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamMixpanelRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamMixpanelRequestBody struct {
	// log stream name
	Name *string               `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamMixpanelEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter     `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig    `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamMixpanelSink `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamMixpanelRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamMixpanelRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamMixpanelRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamMixpanelRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamMixpanelRequestBody) GetSink() *LogStreamMixpanelSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamMixpanelRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamMixpanelRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamMixpanelRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamMixpanelRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetType(type_ LogStreamMixpanelEnum) {
	c.Type = type_
	c.require(createLogStreamMixpanelRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamMixpanelRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamMixpanelRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamMixpanelRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetSink(sink *LogStreamMixpanelSink) {
	c.Sink = sink
	c.require(createLogStreamMixpanelRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamMixpanelRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamMixpanelRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamMixpanelRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamMixpanelRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamMixpanelRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamMixpanelRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamMixpanelRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamMixpanelRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

type CreateLogStreamRequestContent struct {
	CreateLogStreamHTTPRequestBody        *CreateLogStreamHTTPRequestBody
	CreateLogStreamEventBridgeRequestBody *CreateLogStreamEventBridgeRequestBody
	CreateLogStreamEventGridRequestBody   *CreateLogStreamEventGridRequestBody
	CreateLogStreamDatadogRequestBody     *CreateLogStreamDatadogRequestBody
	CreateLogStreamSplunkRequestBody      *CreateLogStreamSplunkRequestBody
	CreateLogStreamSumoRequestBody        *CreateLogStreamSumoRequestBody
	CreateLogStreamSegmentRequestBody     *CreateLogStreamSegmentRequestBody
	CreateLogStreamMixpanelRequestBody    *CreateLogStreamMixpanelRequestBody

	typ string
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamHTTPRequestBody() *CreateLogStreamHTTPRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamHTTPRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamEventBridgeRequestBody() *CreateLogStreamEventBridgeRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamEventBridgeRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamEventGridRequestBody() *CreateLogStreamEventGridRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamEventGridRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamDatadogRequestBody() *CreateLogStreamDatadogRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamDatadogRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamSplunkRequestBody() *CreateLogStreamSplunkRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamSplunkRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamSumoRequestBody() *CreateLogStreamSumoRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamSumoRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamSegmentRequestBody() *CreateLogStreamSegmentRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamSegmentRequestBody
}

func (c *CreateLogStreamRequestContent) GetCreateLogStreamMixpanelRequestBody() *CreateLogStreamMixpanelRequestBody {
	if c == nil {
		return nil
	}
	return c.CreateLogStreamMixpanelRequestBody
}

func (c *CreateLogStreamRequestContent) UnmarshalJSON(data []byte) error {
	valueCreateLogStreamHTTPRequestBody := new(CreateLogStreamHTTPRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamHTTPRequestBody); err == nil {
		c.typ = "CreateLogStreamHTTPRequestBody"
		c.CreateLogStreamHTTPRequestBody = valueCreateLogStreamHTTPRequestBody
		return nil
	}
	valueCreateLogStreamEventBridgeRequestBody := new(CreateLogStreamEventBridgeRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamEventBridgeRequestBody); err == nil {
		c.typ = "CreateLogStreamEventBridgeRequestBody"
		c.CreateLogStreamEventBridgeRequestBody = valueCreateLogStreamEventBridgeRequestBody
		return nil
	}
	valueCreateLogStreamEventGridRequestBody := new(CreateLogStreamEventGridRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamEventGridRequestBody); err == nil {
		c.typ = "CreateLogStreamEventGridRequestBody"
		c.CreateLogStreamEventGridRequestBody = valueCreateLogStreamEventGridRequestBody
		return nil
	}
	valueCreateLogStreamDatadogRequestBody := new(CreateLogStreamDatadogRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamDatadogRequestBody); err == nil {
		c.typ = "CreateLogStreamDatadogRequestBody"
		c.CreateLogStreamDatadogRequestBody = valueCreateLogStreamDatadogRequestBody
		return nil
	}
	valueCreateLogStreamSplunkRequestBody := new(CreateLogStreamSplunkRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamSplunkRequestBody); err == nil {
		c.typ = "CreateLogStreamSplunkRequestBody"
		c.CreateLogStreamSplunkRequestBody = valueCreateLogStreamSplunkRequestBody
		return nil
	}
	valueCreateLogStreamSumoRequestBody := new(CreateLogStreamSumoRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamSumoRequestBody); err == nil {
		c.typ = "CreateLogStreamSumoRequestBody"
		c.CreateLogStreamSumoRequestBody = valueCreateLogStreamSumoRequestBody
		return nil
	}
	valueCreateLogStreamSegmentRequestBody := new(CreateLogStreamSegmentRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamSegmentRequestBody); err == nil {
		c.typ = "CreateLogStreamSegmentRequestBody"
		c.CreateLogStreamSegmentRequestBody = valueCreateLogStreamSegmentRequestBody
		return nil
	}
	valueCreateLogStreamMixpanelRequestBody := new(CreateLogStreamMixpanelRequestBody)
	if err := json.Unmarshal(data, &valueCreateLogStreamMixpanelRequestBody); err == nil {
		c.typ = "CreateLogStreamMixpanelRequestBody"
		c.CreateLogStreamMixpanelRequestBody = valueCreateLogStreamMixpanelRequestBody
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, c)
}

func (c CreateLogStreamRequestContent) MarshalJSON() ([]byte, error) {
	if c.typ == "CreateLogStreamHTTPRequestBody" || c.CreateLogStreamHTTPRequestBody != nil {
		return json.Marshal(c.CreateLogStreamHTTPRequestBody)
	}
	if c.typ == "CreateLogStreamEventBridgeRequestBody" || c.CreateLogStreamEventBridgeRequestBody != nil {
		return json.Marshal(c.CreateLogStreamEventBridgeRequestBody)
	}
	if c.typ == "CreateLogStreamEventGridRequestBody" || c.CreateLogStreamEventGridRequestBody != nil {
		return json.Marshal(c.CreateLogStreamEventGridRequestBody)
	}
	if c.typ == "CreateLogStreamDatadogRequestBody" || c.CreateLogStreamDatadogRequestBody != nil {
		return json.Marshal(c.CreateLogStreamDatadogRequestBody)
	}
	if c.typ == "CreateLogStreamSplunkRequestBody" || c.CreateLogStreamSplunkRequestBody != nil {
		return json.Marshal(c.CreateLogStreamSplunkRequestBody)
	}
	if c.typ == "CreateLogStreamSumoRequestBody" || c.CreateLogStreamSumoRequestBody != nil {
		return json.Marshal(c.CreateLogStreamSumoRequestBody)
	}
	if c.typ == "CreateLogStreamSegmentRequestBody" || c.CreateLogStreamSegmentRequestBody != nil {
		return json.Marshal(c.CreateLogStreamSegmentRequestBody)
	}
	if c.typ == "CreateLogStreamMixpanelRequestBody" || c.CreateLogStreamMixpanelRequestBody != nil {
		return json.Marshal(c.CreateLogStreamMixpanelRequestBody)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", c)
}

type CreateLogStreamRequestContentVisitor interface {
	VisitCreateLogStreamHTTPRequestBody(*CreateLogStreamHTTPRequestBody) error
	VisitCreateLogStreamEventBridgeRequestBody(*CreateLogStreamEventBridgeRequestBody) error
	VisitCreateLogStreamEventGridRequestBody(*CreateLogStreamEventGridRequestBody) error
	VisitCreateLogStreamDatadogRequestBody(*CreateLogStreamDatadogRequestBody) error
	VisitCreateLogStreamSplunkRequestBody(*CreateLogStreamSplunkRequestBody) error
	VisitCreateLogStreamSumoRequestBody(*CreateLogStreamSumoRequestBody) error
	VisitCreateLogStreamSegmentRequestBody(*CreateLogStreamSegmentRequestBody) error
	VisitCreateLogStreamMixpanelRequestBody(*CreateLogStreamMixpanelRequestBody) error
}

func (c *CreateLogStreamRequestContent) Accept(visitor CreateLogStreamRequestContentVisitor) error {
	if c.typ == "CreateLogStreamHTTPRequestBody" || c.CreateLogStreamHTTPRequestBody != nil {
		return visitor.VisitCreateLogStreamHTTPRequestBody(c.CreateLogStreamHTTPRequestBody)
	}
	if c.typ == "CreateLogStreamEventBridgeRequestBody" || c.CreateLogStreamEventBridgeRequestBody != nil {
		return visitor.VisitCreateLogStreamEventBridgeRequestBody(c.CreateLogStreamEventBridgeRequestBody)
	}
	if c.typ == "CreateLogStreamEventGridRequestBody" || c.CreateLogStreamEventGridRequestBody != nil {
		return visitor.VisitCreateLogStreamEventGridRequestBody(c.CreateLogStreamEventGridRequestBody)
	}
	if c.typ == "CreateLogStreamDatadogRequestBody" || c.CreateLogStreamDatadogRequestBody != nil {
		return visitor.VisitCreateLogStreamDatadogRequestBody(c.CreateLogStreamDatadogRequestBody)
	}
	if c.typ == "CreateLogStreamSplunkRequestBody" || c.CreateLogStreamSplunkRequestBody != nil {
		return visitor.VisitCreateLogStreamSplunkRequestBody(c.CreateLogStreamSplunkRequestBody)
	}
	if c.typ == "CreateLogStreamSumoRequestBody" || c.CreateLogStreamSumoRequestBody != nil {
		return visitor.VisitCreateLogStreamSumoRequestBody(c.CreateLogStreamSumoRequestBody)
	}
	if c.typ == "CreateLogStreamSegmentRequestBody" || c.CreateLogStreamSegmentRequestBody != nil {
		return visitor.VisitCreateLogStreamSegmentRequestBody(c.CreateLogStreamSegmentRequestBody)
	}
	if c.typ == "CreateLogStreamMixpanelRequestBody" || c.CreateLogStreamMixpanelRequestBody != nil {
		return visitor.VisitCreateLogStreamMixpanelRequestBody(c.CreateLogStreamMixpanelRequestBody)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", c)
}

type CreateLogStreamResponseContent struct {
	LogStreamHTTPResponseSchema        *LogStreamHTTPResponseSchema
	LogStreamEventBridgeResponseSchema *LogStreamEventBridgeResponseSchema
	LogStreamEventGridResponseSchema   *LogStreamEventGridResponseSchema
	LogStreamDatadogResponseSchema     *LogStreamDatadogResponseSchema
	LogStreamSplunkResponseSchema      *LogStreamSplunkResponseSchema
	LogStreamSumoResponseSchema        *LogStreamSumoResponseSchema
	LogStreamSegmentResponseSchema     *LogStreamSegmentResponseSchema
	LogStreamMixpanelResponseSchema    *LogStreamMixpanelResponseSchema

	typ string
}

func (c *CreateLogStreamResponseContent) GetLogStreamHTTPResponseSchema() *LogStreamHTTPResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamHTTPResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamEventBridgeResponseSchema() *LogStreamEventBridgeResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamEventBridgeResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamEventGridResponseSchema() *LogStreamEventGridResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamEventGridResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamDatadogResponseSchema() *LogStreamDatadogResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamDatadogResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamSplunkResponseSchema() *LogStreamSplunkResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamSplunkResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamSumoResponseSchema() *LogStreamSumoResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamSumoResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamSegmentResponseSchema() *LogStreamSegmentResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamSegmentResponseSchema
}

func (c *CreateLogStreamResponseContent) GetLogStreamMixpanelResponseSchema() *LogStreamMixpanelResponseSchema {
	if c == nil {
		return nil
	}
	return c.LogStreamMixpanelResponseSchema
}

func (c *CreateLogStreamResponseContent) UnmarshalJSON(data []byte) error {
	valueLogStreamHTTPResponseSchema := new(LogStreamHTTPResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamHTTPResponseSchema); err == nil {
		c.typ = "LogStreamHTTPResponseSchema"
		c.LogStreamHTTPResponseSchema = valueLogStreamHTTPResponseSchema
		return nil
	}
	valueLogStreamEventBridgeResponseSchema := new(LogStreamEventBridgeResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventBridgeResponseSchema); err == nil {
		c.typ = "LogStreamEventBridgeResponseSchema"
		c.LogStreamEventBridgeResponseSchema = valueLogStreamEventBridgeResponseSchema
		return nil
	}
	valueLogStreamEventGridResponseSchema := new(LogStreamEventGridResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventGridResponseSchema); err == nil {
		c.typ = "LogStreamEventGridResponseSchema"
		c.LogStreamEventGridResponseSchema = valueLogStreamEventGridResponseSchema
		return nil
	}
	valueLogStreamDatadogResponseSchema := new(LogStreamDatadogResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamDatadogResponseSchema); err == nil {
		c.typ = "LogStreamDatadogResponseSchema"
		c.LogStreamDatadogResponseSchema = valueLogStreamDatadogResponseSchema
		return nil
	}
	valueLogStreamSplunkResponseSchema := new(LogStreamSplunkResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSplunkResponseSchema); err == nil {
		c.typ = "LogStreamSplunkResponseSchema"
		c.LogStreamSplunkResponseSchema = valueLogStreamSplunkResponseSchema
		return nil
	}
	valueLogStreamSumoResponseSchema := new(LogStreamSumoResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSumoResponseSchema); err == nil {
		c.typ = "LogStreamSumoResponseSchema"
		c.LogStreamSumoResponseSchema = valueLogStreamSumoResponseSchema
		return nil
	}
	valueLogStreamSegmentResponseSchema := new(LogStreamSegmentResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSegmentResponseSchema); err == nil {
		c.typ = "LogStreamSegmentResponseSchema"
		c.LogStreamSegmentResponseSchema = valueLogStreamSegmentResponseSchema
		return nil
	}
	valueLogStreamMixpanelResponseSchema := new(LogStreamMixpanelResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamMixpanelResponseSchema); err == nil {
		c.typ = "LogStreamMixpanelResponseSchema"
		c.LogStreamMixpanelResponseSchema = valueLogStreamMixpanelResponseSchema
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, c)
}

func (c CreateLogStreamResponseContent) MarshalJSON() ([]byte, error) {
	if c.typ == "LogStreamHTTPResponseSchema" || c.LogStreamHTTPResponseSchema != nil {
		return json.Marshal(c.LogStreamHTTPResponseSchema)
	}
	if c.typ == "LogStreamEventBridgeResponseSchema" || c.LogStreamEventBridgeResponseSchema != nil {
		return json.Marshal(c.LogStreamEventBridgeResponseSchema)
	}
	if c.typ == "LogStreamEventGridResponseSchema" || c.LogStreamEventGridResponseSchema != nil {
		return json.Marshal(c.LogStreamEventGridResponseSchema)
	}
	if c.typ == "LogStreamDatadogResponseSchema" || c.LogStreamDatadogResponseSchema != nil {
		return json.Marshal(c.LogStreamDatadogResponseSchema)
	}
	if c.typ == "LogStreamSplunkResponseSchema" || c.LogStreamSplunkResponseSchema != nil {
		return json.Marshal(c.LogStreamSplunkResponseSchema)
	}
	if c.typ == "LogStreamSumoResponseSchema" || c.LogStreamSumoResponseSchema != nil {
		return json.Marshal(c.LogStreamSumoResponseSchema)
	}
	if c.typ == "LogStreamSegmentResponseSchema" || c.LogStreamSegmentResponseSchema != nil {
		return json.Marshal(c.LogStreamSegmentResponseSchema)
	}
	if c.typ == "LogStreamMixpanelResponseSchema" || c.LogStreamMixpanelResponseSchema != nil {
		return json.Marshal(c.LogStreamMixpanelResponseSchema)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", c)
}

type CreateLogStreamResponseContentVisitor interface {
	VisitLogStreamHTTPResponseSchema(*LogStreamHTTPResponseSchema) error
	VisitLogStreamEventBridgeResponseSchema(*LogStreamEventBridgeResponseSchema) error
	VisitLogStreamEventGridResponseSchema(*LogStreamEventGridResponseSchema) error
	VisitLogStreamDatadogResponseSchema(*LogStreamDatadogResponseSchema) error
	VisitLogStreamSplunkResponseSchema(*LogStreamSplunkResponseSchema) error
	VisitLogStreamSumoResponseSchema(*LogStreamSumoResponseSchema) error
	VisitLogStreamSegmentResponseSchema(*LogStreamSegmentResponseSchema) error
	VisitLogStreamMixpanelResponseSchema(*LogStreamMixpanelResponseSchema) error
}

func (c *CreateLogStreamResponseContent) Accept(visitor CreateLogStreamResponseContentVisitor) error {
	if c.typ == "LogStreamHTTPResponseSchema" || c.LogStreamHTTPResponseSchema != nil {
		return visitor.VisitLogStreamHTTPResponseSchema(c.LogStreamHTTPResponseSchema)
	}
	if c.typ == "LogStreamEventBridgeResponseSchema" || c.LogStreamEventBridgeResponseSchema != nil {
		return visitor.VisitLogStreamEventBridgeResponseSchema(c.LogStreamEventBridgeResponseSchema)
	}
	if c.typ == "LogStreamEventGridResponseSchema" || c.LogStreamEventGridResponseSchema != nil {
		return visitor.VisitLogStreamEventGridResponseSchema(c.LogStreamEventGridResponseSchema)
	}
	if c.typ == "LogStreamDatadogResponseSchema" || c.LogStreamDatadogResponseSchema != nil {
		return visitor.VisitLogStreamDatadogResponseSchema(c.LogStreamDatadogResponseSchema)
	}
	if c.typ == "LogStreamSplunkResponseSchema" || c.LogStreamSplunkResponseSchema != nil {
		return visitor.VisitLogStreamSplunkResponseSchema(c.LogStreamSplunkResponseSchema)
	}
	if c.typ == "LogStreamSumoResponseSchema" || c.LogStreamSumoResponseSchema != nil {
		return visitor.VisitLogStreamSumoResponseSchema(c.LogStreamSumoResponseSchema)
	}
	if c.typ == "LogStreamSegmentResponseSchema" || c.LogStreamSegmentResponseSchema != nil {
		return visitor.VisitLogStreamSegmentResponseSchema(c.LogStreamSegmentResponseSchema)
	}
	if c.typ == "LogStreamMixpanelResponseSchema" || c.LogStreamMixpanelResponseSchema != nil {
		return visitor.VisitLogStreamMixpanelResponseSchema(c.LogStreamMixpanelResponseSchema)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", c)
}

var (
	createLogStreamSegmentRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamSegmentRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamSegmentRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamSegmentRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamSegmentRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamSegmentRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamSegmentRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamSegmentRequestBody struct {
	// log stream name
	Name *string              `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamSegmentEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter            `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig           `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSegmentSinkWriteKey `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamSegmentRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamSegmentRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamSegmentRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamSegmentRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamSegmentRequestBody) GetSink() *LogStreamSegmentSinkWriteKey {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamSegmentRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamSegmentRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamSegmentRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamSegmentRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetType(type_ LogStreamSegmentEnum) {
	c.Type = type_
	c.require(createLogStreamSegmentRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamSegmentRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamSegmentRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamSegmentRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetSink(sink *LogStreamSegmentSinkWriteKey) {
	c.Sink = sink
	c.require(createLogStreamSegmentRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSegmentRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamSegmentRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamSegmentRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamSegmentRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamSegmentRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamSegmentRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamSegmentRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamSegmentRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamSplunkRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamSplunkRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamSplunkRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamSplunkRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamSplunkRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamSplunkRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamSplunkRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamSplunkRequestBody struct {
	// log stream name
	Name *string             `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamSplunkEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter   `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig  `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSplunkSink `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamSplunkRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamSplunkRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamSplunkRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamSplunkRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamSplunkRequestBody) GetSink() *LogStreamSplunkSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamSplunkRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamSplunkRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamSplunkRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamSplunkRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetType(type_ LogStreamSplunkEnum) {
	c.Type = type_
	c.require(createLogStreamSplunkRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamSplunkRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamSplunkRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamSplunkRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetSink(sink *LogStreamSplunkSink) {
	c.Sink = sink
	c.require(createLogStreamSplunkRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSplunkRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamSplunkRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamSplunkRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamSplunkRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamSplunkRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamSplunkRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamSplunkRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamSplunkRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

var (
	createLogStreamSumoRequestBodyFieldName       = big.NewInt(1 << 0)
	createLogStreamSumoRequestBodyFieldType       = big.NewInt(1 << 1)
	createLogStreamSumoRequestBodyFieldIsPriority = big.NewInt(1 << 2)
	createLogStreamSumoRequestBodyFieldFilters    = big.NewInt(1 << 3)
	createLogStreamSumoRequestBodyFieldPiiConfig  = big.NewInt(1 << 4)
	createLogStreamSumoRequestBodyFieldSink       = big.NewInt(1 << 5)
	createLogStreamSumoRequestBodyFieldStartFrom  = big.NewInt(1 << 6)
)

type CreateLogStreamSumoRequestBody struct {
	// log stream name
	Name *string           `json:"name,omitempty" url:"name,omitempty"`
	Type LogStreamSumoEnum `json:"type" url:"type"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter  `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSumoSink  `json:"sink" url:"sink"`
	// The optional datetime (ISO 8601) to start streaming logs from
	StartFrom *string `json:"startFrom,omitempty" url:"startFrom,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (c *CreateLogStreamSumoRequestBody) GetName() string {
	if c == nil || c.Name == nil {
		return ""
	}
	return *c.Name
}

func (c *CreateLogStreamSumoRequestBody) GetIsPriority() bool {
	if c == nil || c.IsPriority == nil {
		return false
	}
	return *c.IsPriority
}

func (c *CreateLogStreamSumoRequestBody) GetFilters() []*LogStreamFilter {
	if c == nil || c.Filters == nil {
		return nil
	}
	return c.Filters
}

func (c *CreateLogStreamSumoRequestBody) GetPiiConfig() LogStreamPiiConfig {
	if c == nil || c.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *c.PiiConfig
}

func (c *CreateLogStreamSumoRequestBody) GetSink() *LogStreamSumoSink {
	if c == nil {
		return nil
	}
	return c.Sink
}

func (c *CreateLogStreamSumoRequestBody) GetStartFrom() string {
	if c == nil || c.StartFrom == nil {
		return ""
	}
	return *c.StartFrom
}

func (c *CreateLogStreamSumoRequestBody) GetExtraProperties() map[string]interface{} {
	return c.extraProperties
}

func (c *CreateLogStreamSumoRequestBody) require(field *big.Int) {
	if c.explicitFields == nil {
		c.explicitFields = big.NewInt(0)
	}
	c.explicitFields.Or(c.explicitFields, field)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetName(name *string) {
	c.Name = name
	c.require(createLogStreamSumoRequestBodyFieldName)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetType(type_ LogStreamSumoEnum) {
	c.Type = type_
	c.require(createLogStreamSumoRequestBodyFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetIsPriority(isPriority *bool) {
	c.IsPriority = isPriority
	c.require(createLogStreamSumoRequestBodyFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetFilters(filters []*LogStreamFilter) {
	c.Filters = filters
	c.require(createLogStreamSumoRequestBodyFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	c.PiiConfig = piiConfig
	c.require(createLogStreamSumoRequestBodyFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetSink(sink *LogStreamSumoSink) {
	c.Sink = sink
	c.require(createLogStreamSumoRequestBodyFieldSink)
}

// SetStartFrom sets the StartFrom field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (c *CreateLogStreamSumoRequestBody) SetStartFrom(startFrom *string) {
	c.StartFrom = startFrom
	c.require(createLogStreamSumoRequestBodyFieldStartFrom)
}

func (c *CreateLogStreamSumoRequestBody) UnmarshalJSON(data []byte) error {
	type unmarshaler CreateLogStreamSumoRequestBody
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*c = CreateLogStreamSumoRequestBody(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *c)
	if err != nil {
		return err
	}
	c.extraProperties = extraProperties
	c.rawJSON = json.RawMessage(data)
	return nil
}

func (c *CreateLogStreamSumoRequestBody) MarshalJSON() ([]byte, error) {
	type embed CreateLogStreamSumoRequestBody
	var marshaler = struct {
		embed
	}{
		embed: embed(*c),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, c.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (c *CreateLogStreamSumoRequestBody) String() string {
	if len(c.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(c.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(c); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", c)
}

type GetLogStreamResponseContent struct {
	LogStreamHTTPResponseSchema        *LogStreamHTTPResponseSchema
	LogStreamEventBridgeResponseSchema *LogStreamEventBridgeResponseSchema
	LogStreamEventGridResponseSchema   *LogStreamEventGridResponseSchema
	LogStreamDatadogResponseSchema     *LogStreamDatadogResponseSchema
	LogStreamSplunkResponseSchema      *LogStreamSplunkResponseSchema
	LogStreamSumoResponseSchema        *LogStreamSumoResponseSchema
	LogStreamSegmentResponseSchema     *LogStreamSegmentResponseSchema
	LogStreamMixpanelResponseSchema    *LogStreamMixpanelResponseSchema

	typ string
}

func (g *GetLogStreamResponseContent) GetLogStreamHTTPResponseSchema() *LogStreamHTTPResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamHTTPResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamEventBridgeResponseSchema() *LogStreamEventBridgeResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamEventBridgeResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamEventGridResponseSchema() *LogStreamEventGridResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamEventGridResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamDatadogResponseSchema() *LogStreamDatadogResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamDatadogResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamSplunkResponseSchema() *LogStreamSplunkResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamSplunkResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamSumoResponseSchema() *LogStreamSumoResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamSumoResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamSegmentResponseSchema() *LogStreamSegmentResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamSegmentResponseSchema
}

func (g *GetLogStreamResponseContent) GetLogStreamMixpanelResponseSchema() *LogStreamMixpanelResponseSchema {
	if g == nil {
		return nil
	}
	return g.LogStreamMixpanelResponseSchema
}

func (g *GetLogStreamResponseContent) UnmarshalJSON(data []byte) error {
	valueLogStreamHTTPResponseSchema := new(LogStreamHTTPResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamHTTPResponseSchema); err == nil {
		g.typ = "LogStreamHTTPResponseSchema"
		g.LogStreamHTTPResponseSchema = valueLogStreamHTTPResponseSchema
		return nil
	}
	valueLogStreamEventBridgeResponseSchema := new(LogStreamEventBridgeResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventBridgeResponseSchema); err == nil {
		g.typ = "LogStreamEventBridgeResponseSchema"
		g.LogStreamEventBridgeResponseSchema = valueLogStreamEventBridgeResponseSchema
		return nil
	}
	valueLogStreamEventGridResponseSchema := new(LogStreamEventGridResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventGridResponseSchema); err == nil {
		g.typ = "LogStreamEventGridResponseSchema"
		g.LogStreamEventGridResponseSchema = valueLogStreamEventGridResponseSchema
		return nil
	}
	valueLogStreamDatadogResponseSchema := new(LogStreamDatadogResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamDatadogResponseSchema); err == nil {
		g.typ = "LogStreamDatadogResponseSchema"
		g.LogStreamDatadogResponseSchema = valueLogStreamDatadogResponseSchema
		return nil
	}
	valueLogStreamSplunkResponseSchema := new(LogStreamSplunkResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSplunkResponseSchema); err == nil {
		g.typ = "LogStreamSplunkResponseSchema"
		g.LogStreamSplunkResponseSchema = valueLogStreamSplunkResponseSchema
		return nil
	}
	valueLogStreamSumoResponseSchema := new(LogStreamSumoResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSumoResponseSchema); err == nil {
		g.typ = "LogStreamSumoResponseSchema"
		g.LogStreamSumoResponseSchema = valueLogStreamSumoResponseSchema
		return nil
	}
	valueLogStreamSegmentResponseSchema := new(LogStreamSegmentResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSegmentResponseSchema); err == nil {
		g.typ = "LogStreamSegmentResponseSchema"
		g.LogStreamSegmentResponseSchema = valueLogStreamSegmentResponseSchema
		return nil
	}
	valueLogStreamMixpanelResponseSchema := new(LogStreamMixpanelResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamMixpanelResponseSchema); err == nil {
		g.typ = "LogStreamMixpanelResponseSchema"
		g.LogStreamMixpanelResponseSchema = valueLogStreamMixpanelResponseSchema
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, g)
}

func (g GetLogStreamResponseContent) MarshalJSON() ([]byte, error) {
	if g.typ == "LogStreamHTTPResponseSchema" || g.LogStreamHTTPResponseSchema != nil {
		return json.Marshal(g.LogStreamHTTPResponseSchema)
	}
	if g.typ == "LogStreamEventBridgeResponseSchema" || g.LogStreamEventBridgeResponseSchema != nil {
		return json.Marshal(g.LogStreamEventBridgeResponseSchema)
	}
	if g.typ == "LogStreamEventGridResponseSchema" || g.LogStreamEventGridResponseSchema != nil {
		return json.Marshal(g.LogStreamEventGridResponseSchema)
	}
	if g.typ == "LogStreamDatadogResponseSchema" || g.LogStreamDatadogResponseSchema != nil {
		return json.Marshal(g.LogStreamDatadogResponseSchema)
	}
	if g.typ == "LogStreamSplunkResponseSchema" || g.LogStreamSplunkResponseSchema != nil {
		return json.Marshal(g.LogStreamSplunkResponseSchema)
	}
	if g.typ == "LogStreamSumoResponseSchema" || g.LogStreamSumoResponseSchema != nil {
		return json.Marshal(g.LogStreamSumoResponseSchema)
	}
	if g.typ == "LogStreamSegmentResponseSchema" || g.LogStreamSegmentResponseSchema != nil {
		return json.Marshal(g.LogStreamSegmentResponseSchema)
	}
	if g.typ == "LogStreamMixpanelResponseSchema" || g.LogStreamMixpanelResponseSchema != nil {
		return json.Marshal(g.LogStreamMixpanelResponseSchema)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", g)
}

type GetLogStreamResponseContentVisitor interface {
	VisitLogStreamHTTPResponseSchema(*LogStreamHTTPResponseSchema) error
	VisitLogStreamEventBridgeResponseSchema(*LogStreamEventBridgeResponseSchema) error
	VisitLogStreamEventGridResponseSchema(*LogStreamEventGridResponseSchema) error
	VisitLogStreamDatadogResponseSchema(*LogStreamDatadogResponseSchema) error
	VisitLogStreamSplunkResponseSchema(*LogStreamSplunkResponseSchema) error
	VisitLogStreamSumoResponseSchema(*LogStreamSumoResponseSchema) error
	VisitLogStreamSegmentResponseSchema(*LogStreamSegmentResponseSchema) error
	VisitLogStreamMixpanelResponseSchema(*LogStreamMixpanelResponseSchema) error
}

func (g *GetLogStreamResponseContent) Accept(visitor GetLogStreamResponseContentVisitor) error {
	if g.typ == "LogStreamHTTPResponseSchema" || g.LogStreamHTTPResponseSchema != nil {
		return visitor.VisitLogStreamHTTPResponseSchema(g.LogStreamHTTPResponseSchema)
	}
	if g.typ == "LogStreamEventBridgeResponseSchema" || g.LogStreamEventBridgeResponseSchema != nil {
		return visitor.VisitLogStreamEventBridgeResponseSchema(g.LogStreamEventBridgeResponseSchema)
	}
	if g.typ == "LogStreamEventGridResponseSchema" || g.LogStreamEventGridResponseSchema != nil {
		return visitor.VisitLogStreamEventGridResponseSchema(g.LogStreamEventGridResponseSchema)
	}
	if g.typ == "LogStreamDatadogResponseSchema" || g.LogStreamDatadogResponseSchema != nil {
		return visitor.VisitLogStreamDatadogResponseSchema(g.LogStreamDatadogResponseSchema)
	}
	if g.typ == "LogStreamSplunkResponseSchema" || g.LogStreamSplunkResponseSchema != nil {
		return visitor.VisitLogStreamSplunkResponseSchema(g.LogStreamSplunkResponseSchema)
	}
	if g.typ == "LogStreamSumoResponseSchema" || g.LogStreamSumoResponseSchema != nil {
		return visitor.VisitLogStreamSumoResponseSchema(g.LogStreamSumoResponseSchema)
	}
	if g.typ == "LogStreamSegmentResponseSchema" || g.LogStreamSegmentResponseSchema != nil {
		return visitor.VisitLogStreamSegmentResponseSchema(g.LogStreamSegmentResponseSchema)
	}
	if g.typ == "LogStreamMixpanelResponseSchema" || g.LogStreamMixpanelResponseSchema != nil {
		return visitor.VisitLogStreamMixpanelResponseSchema(g.LogStreamMixpanelResponseSchema)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", g)
}

var (
	hTTPCustomHeaderFieldHeader = big.NewInt(1 << 0)
	hTTPCustomHeaderFieldValue  = big.NewInt(1 << 1)
)

type HTTPCustomHeader struct {
	// HTTP header name
	Header *string `json:"header,omitempty" url:"header,omitempty"`
	// HTTP header value
	Value *string `json:"value,omitempty" url:"value,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (h *HTTPCustomHeader) GetHeader() string {
	if h == nil || h.Header == nil {
		return ""
	}
	return *h.Header
}

func (h *HTTPCustomHeader) GetValue() string {
	if h == nil || h.Value == nil {
		return ""
	}
	return *h.Value
}

func (h *HTTPCustomHeader) GetExtraProperties() map[string]interface{} {
	return h.ExtraProperties
}

func (h *HTTPCustomHeader) require(field *big.Int) {
	if h.explicitFields == nil {
		h.explicitFields = big.NewInt(0)
	}
	h.explicitFields.Or(h.explicitFields, field)
}

// SetHeader sets the Header field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (h *HTTPCustomHeader) SetHeader(header *string) {
	h.Header = header
	h.require(hTTPCustomHeaderFieldHeader)
}

// SetValue sets the Value field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (h *HTTPCustomHeader) SetValue(value *string) {
	h.Value = value
	h.require(hTTPCustomHeaderFieldValue)
}

func (h *HTTPCustomHeader) UnmarshalJSON(data []byte) error {
	type embed HTTPCustomHeader
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*h),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*h = HTTPCustomHeader(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *h)
	if err != nil {
		return err
	}
	h.ExtraProperties = extraProperties
	h.rawJSON = json.RawMessage(data)
	return nil
}

func (h *HTTPCustomHeader) MarshalJSON() ([]byte, error) {
	type embed HTTPCustomHeader
	var marshaler = struct {
		embed
	}{
		embed: embed(*h),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, h.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, h.ExtraProperties)
}

func (h *HTTPCustomHeader) String() string {
	if len(h.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(h.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(h); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", h)
}

type LogStreamDatadogEnum = string

// Datadog region
type LogStreamDatadogRegionEnum string

const (
	LogStreamDatadogRegionEnumUs  LogStreamDatadogRegionEnum = "us"
	LogStreamDatadogRegionEnumEu  LogStreamDatadogRegionEnum = "eu"
	LogStreamDatadogRegionEnumUs3 LogStreamDatadogRegionEnum = "us3"
	LogStreamDatadogRegionEnumUs5 LogStreamDatadogRegionEnum = "us5"
)

func NewLogStreamDatadogRegionEnumFromString(s string) (LogStreamDatadogRegionEnum, error) {
	switch s {
	case "us":
		return LogStreamDatadogRegionEnumUs, nil
	case "eu":
		return LogStreamDatadogRegionEnumEu, nil
	case "us3":
		return LogStreamDatadogRegionEnumUs3, nil
	case "us5":
		return LogStreamDatadogRegionEnumUs5, nil
	}
	var t LogStreamDatadogRegionEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamDatadogRegionEnum) Ptr() *LogStreamDatadogRegionEnum {
	return &l
}

var (
	logStreamDatadogResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamDatadogResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamDatadogResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamDatadogResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamDatadogResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamDatadogResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamDatadogResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamDatadogResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamDatadogResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string               `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum  `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamDatadogEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter    `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig   `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamDatadogSink `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamDatadogResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamDatadogResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamDatadogResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamDatadogResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamDatadogResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamDatadogResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamDatadogResponseSchema) GetSink() LogStreamDatadogSink {
	if l == nil || l.Sink == nil {
		return LogStreamDatadogSink{}
	}
	return *l.Sink
}

func (l *LogStreamDatadogResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamDatadogResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamDatadogResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamDatadogResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamDatadogResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetType(type_ *LogStreamDatadogEnum) {
	l.Type = type_
	l.require(logStreamDatadogResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamDatadogResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamDatadogResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamDatadogResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogResponseSchema) SetSink(sink *LogStreamDatadogSink) {
	l.Sink = sink
	l.require(logStreamDatadogResponseSchemaFieldSink)
}

func (l *LogStreamDatadogResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamDatadogResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamDatadogResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamDatadogResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamDatadogResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamDatadogResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamDatadogSinkFieldDatadogAPIKey = big.NewInt(1 << 0)
	logStreamDatadogSinkFieldDatadogRegion = big.NewInt(1 << 1)
)

type LogStreamDatadogSink struct {
	// Datadog API Key
	DatadogAPIKey string                     `json:"datadogApiKey" url:"datadogApiKey"`
	DatadogRegion LogStreamDatadogRegionEnum `json:"datadogRegion" url:"datadogRegion"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamDatadogSink) GetDatadogAPIKey() string {
	if l == nil {
		return ""
	}
	return l.DatadogAPIKey
}

func (l *LogStreamDatadogSink) GetDatadogRegion() LogStreamDatadogRegionEnum {
	if l == nil {
		return ""
	}
	return l.DatadogRegion
}

func (l *LogStreamDatadogSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamDatadogSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetDatadogAPIKey sets the DatadogAPIKey field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogSink) SetDatadogAPIKey(datadogAPIKey string) {
	l.DatadogAPIKey = datadogAPIKey
	l.require(logStreamDatadogSinkFieldDatadogAPIKey)
}

// SetDatadogRegion sets the DatadogRegion field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamDatadogSink) SetDatadogRegion(datadogRegion LogStreamDatadogRegionEnum) {
	l.DatadogRegion = datadogRegion
	l.require(logStreamDatadogSinkFieldDatadogRegion)
}

func (l *LogStreamDatadogSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamDatadogSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamDatadogSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamDatadogSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamDatadogSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamDatadogSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type LogStreamEventBridgeEnum = string

var (
	logStreamEventBridgeResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamEventBridgeResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamEventBridgeResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamEventBridgeResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamEventBridgeResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamEventBridgeResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamEventBridgeResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamEventBridgeResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamEventBridgeResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string                   `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum      `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamEventBridgeEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter        `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig       `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamEventBridgeSink `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamEventBridgeResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamEventBridgeResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamEventBridgeResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamEventBridgeResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamEventBridgeResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamEventBridgeResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamEventBridgeResponseSchema) GetSink() LogStreamEventBridgeSink {
	if l == nil || l.Sink == nil {
		return LogStreamEventBridgeSink{}
	}
	return *l.Sink
}

func (l *LogStreamEventBridgeResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamEventBridgeResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamEventBridgeResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamEventBridgeResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamEventBridgeResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetType(type_ *LogStreamEventBridgeEnum) {
	l.Type = type_
	l.require(logStreamEventBridgeResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamEventBridgeResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamEventBridgeResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamEventBridgeResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeResponseSchema) SetSink(sink *LogStreamEventBridgeSink) {
	l.Sink = sink
	l.require(logStreamEventBridgeResponseSchemaFieldSink)
}

func (l *LogStreamEventBridgeResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamEventBridgeResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamEventBridgeResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamEventBridgeResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamEventBridgeResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamEventBridgeResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamEventBridgeSinkFieldAwsAccountID          = big.NewInt(1 << 0)
	logStreamEventBridgeSinkFieldAwsRegion             = big.NewInt(1 << 1)
	logStreamEventBridgeSinkFieldAwsPartnerEventSource = big.NewInt(1 << 2)
)

type LogStreamEventBridgeSink struct {
	// AWS account ID
	AwsAccountID string                             `json:"awsAccountId" url:"awsAccountId"`
	AwsRegion    LogStreamEventBridgeSinkRegionEnum `json:"awsRegion" url:"awsRegion"`
	// AWS EventBridge partner event source
	AwsPartnerEventSource *string `json:"awsPartnerEventSource,omitempty" url:"awsPartnerEventSource,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamEventBridgeSink) GetAwsAccountID() string {
	if l == nil {
		return ""
	}
	return l.AwsAccountID
}

func (l *LogStreamEventBridgeSink) GetAwsRegion() LogStreamEventBridgeSinkRegionEnum {
	if l == nil {
		return ""
	}
	return l.AwsRegion
}

func (l *LogStreamEventBridgeSink) GetAwsPartnerEventSource() string {
	if l == nil || l.AwsPartnerEventSource == nil {
		return ""
	}
	return *l.AwsPartnerEventSource
}

func (l *LogStreamEventBridgeSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamEventBridgeSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetAwsAccountID sets the AwsAccountID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeSink) SetAwsAccountID(awsAccountID string) {
	l.AwsAccountID = awsAccountID
	l.require(logStreamEventBridgeSinkFieldAwsAccountID)
}

// SetAwsRegion sets the AwsRegion field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeSink) SetAwsRegion(awsRegion LogStreamEventBridgeSinkRegionEnum) {
	l.AwsRegion = awsRegion
	l.require(logStreamEventBridgeSinkFieldAwsRegion)
}

// SetAwsPartnerEventSource sets the AwsPartnerEventSource field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventBridgeSink) SetAwsPartnerEventSource(awsPartnerEventSource *string) {
	l.AwsPartnerEventSource = awsPartnerEventSource
	l.require(logStreamEventBridgeSinkFieldAwsPartnerEventSource)
}

func (l *LogStreamEventBridgeSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamEventBridgeSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamEventBridgeSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamEventBridgeSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamEventBridgeSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamEventBridgeSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

// The region in which the EventBridge event source will be created
type LogStreamEventBridgeSinkRegionEnum string

const (
	LogStreamEventBridgeSinkRegionEnumAfSouth1     LogStreamEventBridgeSinkRegionEnum = "af-south-1"
	LogStreamEventBridgeSinkRegionEnumApEast1      LogStreamEventBridgeSinkRegionEnum = "ap-east-1"
	LogStreamEventBridgeSinkRegionEnumApEast2      LogStreamEventBridgeSinkRegionEnum = "ap-east-2"
	LogStreamEventBridgeSinkRegionEnumApNortheast1 LogStreamEventBridgeSinkRegionEnum = "ap-northeast-1"
	LogStreamEventBridgeSinkRegionEnumApNortheast2 LogStreamEventBridgeSinkRegionEnum = "ap-northeast-2"
	LogStreamEventBridgeSinkRegionEnumApNortheast3 LogStreamEventBridgeSinkRegionEnum = "ap-northeast-3"
	LogStreamEventBridgeSinkRegionEnumApSouth1     LogStreamEventBridgeSinkRegionEnum = "ap-south-1"
	LogStreamEventBridgeSinkRegionEnumApSouth2     LogStreamEventBridgeSinkRegionEnum = "ap-south-2"
	LogStreamEventBridgeSinkRegionEnumApSoutheast1 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-1"
	LogStreamEventBridgeSinkRegionEnumApSoutheast2 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-2"
	LogStreamEventBridgeSinkRegionEnumApSoutheast3 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-3"
	LogStreamEventBridgeSinkRegionEnumApSoutheast4 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-4"
	LogStreamEventBridgeSinkRegionEnumApSoutheast5 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-5"
	LogStreamEventBridgeSinkRegionEnumApSoutheast6 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-6"
	LogStreamEventBridgeSinkRegionEnumApSoutheast7 LogStreamEventBridgeSinkRegionEnum = "ap-southeast-7"
	LogStreamEventBridgeSinkRegionEnumCaCentral1   LogStreamEventBridgeSinkRegionEnum = "ca-central-1"
	LogStreamEventBridgeSinkRegionEnumCaWest1      LogStreamEventBridgeSinkRegionEnum = "ca-west-1"
	LogStreamEventBridgeSinkRegionEnumEuCentral1   LogStreamEventBridgeSinkRegionEnum = "eu-central-1"
	LogStreamEventBridgeSinkRegionEnumEuCentral2   LogStreamEventBridgeSinkRegionEnum = "eu-central-2"
	LogStreamEventBridgeSinkRegionEnumEuNorth1     LogStreamEventBridgeSinkRegionEnum = "eu-north-1"
	LogStreamEventBridgeSinkRegionEnumEuSouth1     LogStreamEventBridgeSinkRegionEnum = "eu-south-1"
	LogStreamEventBridgeSinkRegionEnumEuSouth2     LogStreamEventBridgeSinkRegionEnum = "eu-south-2"
	LogStreamEventBridgeSinkRegionEnumEuWest1      LogStreamEventBridgeSinkRegionEnum = "eu-west-1"
	LogStreamEventBridgeSinkRegionEnumEuWest2      LogStreamEventBridgeSinkRegionEnum = "eu-west-2"
	LogStreamEventBridgeSinkRegionEnumEuWest3      LogStreamEventBridgeSinkRegionEnum = "eu-west-3"
	LogStreamEventBridgeSinkRegionEnumIlCentral1   LogStreamEventBridgeSinkRegionEnum = "il-central-1"
	LogStreamEventBridgeSinkRegionEnumMeCentral1   LogStreamEventBridgeSinkRegionEnum = "me-central-1"
	LogStreamEventBridgeSinkRegionEnumMeSouth1     LogStreamEventBridgeSinkRegionEnum = "me-south-1"
	LogStreamEventBridgeSinkRegionEnumMxCentral1   LogStreamEventBridgeSinkRegionEnum = "mx-central-1"
	LogStreamEventBridgeSinkRegionEnumSaEast1      LogStreamEventBridgeSinkRegionEnum = "sa-east-1"
	LogStreamEventBridgeSinkRegionEnumUsGovEast1   LogStreamEventBridgeSinkRegionEnum = "us-gov-east-1"
	LogStreamEventBridgeSinkRegionEnumUsGovWest1   LogStreamEventBridgeSinkRegionEnum = "us-gov-west-1"
	LogStreamEventBridgeSinkRegionEnumUsEast1      LogStreamEventBridgeSinkRegionEnum = "us-east-1"
	LogStreamEventBridgeSinkRegionEnumUsEast2      LogStreamEventBridgeSinkRegionEnum = "us-east-2"
	LogStreamEventBridgeSinkRegionEnumUsWest1      LogStreamEventBridgeSinkRegionEnum = "us-west-1"
	LogStreamEventBridgeSinkRegionEnumUsWest2      LogStreamEventBridgeSinkRegionEnum = "us-west-2"
)

func NewLogStreamEventBridgeSinkRegionEnumFromString(s string) (LogStreamEventBridgeSinkRegionEnum, error) {
	switch s {
	case "af-south-1":
		return LogStreamEventBridgeSinkRegionEnumAfSouth1, nil
	case "ap-east-1":
		return LogStreamEventBridgeSinkRegionEnumApEast1, nil
	case "ap-east-2":
		return LogStreamEventBridgeSinkRegionEnumApEast2, nil
	case "ap-northeast-1":
		return LogStreamEventBridgeSinkRegionEnumApNortheast1, nil
	case "ap-northeast-2":
		return LogStreamEventBridgeSinkRegionEnumApNortheast2, nil
	case "ap-northeast-3":
		return LogStreamEventBridgeSinkRegionEnumApNortheast3, nil
	case "ap-south-1":
		return LogStreamEventBridgeSinkRegionEnumApSouth1, nil
	case "ap-south-2":
		return LogStreamEventBridgeSinkRegionEnumApSouth2, nil
	case "ap-southeast-1":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast1, nil
	case "ap-southeast-2":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast2, nil
	case "ap-southeast-3":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast3, nil
	case "ap-southeast-4":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast4, nil
	case "ap-southeast-5":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast5, nil
	case "ap-southeast-6":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast6, nil
	case "ap-southeast-7":
		return LogStreamEventBridgeSinkRegionEnumApSoutheast7, nil
	case "ca-central-1":
		return LogStreamEventBridgeSinkRegionEnumCaCentral1, nil
	case "ca-west-1":
		return LogStreamEventBridgeSinkRegionEnumCaWest1, nil
	case "eu-central-1":
		return LogStreamEventBridgeSinkRegionEnumEuCentral1, nil
	case "eu-central-2":
		return LogStreamEventBridgeSinkRegionEnumEuCentral2, nil
	case "eu-north-1":
		return LogStreamEventBridgeSinkRegionEnumEuNorth1, nil
	case "eu-south-1":
		return LogStreamEventBridgeSinkRegionEnumEuSouth1, nil
	case "eu-south-2":
		return LogStreamEventBridgeSinkRegionEnumEuSouth2, nil
	case "eu-west-1":
		return LogStreamEventBridgeSinkRegionEnumEuWest1, nil
	case "eu-west-2":
		return LogStreamEventBridgeSinkRegionEnumEuWest2, nil
	case "eu-west-3":
		return LogStreamEventBridgeSinkRegionEnumEuWest3, nil
	case "il-central-1":
		return LogStreamEventBridgeSinkRegionEnumIlCentral1, nil
	case "me-central-1":
		return LogStreamEventBridgeSinkRegionEnumMeCentral1, nil
	case "me-south-1":
		return LogStreamEventBridgeSinkRegionEnumMeSouth1, nil
	case "mx-central-1":
		return LogStreamEventBridgeSinkRegionEnumMxCentral1, nil
	case "sa-east-1":
		return LogStreamEventBridgeSinkRegionEnumSaEast1, nil
	case "us-gov-east-1":
		return LogStreamEventBridgeSinkRegionEnumUsGovEast1, nil
	case "us-gov-west-1":
		return LogStreamEventBridgeSinkRegionEnumUsGovWest1, nil
	case "us-east-1":
		return LogStreamEventBridgeSinkRegionEnumUsEast1, nil
	case "us-east-2":
		return LogStreamEventBridgeSinkRegionEnumUsEast2, nil
	case "us-west-1":
		return LogStreamEventBridgeSinkRegionEnumUsWest1, nil
	case "us-west-2":
		return LogStreamEventBridgeSinkRegionEnumUsWest2, nil
	}
	var t LogStreamEventBridgeSinkRegionEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamEventBridgeSinkRegionEnum) Ptr() *LogStreamEventBridgeSinkRegionEnum {
	return &l
}

type LogStreamEventGridEnum = string

// Azure Region Name
type LogStreamEventGridRegionEnum string

const (
	LogStreamEventGridRegionEnumAustraliacentral   LogStreamEventGridRegionEnum = "australiacentral"
	LogStreamEventGridRegionEnumAustraliaeast      LogStreamEventGridRegionEnum = "australiaeast"
	LogStreamEventGridRegionEnumAustraliasoutheast LogStreamEventGridRegionEnum = "australiasoutheast"
	LogStreamEventGridRegionEnumBrazilsouth        LogStreamEventGridRegionEnum = "brazilsouth"
	LogStreamEventGridRegionEnumCanadacentral      LogStreamEventGridRegionEnum = "canadacentral"
	LogStreamEventGridRegionEnumCanadaeast         LogStreamEventGridRegionEnum = "canadaeast"
	LogStreamEventGridRegionEnumCentralindia       LogStreamEventGridRegionEnum = "centralindia"
	LogStreamEventGridRegionEnumCentralus          LogStreamEventGridRegionEnum = "centralus"
	LogStreamEventGridRegionEnumEastasia           LogStreamEventGridRegionEnum = "eastasia"
	LogStreamEventGridRegionEnumEastus             LogStreamEventGridRegionEnum = "eastus"
	LogStreamEventGridRegionEnumEastus2            LogStreamEventGridRegionEnum = "eastus2"
	LogStreamEventGridRegionEnumFrancecentral      LogStreamEventGridRegionEnum = "francecentral"
	LogStreamEventGridRegionEnumGermanywestcentral LogStreamEventGridRegionEnum = "germanywestcentral"
	LogStreamEventGridRegionEnumJapaneast          LogStreamEventGridRegionEnum = "japaneast"
	LogStreamEventGridRegionEnumJapanwest          LogStreamEventGridRegionEnum = "japanwest"
	LogStreamEventGridRegionEnumKoreacentral       LogStreamEventGridRegionEnum = "koreacentral"
	LogStreamEventGridRegionEnumKoreasouth         LogStreamEventGridRegionEnum = "koreasouth"
	LogStreamEventGridRegionEnumNorthcentralus     LogStreamEventGridRegionEnum = "northcentralus"
	LogStreamEventGridRegionEnumNortheurope        LogStreamEventGridRegionEnum = "northeurope"
	LogStreamEventGridRegionEnumNorwayeast         LogStreamEventGridRegionEnum = "norwayeast"
	LogStreamEventGridRegionEnumSouthafricanorth   LogStreamEventGridRegionEnum = "southafricanorth"
	LogStreamEventGridRegionEnumSouthcentralus     LogStreamEventGridRegionEnum = "southcentralus"
	LogStreamEventGridRegionEnumSoutheastasia      LogStreamEventGridRegionEnum = "southeastasia"
	LogStreamEventGridRegionEnumSouthindia         LogStreamEventGridRegionEnum = "southindia"
	LogStreamEventGridRegionEnumSwedencentral      LogStreamEventGridRegionEnum = "swedencentral"
	LogStreamEventGridRegionEnumSwitzerlandnorth   LogStreamEventGridRegionEnum = "switzerlandnorth"
	LogStreamEventGridRegionEnumUaenorth           LogStreamEventGridRegionEnum = "uaenorth"
	LogStreamEventGridRegionEnumUksouth            LogStreamEventGridRegionEnum = "uksouth"
	LogStreamEventGridRegionEnumUkwest             LogStreamEventGridRegionEnum = "ukwest"
	LogStreamEventGridRegionEnumWestcentralus      LogStreamEventGridRegionEnum = "westcentralus"
	LogStreamEventGridRegionEnumWesteurope         LogStreamEventGridRegionEnum = "westeurope"
	LogStreamEventGridRegionEnumWestindia          LogStreamEventGridRegionEnum = "westindia"
	LogStreamEventGridRegionEnumWestus             LogStreamEventGridRegionEnum = "westus"
	LogStreamEventGridRegionEnumWestus2            LogStreamEventGridRegionEnum = "westus2"
)

func NewLogStreamEventGridRegionEnumFromString(s string) (LogStreamEventGridRegionEnum, error) {
	switch s {
	case "australiacentral":
		return LogStreamEventGridRegionEnumAustraliacentral, nil
	case "australiaeast":
		return LogStreamEventGridRegionEnumAustraliaeast, nil
	case "australiasoutheast":
		return LogStreamEventGridRegionEnumAustraliasoutheast, nil
	case "brazilsouth":
		return LogStreamEventGridRegionEnumBrazilsouth, nil
	case "canadacentral":
		return LogStreamEventGridRegionEnumCanadacentral, nil
	case "canadaeast":
		return LogStreamEventGridRegionEnumCanadaeast, nil
	case "centralindia":
		return LogStreamEventGridRegionEnumCentralindia, nil
	case "centralus":
		return LogStreamEventGridRegionEnumCentralus, nil
	case "eastasia":
		return LogStreamEventGridRegionEnumEastasia, nil
	case "eastus":
		return LogStreamEventGridRegionEnumEastus, nil
	case "eastus2":
		return LogStreamEventGridRegionEnumEastus2, nil
	case "francecentral":
		return LogStreamEventGridRegionEnumFrancecentral, nil
	case "germanywestcentral":
		return LogStreamEventGridRegionEnumGermanywestcentral, nil
	case "japaneast":
		return LogStreamEventGridRegionEnumJapaneast, nil
	case "japanwest":
		return LogStreamEventGridRegionEnumJapanwest, nil
	case "koreacentral":
		return LogStreamEventGridRegionEnumKoreacentral, nil
	case "koreasouth":
		return LogStreamEventGridRegionEnumKoreasouth, nil
	case "northcentralus":
		return LogStreamEventGridRegionEnumNorthcentralus, nil
	case "northeurope":
		return LogStreamEventGridRegionEnumNortheurope, nil
	case "norwayeast":
		return LogStreamEventGridRegionEnumNorwayeast, nil
	case "southafricanorth":
		return LogStreamEventGridRegionEnumSouthafricanorth, nil
	case "southcentralus":
		return LogStreamEventGridRegionEnumSouthcentralus, nil
	case "southeastasia":
		return LogStreamEventGridRegionEnumSoutheastasia, nil
	case "southindia":
		return LogStreamEventGridRegionEnumSouthindia, nil
	case "swedencentral":
		return LogStreamEventGridRegionEnumSwedencentral, nil
	case "switzerlandnorth":
		return LogStreamEventGridRegionEnumSwitzerlandnorth, nil
	case "uaenorth":
		return LogStreamEventGridRegionEnumUaenorth, nil
	case "uksouth":
		return LogStreamEventGridRegionEnumUksouth, nil
	case "ukwest":
		return LogStreamEventGridRegionEnumUkwest, nil
	case "westcentralus":
		return LogStreamEventGridRegionEnumWestcentralus, nil
	case "westeurope":
		return LogStreamEventGridRegionEnumWesteurope, nil
	case "westindia":
		return LogStreamEventGridRegionEnumWestindia, nil
	case "westus":
		return LogStreamEventGridRegionEnumWestus, nil
	case "westus2":
		return LogStreamEventGridRegionEnumWestus2, nil
	}
	var t LogStreamEventGridRegionEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamEventGridRegionEnum) Ptr() *LogStreamEventGridRegionEnum {
	return &l
}

var (
	logStreamEventGridResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamEventGridResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamEventGridResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamEventGridResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamEventGridResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamEventGridResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamEventGridResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamEventGridResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamEventGridResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string                 `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum    `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamEventGridEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter      `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig     `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamEventGridSink `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamEventGridResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamEventGridResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamEventGridResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamEventGridResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamEventGridResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamEventGridResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamEventGridResponseSchema) GetSink() LogStreamEventGridSink {
	if l == nil || l.Sink == nil {
		return LogStreamEventGridSink{}
	}
	return *l.Sink
}

func (l *LogStreamEventGridResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamEventGridResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamEventGridResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamEventGridResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamEventGridResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetType(type_ *LogStreamEventGridEnum) {
	l.Type = type_
	l.require(logStreamEventGridResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamEventGridResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamEventGridResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamEventGridResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridResponseSchema) SetSink(sink *LogStreamEventGridSink) {
	l.Sink = sink
	l.require(logStreamEventGridResponseSchemaFieldSink)
}

func (l *LogStreamEventGridResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamEventGridResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamEventGridResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamEventGridResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamEventGridResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamEventGridResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamEventGridSinkFieldAzureSubscriptionID = big.NewInt(1 << 0)
	logStreamEventGridSinkFieldAzureRegion         = big.NewInt(1 << 1)
	logStreamEventGridSinkFieldAzureResourceGroup  = big.NewInt(1 << 2)
	logStreamEventGridSinkFieldAzurePartnerTopic   = big.NewInt(1 << 3)
)

type LogStreamEventGridSink struct {
	// Subscription ID
	AzureSubscriptionID string                       `json:"azureSubscriptionId" url:"azureSubscriptionId"`
	AzureRegion         LogStreamEventGridRegionEnum `json:"azureRegion" url:"azureRegion"`
	// Resource Group
	AzureResourceGroup string `json:"azureResourceGroup" url:"azureResourceGroup"`
	// Partner Topic
	AzurePartnerTopic *string `json:"azurePartnerTopic,omitempty" url:"azurePartnerTopic,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamEventGridSink) GetAzureSubscriptionID() string {
	if l == nil {
		return ""
	}
	return l.AzureSubscriptionID
}

func (l *LogStreamEventGridSink) GetAzureRegion() LogStreamEventGridRegionEnum {
	if l == nil {
		return ""
	}
	return l.AzureRegion
}

func (l *LogStreamEventGridSink) GetAzureResourceGroup() string {
	if l == nil {
		return ""
	}
	return l.AzureResourceGroup
}

func (l *LogStreamEventGridSink) GetAzurePartnerTopic() string {
	if l == nil || l.AzurePartnerTopic == nil {
		return ""
	}
	return *l.AzurePartnerTopic
}

func (l *LogStreamEventGridSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamEventGridSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetAzureSubscriptionID sets the AzureSubscriptionID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridSink) SetAzureSubscriptionID(azureSubscriptionID string) {
	l.AzureSubscriptionID = azureSubscriptionID
	l.require(logStreamEventGridSinkFieldAzureSubscriptionID)
}

// SetAzureRegion sets the AzureRegion field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridSink) SetAzureRegion(azureRegion LogStreamEventGridRegionEnum) {
	l.AzureRegion = azureRegion
	l.require(logStreamEventGridSinkFieldAzureRegion)
}

// SetAzureResourceGroup sets the AzureResourceGroup field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridSink) SetAzureResourceGroup(azureResourceGroup string) {
	l.AzureResourceGroup = azureResourceGroup
	l.require(logStreamEventGridSinkFieldAzureResourceGroup)
}

// SetAzurePartnerTopic sets the AzurePartnerTopic field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamEventGridSink) SetAzurePartnerTopic(azurePartnerTopic *string) {
	l.AzurePartnerTopic = azurePartnerTopic
	l.require(logStreamEventGridSinkFieldAzurePartnerTopic)
}

func (l *LogStreamEventGridSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamEventGridSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamEventGridSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamEventGridSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamEventGridSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamEventGridSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamFilterFieldType = big.NewInt(1 << 0)
	logStreamFilterFieldName = big.NewInt(1 << 1)
)

type LogStreamFilter struct {
	Type *LogStreamFilterTypeEnum      `json:"type,omitempty" url:"type,omitempty"`
	Name *LogStreamFilterGroupNameEnum `json:"name,omitempty" url:"name,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamFilter) GetName() LogStreamFilterGroupNameEnum {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamFilter) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamFilter) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamFilter) SetType(type_ *LogStreamFilterTypeEnum) {
	l.Type = type_
	l.require(logStreamFilterFieldType)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamFilter) SetName(name *LogStreamFilterGroupNameEnum) {
	l.Name = name
	l.require(logStreamFilterFieldName)
}

func (l *LogStreamFilter) UnmarshalJSON(data []byte) error {
	type embed LogStreamFilter
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamFilter(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamFilter) MarshalJSON() ([]byte, error) {
	type embed LogStreamFilter
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamFilter) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

// Category group name
type LogStreamFilterGroupNameEnum string

const (
	LogStreamFilterGroupNameEnumAuthLoginFail            LogStreamFilterGroupNameEnum = "auth.login.fail"
	LogStreamFilterGroupNameEnumAuthLoginNotification    LogStreamFilterGroupNameEnum = "auth.login.notification"
	LogStreamFilterGroupNameEnumAuthLoginSuccess         LogStreamFilterGroupNameEnum = "auth.login.success"
	LogStreamFilterGroupNameEnumAuthLogoutFail           LogStreamFilterGroupNameEnum = "auth.logout.fail"
	LogStreamFilterGroupNameEnumAuthLogoutSuccess        LogStreamFilterGroupNameEnum = "auth.logout.success"
	LogStreamFilterGroupNameEnumAuthSignupFail           LogStreamFilterGroupNameEnum = "auth.signup.fail"
	LogStreamFilterGroupNameEnumAuthSignupSuccess        LogStreamFilterGroupNameEnum = "auth.signup.success"
	LogStreamFilterGroupNameEnumAuthSilentAuthFail       LogStreamFilterGroupNameEnum = "auth.silent_auth.fail"
	LogStreamFilterGroupNameEnumAuthSilentAuthSuccess    LogStreamFilterGroupNameEnum = "auth.silent_auth.success"
	LogStreamFilterGroupNameEnumAuthTokenExchangeFail    LogStreamFilterGroupNameEnum = "auth.token_exchange.fail"
	LogStreamFilterGroupNameEnumAuthTokenExchangeSuccess LogStreamFilterGroupNameEnum = "auth.token_exchange.success"
	LogStreamFilterGroupNameEnumManagementFail           LogStreamFilterGroupNameEnum = "management.fail"
	LogStreamFilterGroupNameEnumManagementSuccess        LogStreamFilterGroupNameEnum = "management.success"
	LogStreamFilterGroupNameEnumSCIMEvent                LogStreamFilterGroupNameEnum = "scim.event"
	LogStreamFilterGroupNameEnumSystemNotification       LogStreamFilterGroupNameEnum = "system.notification"
	LogStreamFilterGroupNameEnumUserFail                 LogStreamFilterGroupNameEnum = "user.fail"
	LogStreamFilterGroupNameEnumUserNotification         LogStreamFilterGroupNameEnum = "user.notification"
	LogStreamFilterGroupNameEnumUserSuccess              LogStreamFilterGroupNameEnum = "user.success"
	LogStreamFilterGroupNameEnumActions                  LogStreamFilterGroupNameEnum = "actions"
	LogStreamFilterGroupNameEnumOther                    LogStreamFilterGroupNameEnum = "other"
)

func NewLogStreamFilterGroupNameEnumFromString(s string) (LogStreamFilterGroupNameEnum, error) {
	switch s {
	case "auth.login.fail":
		return LogStreamFilterGroupNameEnumAuthLoginFail, nil
	case "auth.login.notification":
		return LogStreamFilterGroupNameEnumAuthLoginNotification, nil
	case "auth.login.success":
		return LogStreamFilterGroupNameEnumAuthLoginSuccess, nil
	case "auth.logout.fail":
		return LogStreamFilterGroupNameEnumAuthLogoutFail, nil
	case "auth.logout.success":
		return LogStreamFilterGroupNameEnumAuthLogoutSuccess, nil
	case "auth.signup.fail":
		return LogStreamFilterGroupNameEnumAuthSignupFail, nil
	case "auth.signup.success":
		return LogStreamFilterGroupNameEnumAuthSignupSuccess, nil
	case "auth.silent_auth.fail":
		return LogStreamFilterGroupNameEnumAuthSilentAuthFail, nil
	case "auth.silent_auth.success":
		return LogStreamFilterGroupNameEnumAuthSilentAuthSuccess, nil
	case "auth.token_exchange.fail":
		return LogStreamFilterGroupNameEnumAuthTokenExchangeFail, nil
	case "auth.token_exchange.success":
		return LogStreamFilterGroupNameEnumAuthTokenExchangeSuccess, nil
	case "management.fail":
		return LogStreamFilterGroupNameEnumManagementFail, nil
	case "management.success":
		return LogStreamFilterGroupNameEnumManagementSuccess, nil
	case "scim.event":
		return LogStreamFilterGroupNameEnumSCIMEvent, nil
	case "system.notification":
		return LogStreamFilterGroupNameEnumSystemNotification, nil
	case "user.fail":
		return LogStreamFilterGroupNameEnumUserFail, nil
	case "user.notification":
		return LogStreamFilterGroupNameEnumUserNotification, nil
	case "user.success":
		return LogStreamFilterGroupNameEnumUserSuccess, nil
	case "actions":
		return LogStreamFilterGroupNameEnumActions, nil
	case "other":
		return LogStreamFilterGroupNameEnumOther, nil
	}
	var t LogStreamFilterGroupNameEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamFilterGroupNameEnum) Ptr() *LogStreamFilterGroupNameEnum {
	return &l
}

// Filter type. Currently `category` is the only valid type.
type LogStreamFilterTypeEnum = string

// HTTP JSON format
type LogStreamHTTPContentFormatEnum string

const (
	LogStreamHTTPContentFormatEnumJsonarray  LogStreamHTTPContentFormatEnum = "JSONARRAY"
	LogStreamHTTPContentFormatEnumJsonlines  LogStreamHTTPContentFormatEnum = "JSONLINES"
	LogStreamHTTPContentFormatEnumJsonobject LogStreamHTTPContentFormatEnum = "JSONOBJECT"
)

func NewLogStreamHTTPContentFormatEnumFromString(s string) (LogStreamHTTPContentFormatEnum, error) {
	switch s {
	case "JSONARRAY":
		return LogStreamHTTPContentFormatEnumJsonarray, nil
	case "JSONLINES":
		return LogStreamHTTPContentFormatEnumJsonlines, nil
	case "JSONOBJECT":
		return LogStreamHTTPContentFormatEnumJsonobject, nil
	}
	var t LogStreamHTTPContentFormatEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamHTTPContentFormatEnum) Ptr() *LogStreamHTTPContentFormatEnum {
	return &l
}

type LogStreamHTTPEnum = string

var (
	logStreamHTTPResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamHTTPResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamHTTPResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamHTTPResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamHTTPResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamHTTPResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamHTTPResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamHTTPResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamHTTPResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string              `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamHTTPEnum   `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter  `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamHTTPSink  `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamHTTPResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamHTTPResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamHTTPResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamHTTPResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamHTTPResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamHTTPResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamHTTPResponseSchema) GetSink() LogStreamHTTPSink {
	if l == nil || l.Sink == nil {
		return LogStreamHTTPSink{}
	}
	return *l.Sink
}

func (l *LogStreamHTTPResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamHTTPResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamHTTPResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamHTTPResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamHTTPResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetType(type_ *LogStreamHTTPEnum) {
	l.Type = type_
	l.require(logStreamHTTPResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamHTTPResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamHTTPResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamHTTPResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPResponseSchema) SetSink(sink *LogStreamHTTPSink) {
	l.Sink = sink
	l.require(logStreamHTTPResponseSchemaFieldSink)
}

func (l *LogStreamHTTPResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamHTTPResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamHTTPResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamHTTPResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamHTTPResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamHTTPResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamHTTPSinkFieldHTTPAuthorization = big.NewInt(1 << 0)
	logStreamHTTPSinkFieldHTTPContentFormat = big.NewInt(1 << 1)
	logStreamHTTPSinkFieldHTTPContentType   = big.NewInt(1 << 2)
	logStreamHTTPSinkFieldHTTPEndpoint      = big.NewInt(1 << 3)
	logStreamHTTPSinkFieldHTTPCustomHeaders = big.NewInt(1 << 4)
)

type LogStreamHTTPSink struct {
	// HTTP Authorization header
	HTTPAuthorization *string                         `json:"httpAuthorization,omitempty" url:"httpAuthorization,omitempty"`
	HTTPContentFormat *LogStreamHTTPContentFormatEnum `json:"httpContentFormat,omitempty" url:"httpContentFormat,omitempty"`
	// HTTP Content-Type header
	HTTPContentType *string `json:"httpContentType,omitempty" url:"httpContentType,omitempty"`
	// HTTP endpoint
	HTTPEndpoint string `json:"httpEndpoint" url:"httpEndpoint"`
	// custom HTTP headers
	HTTPCustomHeaders []*HTTPCustomHeader `json:"httpCustomHeaders,omitempty" url:"httpCustomHeaders,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamHTTPSink) GetHTTPAuthorization() string {
	if l == nil || l.HTTPAuthorization == nil {
		return ""
	}
	return *l.HTTPAuthorization
}

func (l *LogStreamHTTPSink) GetHTTPContentFormat() LogStreamHTTPContentFormatEnum {
	if l == nil || l.HTTPContentFormat == nil {
		return ""
	}
	return *l.HTTPContentFormat
}

func (l *LogStreamHTTPSink) GetHTTPContentType() string {
	if l == nil || l.HTTPContentType == nil {
		return ""
	}
	return *l.HTTPContentType
}

func (l *LogStreamHTTPSink) GetHTTPEndpoint() string {
	if l == nil {
		return ""
	}
	return l.HTTPEndpoint
}

func (l *LogStreamHTTPSink) GetHTTPCustomHeaders() []*HTTPCustomHeader {
	if l == nil || l.HTTPCustomHeaders == nil {
		return nil
	}
	return l.HTTPCustomHeaders
}

func (l *LogStreamHTTPSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamHTTPSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetHTTPAuthorization sets the HTTPAuthorization field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPSink) SetHTTPAuthorization(httpAuthorization *string) {
	l.HTTPAuthorization = httpAuthorization
	l.require(logStreamHTTPSinkFieldHTTPAuthorization)
}

// SetHTTPContentFormat sets the HTTPContentFormat field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPSink) SetHTTPContentFormat(httpContentFormat *LogStreamHTTPContentFormatEnum) {
	l.HTTPContentFormat = httpContentFormat
	l.require(logStreamHTTPSinkFieldHTTPContentFormat)
}

// SetHTTPContentType sets the HTTPContentType field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPSink) SetHTTPContentType(httpContentType *string) {
	l.HTTPContentType = httpContentType
	l.require(logStreamHTTPSinkFieldHTTPContentType)
}

// SetHTTPEndpoint sets the HTTPEndpoint field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPSink) SetHTTPEndpoint(httpEndpoint string) {
	l.HTTPEndpoint = httpEndpoint
	l.require(logStreamHTTPSinkFieldHTTPEndpoint)
}

// SetHTTPCustomHeaders sets the HTTPCustomHeaders field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamHTTPSink) SetHTTPCustomHeaders(httpCustomHeaders []*HTTPCustomHeader) {
	l.HTTPCustomHeaders = httpCustomHeaders
	l.require(logStreamHTTPSinkFieldHTTPCustomHeaders)
}

func (l *LogStreamHTTPSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamHTTPSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamHTTPSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamHTTPSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamHTTPSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamHTTPSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type LogStreamMixpanelEnum = string

// Mixpanel Region
type LogStreamMixpanelRegionEnum string

const (
	LogStreamMixpanelRegionEnumUs LogStreamMixpanelRegionEnum = "us"
	LogStreamMixpanelRegionEnumEu LogStreamMixpanelRegionEnum = "eu"
)

func NewLogStreamMixpanelRegionEnumFromString(s string) (LogStreamMixpanelRegionEnum, error) {
	switch s {
	case "us":
		return LogStreamMixpanelRegionEnumUs, nil
	case "eu":
		return LogStreamMixpanelRegionEnumEu, nil
	}
	var t LogStreamMixpanelRegionEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamMixpanelRegionEnum) Ptr() *LogStreamMixpanelRegionEnum {
	return &l
}

var (
	logStreamMixpanelResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamMixpanelResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamMixpanelResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamMixpanelResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamMixpanelResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamMixpanelResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamMixpanelResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamMixpanelResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamMixpanelResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string                `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum   `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamMixpanelEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter     `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig    `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamMixpanelSink `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamMixpanelResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamMixpanelResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamMixpanelResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamMixpanelResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamMixpanelResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamMixpanelResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamMixpanelResponseSchema) GetSink() LogStreamMixpanelSink {
	if l == nil || l.Sink == nil {
		return LogStreamMixpanelSink{}
	}
	return *l.Sink
}

func (l *LogStreamMixpanelResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamMixpanelResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamMixpanelResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamMixpanelResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamMixpanelResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetType(type_ *LogStreamMixpanelEnum) {
	l.Type = type_
	l.require(logStreamMixpanelResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamMixpanelResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamMixpanelResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamMixpanelResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelResponseSchema) SetSink(sink *LogStreamMixpanelSink) {
	l.Sink = sink
	l.require(logStreamMixpanelResponseSchemaFieldSink)
}

func (l *LogStreamMixpanelResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamMixpanelResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamMixpanelResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamMixpanelResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamMixpanelResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamMixpanelResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamMixpanelSinkFieldMixpanelRegion                 = big.NewInt(1 << 0)
	logStreamMixpanelSinkFieldMixpanelProjectID              = big.NewInt(1 << 1)
	logStreamMixpanelSinkFieldMixpanelServiceAccountUsername = big.NewInt(1 << 2)
	logStreamMixpanelSinkFieldMixpanelServiceAccountPassword = big.NewInt(1 << 3)
)

type LogStreamMixpanelSink struct {
	MixpanelRegion LogStreamMixpanelRegionEnum `json:"mixpanelRegion" url:"mixpanelRegion"`
	// Mixpanel Project Id
	MixpanelProjectID string `json:"mixpanelProjectId" url:"mixpanelProjectId"`
	// Mixpanel Service Account Username
	MixpanelServiceAccountUsername string `json:"mixpanelServiceAccountUsername" url:"mixpanelServiceAccountUsername"`
	// Mixpanel Service Account Password
	MixpanelServiceAccountPassword string `json:"mixpanelServiceAccountPassword" url:"mixpanelServiceAccountPassword"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamMixpanelSink) GetMixpanelRegion() LogStreamMixpanelRegionEnum {
	if l == nil {
		return ""
	}
	return l.MixpanelRegion
}

func (l *LogStreamMixpanelSink) GetMixpanelProjectID() string {
	if l == nil {
		return ""
	}
	return l.MixpanelProjectID
}

func (l *LogStreamMixpanelSink) GetMixpanelServiceAccountUsername() string {
	if l == nil {
		return ""
	}
	return l.MixpanelServiceAccountUsername
}

func (l *LogStreamMixpanelSink) GetMixpanelServiceAccountPassword() string {
	if l == nil {
		return ""
	}
	return l.MixpanelServiceAccountPassword
}

func (l *LogStreamMixpanelSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamMixpanelSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetMixpanelRegion sets the MixpanelRegion field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSink) SetMixpanelRegion(mixpanelRegion LogStreamMixpanelRegionEnum) {
	l.MixpanelRegion = mixpanelRegion
	l.require(logStreamMixpanelSinkFieldMixpanelRegion)
}

// SetMixpanelProjectID sets the MixpanelProjectID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSink) SetMixpanelProjectID(mixpanelProjectID string) {
	l.MixpanelProjectID = mixpanelProjectID
	l.require(logStreamMixpanelSinkFieldMixpanelProjectID)
}

// SetMixpanelServiceAccountUsername sets the MixpanelServiceAccountUsername field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSink) SetMixpanelServiceAccountUsername(mixpanelServiceAccountUsername string) {
	l.MixpanelServiceAccountUsername = mixpanelServiceAccountUsername
	l.require(logStreamMixpanelSinkFieldMixpanelServiceAccountUsername)
}

// SetMixpanelServiceAccountPassword sets the MixpanelServiceAccountPassword field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSink) SetMixpanelServiceAccountPassword(mixpanelServiceAccountPassword string) {
	l.MixpanelServiceAccountPassword = mixpanelServiceAccountPassword
	l.require(logStreamMixpanelSinkFieldMixpanelServiceAccountPassword)
}

func (l *LogStreamMixpanelSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamMixpanelSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamMixpanelSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamMixpanelSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamMixpanelSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamMixpanelSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamMixpanelSinkPatchFieldMixpanelRegion                 = big.NewInt(1 << 0)
	logStreamMixpanelSinkPatchFieldMixpanelProjectID              = big.NewInt(1 << 1)
	logStreamMixpanelSinkPatchFieldMixpanelServiceAccountUsername = big.NewInt(1 << 2)
	logStreamMixpanelSinkPatchFieldMixpanelServiceAccountPassword = big.NewInt(1 << 3)
)

type LogStreamMixpanelSinkPatch struct {
	MixpanelRegion LogStreamMixpanelRegionEnum `json:"mixpanelRegion" url:"mixpanelRegion"`
	// Mixpanel Project Id
	MixpanelProjectID string `json:"mixpanelProjectId" url:"mixpanelProjectId"`
	// Mixpanel Service Account Username
	MixpanelServiceAccountUsername string `json:"mixpanelServiceAccountUsername" url:"mixpanelServiceAccountUsername"`
	// Mixpanel Service Account Password
	MixpanelServiceAccountPassword *string `json:"mixpanelServiceAccountPassword,omitempty" url:"mixpanelServiceAccountPassword,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamMixpanelSinkPatch) GetMixpanelRegion() LogStreamMixpanelRegionEnum {
	if l == nil {
		return ""
	}
	return l.MixpanelRegion
}

func (l *LogStreamMixpanelSinkPatch) GetMixpanelProjectID() string {
	if l == nil {
		return ""
	}
	return l.MixpanelProjectID
}

func (l *LogStreamMixpanelSinkPatch) GetMixpanelServiceAccountUsername() string {
	if l == nil {
		return ""
	}
	return l.MixpanelServiceAccountUsername
}

func (l *LogStreamMixpanelSinkPatch) GetMixpanelServiceAccountPassword() string {
	if l == nil || l.MixpanelServiceAccountPassword == nil {
		return ""
	}
	return *l.MixpanelServiceAccountPassword
}

func (l *LogStreamMixpanelSinkPatch) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamMixpanelSinkPatch) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetMixpanelRegion sets the MixpanelRegion field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSinkPatch) SetMixpanelRegion(mixpanelRegion LogStreamMixpanelRegionEnum) {
	l.MixpanelRegion = mixpanelRegion
	l.require(logStreamMixpanelSinkPatchFieldMixpanelRegion)
}

// SetMixpanelProjectID sets the MixpanelProjectID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSinkPatch) SetMixpanelProjectID(mixpanelProjectID string) {
	l.MixpanelProjectID = mixpanelProjectID
	l.require(logStreamMixpanelSinkPatchFieldMixpanelProjectID)
}

// SetMixpanelServiceAccountUsername sets the MixpanelServiceAccountUsername field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSinkPatch) SetMixpanelServiceAccountUsername(mixpanelServiceAccountUsername string) {
	l.MixpanelServiceAccountUsername = mixpanelServiceAccountUsername
	l.require(logStreamMixpanelSinkPatchFieldMixpanelServiceAccountUsername)
}

// SetMixpanelServiceAccountPassword sets the MixpanelServiceAccountPassword field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamMixpanelSinkPatch) SetMixpanelServiceAccountPassword(mixpanelServiceAccountPassword *string) {
	l.MixpanelServiceAccountPassword = mixpanelServiceAccountPassword
	l.require(logStreamMixpanelSinkPatchFieldMixpanelServiceAccountPassword)
}

func (l *LogStreamMixpanelSinkPatch) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamMixpanelSinkPatch
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamMixpanelSinkPatch(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamMixpanelSinkPatch) MarshalJSON() ([]byte, error) {
	type embed LogStreamMixpanelSinkPatch
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamMixpanelSinkPatch) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type LogStreamPiiAlgorithmEnum = string

var (
	logStreamPiiConfigFieldLogFields = big.NewInt(1 << 0)
	logStreamPiiConfigFieldMethod    = big.NewInt(1 << 1)
	logStreamPiiConfigFieldAlgorithm = big.NewInt(1 << 2)
)

type LogStreamPiiConfig struct {
	LogFields []LogStreamPiiLogFieldsEnum `json:"log_fields" url:"log_fields"`
	Method    *LogStreamPiiMethodEnum     `json:"method,omitempty" url:"method,omitempty"`
	Algorithm *LogStreamPiiAlgorithmEnum  `json:"algorithm,omitempty" url:"algorithm,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamPiiConfig) GetLogFields() []LogStreamPiiLogFieldsEnum {
	if l == nil {
		return nil
	}
	return l.LogFields
}

func (l *LogStreamPiiConfig) GetMethod() LogStreamPiiMethodEnum {
	if l == nil || l.Method == nil {
		return ""
	}
	return *l.Method
}

func (l *LogStreamPiiConfig) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamPiiConfig) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetLogFields sets the LogFields field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamPiiConfig) SetLogFields(logFields []LogStreamPiiLogFieldsEnum) {
	l.LogFields = logFields
	l.require(logStreamPiiConfigFieldLogFields)
}

// SetMethod sets the Method field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamPiiConfig) SetMethod(method *LogStreamPiiMethodEnum) {
	l.Method = method
	l.require(logStreamPiiConfigFieldMethod)
}

// SetAlgorithm sets the Algorithm field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamPiiConfig) SetAlgorithm(algorithm *LogStreamPiiAlgorithmEnum) {
	l.Algorithm = algorithm
	l.require(logStreamPiiConfigFieldAlgorithm)
}

func (l *LogStreamPiiConfig) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamPiiConfig
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamPiiConfig(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamPiiConfig) MarshalJSON() ([]byte, error) {
	type embed LogStreamPiiConfig
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamPiiConfig) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type LogStreamPiiLogFieldsEnum string

const (
	LogStreamPiiLogFieldsEnumFirstName LogStreamPiiLogFieldsEnum = "first_name"
	LogStreamPiiLogFieldsEnumLastName  LogStreamPiiLogFieldsEnum = "last_name"
	LogStreamPiiLogFieldsEnumUsername  LogStreamPiiLogFieldsEnum = "username"
	LogStreamPiiLogFieldsEnumEmail     LogStreamPiiLogFieldsEnum = "email"
	LogStreamPiiLogFieldsEnumPhone     LogStreamPiiLogFieldsEnum = "phone"
	LogStreamPiiLogFieldsEnumAddress   LogStreamPiiLogFieldsEnum = "address"
)

func NewLogStreamPiiLogFieldsEnumFromString(s string) (LogStreamPiiLogFieldsEnum, error) {
	switch s {
	case "first_name":
		return LogStreamPiiLogFieldsEnumFirstName, nil
	case "last_name":
		return LogStreamPiiLogFieldsEnumLastName, nil
	case "username":
		return LogStreamPiiLogFieldsEnumUsername, nil
	case "email":
		return LogStreamPiiLogFieldsEnumEmail, nil
	case "phone":
		return LogStreamPiiLogFieldsEnumPhone, nil
	case "address":
		return LogStreamPiiLogFieldsEnumAddress, nil
	}
	var t LogStreamPiiLogFieldsEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamPiiLogFieldsEnum) Ptr() *LogStreamPiiLogFieldsEnum {
	return &l
}

type LogStreamPiiMethodEnum string

const (
	LogStreamPiiMethodEnumMask LogStreamPiiMethodEnum = "mask"
	LogStreamPiiMethodEnumHash LogStreamPiiMethodEnum = "hash"
)

func NewLogStreamPiiMethodEnumFromString(s string) (LogStreamPiiMethodEnum, error) {
	switch s {
	case "mask":
		return LogStreamPiiMethodEnumMask, nil
	case "hash":
		return LogStreamPiiMethodEnumHash, nil
	}
	var t LogStreamPiiMethodEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamPiiMethodEnum) Ptr() *LogStreamPiiMethodEnum {
	return &l
}

type LogStreamResponseSchema struct {
	LogStreamHTTPResponseSchema        *LogStreamHTTPResponseSchema
	LogStreamEventBridgeResponseSchema *LogStreamEventBridgeResponseSchema
	LogStreamEventGridResponseSchema   *LogStreamEventGridResponseSchema
	LogStreamDatadogResponseSchema     *LogStreamDatadogResponseSchema
	LogStreamSplunkResponseSchema      *LogStreamSplunkResponseSchema
	LogStreamSumoResponseSchema        *LogStreamSumoResponseSchema
	LogStreamSegmentResponseSchema     *LogStreamSegmentResponseSchema
	LogStreamMixpanelResponseSchema    *LogStreamMixpanelResponseSchema

	typ string
}

func (l *LogStreamResponseSchema) GetLogStreamHTTPResponseSchema() *LogStreamHTTPResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamHTTPResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamEventBridgeResponseSchema() *LogStreamEventBridgeResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamEventBridgeResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamEventGridResponseSchema() *LogStreamEventGridResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamEventGridResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamDatadogResponseSchema() *LogStreamDatadogResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamDatadogResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamSplunkResponseSchema() *LogStreamSplunkResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamSplunkResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamSumoResponseSchema() *LogStreamSumoResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamSumoResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamSegmentResponseSchema() *LogStreamSegmentResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamSegmentResponseSchema
}

func (l *LogStreamResponseSchema) GetLogStreamMixpanelResponseSchema() *LogStreamMixpanelResponseSchema {
	if l == nil {
		return nil
	}
	return l.LogStreamMixpanelResponseSchema
}

func (l *LogStreamResponseSchema) UnmarshalJSON(data []byte) error {
	valueLogStreamHTTPResponseSchema := new(LogStreamHTTPResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamHTTPResponseSchema); err == nil {
		l.typ = "LogStreamHTTPResponseSchema"
		l.LogStreamHTTPResponseSchema = valueLogStreamHTTPResponseSchema
		return nil
	}
	valueLogStreamEventBridgeResponseSchema := new(LogStreamEventBridgeResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventBridgeResponseSchema); err == nil {
		l.typ = "LogStreamEventBridgeResponseSchema"
		l.LogStreamEventBridgeResponseSchema = valueLogStreamEventBridgeResponseSchema
		return nil
	}
	valueLogStreamEventGridResponseSchema := new(LogStreamEventGridResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventGridResponseSchema); err == nil {
		l.typ = "LogStreamEventGridResponseSchema"
		l.LogStreamEventGridResponseSchema = valueLogStreamEventGridResponseSchema
		return nil
	}
	valueLogStreamDatadogResponseSchema := new(LogStreamDatadogResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamDatadogResponseSchema); err == nil {
		l.typ = "LogStreamDatadogResponseSchema"
		l.LogStreamDatadogResponseSchema = valueLogStreamDatadogResponseSchema
		return nil
	}
	valueLogStreamSplunkResponseSchema := new(LogStreamSplunkResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSplunkResponseSchema); err == nil {
		l.typ = "LogStreamSplunkResponseSchema"
		l.LogStreamSplunkResponseSchema = valueLogStreamSplunkResponseSchema
		return nil
	}
	valueLogStreamSumoResponseSchema := new(LogStreamSumoResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSumoResponseSchema); err == nil {
		l.typ = "LogStreamSumoResponseSchema"
		l.LogStreamSumoResponseSchema = valueLogStreamSumoResponseSchema
		return nil
	}
	valueLogStreamSegmentResponseSchema := new(LogStreamSegmentResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSegmentResponseSchema); err == nil {
		l.typ = "LogStreamSegmentResponseSchema"
		l.LogStreamSegmentResponseSchema = valueLogStreamSegmentResponseSchema
		return nil
	}
	valueLogStreamMixpanelResponseSchema := new(LogStreamMixpanelResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamMixpanelResponseSchema); err == nil {
		l.typ = "LogStreamMixpanelResponseSchema"
		l.LogStreamMixpanelResponseSchema = valueLogStreamMixpanelResponseSchema
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, l)
}

func (l LogStreamResponseSchema) MarshalJSON() ([]byte, error) {
	if l.typ == "LogStreamHTTPResponseSchema" || l.LogStreamHTTPResponseSchema != nil {
		return json.Marshal(l.LogStreamHTTPResponseSchema)
	}
	if l.typ == "LogStreamEventBridgeResponseSchema" || l.LogStreamEventBridgeResponseSchema != nil {
		return json.Marshal(l.LogStreamEventBridgeResponseSchema)
	}
	if l.typ == "LogStreamEventGridResponseSchema" || l.LogStreamEventGridResponseSchema != nil {
		return json.Marshal(l.LogStreamEventGridResponseSchema)
	}
	if l.typ == "LogStreamDatadogResponseSchema" || l.LogStreamDatadogResponseSchema != nil {
		return json.Marshal(l.LogStreamDatadogResponseSchema)
	}
	if l.typ == "LogStreamSplunkResponseSchema" || l.LogStreamSplunkResponseSchema != nil {
		return json.Marshal(l.LogStreamSplunkResponseSchema)
	}
	if l.typ == "LogStreamSumoResponseSchema" || l.LogStreamSumoResponseSchema != nil {
		return json.Marshal(l.LogStreamSumoResponseSchema)
	}
	if l.typ == "LogStreamSegmentResponseSchema" || l.LogStreamSegmentResponseSchema != nil {
		return json.Marshal(l.LogStreamSegmentResponseSchema)
	}
	if l.typ == "LogStreamMixpanelResponseSchema" || l.LogStreamMixpanelResponseSchema != nil {
		return json.Marshal(l.LogStreamMixpanelResponseSchema)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", l)
}

type LogStreamResponseSchemaVisitor interface {
	VisitLogStreamHTTPResponseSchema(*LogStreamHTTPResponseSchema) error
	VisitLogStreamEventBridgeResponseSchema(*LogStreamEventBridgeResponseSchema) error
	VisitLogStreamEventGridResponseSchema(*LogStreamEventGridResponseSchema) error
	VisitLogStreamDatadogResponseSchema(*LogStreamDatadogResponseSchema) error
	VisitLogStreamSplunkResponseSchema(*LogStreamSplunkResponseSchema) error
	VisitLogStreamSumoResponseSchema(*LogStreamSumoResponseSchema) error
	VisitLogStreamSegmentResponseSchema(*LogStreamSegmentResponseSchema) error
	VisitLogStreamMixpanelResponseSchema(*LogStreamMixpanelResponseSchema) error
}

func (l *LogStreamResponseSchema) Accept(visitor LogStreamResponseSchemaVisitor) error {
	if l.typ == "LogStreamHTTPResponseSchema" || l.LogStreamHTTPResponseSchema != nil {
		return visitor.VisitLogStreamHTTPResponseSchema(l.LogStreamHTTPResponseSchema)
	}
	if l.typ == "LogStreamEventBridgeResponseSchema" || l.LogStreamEventBridgeResponseSchema != nil {
		return visitor.VisitLogStreamEventBridgeResponseSchema(l.LogStreamEventBridgeResponseSchema)
	}
	if l.typ == "LogStreamEventGridResponseSchema" || l.LogStreamEventGridResponseSchema != nil {
		return visitor.VisitLogStreamEventGridResponseSchema(l.LogStreamEventGridResponseSchema)
	}
	if l.typ == "LogStreamDatadogResponseSchema" || l.LogStreamDatadogResponseSchema != nil {
		return visitor.VisitLogStreamDatadogResponseSchema(l.LogStreamDatadogResponseSchema)
	}
	if l.typ == "LogStreamSplunkResponseSchema" || l.LogStreamSplunkResponseSchema != nil {
		return visitor.VisitLogStreamSplunkResponseSchema(l.LogStreamSplunkResponseSchema)
	}
	if l.typ == "LogStreamSumoResponseSchema" || l.LogStreamSumoResponseSchema != nil {
		return visitor.VisitLogStreamSumoResponseSchema(l.LogStreamSumoResponseSchema)
	}
	if l.typ == "LogStreamSegmentResponseSchema" || l.LogStreamSegmentResponseSchema != nil {
		return visitor.VisitLogStreamSegmentResponseSchema(l.LogStreamSegmentResponseSchema)
	}
	if l.typ == "LogStreamMixpanelResponseSchema" || l.LogStreamMixpanelResponseSchema != nil {
		return visitor.VisitLogStreamMixpanelResponseSchema(l.LogStreamMixpanelResponseSchema)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", l)
}

type LogStreamSegmentEnum = string

var (
	logStreamSegmentResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamSegmentResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamSegmentResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamSegmentResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamSegmentResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamSegmentResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamSegmentResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamSegmentResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamSegmentResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string               `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum  `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamSegmentEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter            `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig           `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSegmentSinkWriteKey `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamSegmentResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamSegmentResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamSegmentResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamSegmentResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamSegmentResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamSegmentResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamSegmentResponseSchema) GetSink() LogStreamSegmentSinkWriteKey {
	if l == nil || l.Sink == nil {
		return LogStreamSegmentSinkWriteKey{}
	}
	return *l.Sink
}

func (l *LogStreamSegmentResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamSegmentResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamSegmentResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamSegmentResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamSegmentResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetType(type_ *LogStreamSegmentEnum) {
	l.Type = type_
	l.require(logStreamSegmentResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamSegmentResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamSegmentResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamSegmentResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentResponseSchema) SetSink(sink *LogStreamSegmentSinkWriteKey) {
	l.Sink = sink
	l.require(logStreamSegmentResponseSchemaFieldSink)
}

func (l *LogStreamSegmentResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamSegmentResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamSegmentResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSegmentResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamSegmentResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamSegmentResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamSegmentSinkFieldSegmentWriteKey = big.NewInt(1 << 0)
)

type LogStreamSegmentSink struct {
	// Segment write key
	SegmentWriteKey *string `json:"segmentWriteKey,omitempty" url:"segmentWriteKey,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamSegmentSink) GetSegmentWriteKey() string {
	if l == nil || l.SegmentWriteKey == nil {
		return ""
	}
	return *l.SegmentWriteKey
}

func (l *LogStreamSegmentSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamSegmentSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetSegmentWriteKey sets the SegmentWriteKey field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentSink) SetSegmentWriteKey(segmentWriteKey *string) {
	l.SegmentWriteKey = segmentWriteKey
	l.require(logStreamSegmentSinkFieldSegmentWriteKey)
}

func (l *LogStreamSegmentSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamSegmentSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamSegmentSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSegmentSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamSegmentSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamSegmentSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamSegmentSinkWriteKeyFieldSegmentWriteKey = big.NewInt(1 << 0)
)

type LogStreamSegmentSinkWriteKey struct {
	// Segment write key
	SegmentWriteKey string `json:"segmentWriteKey" url:"segmentWriteKey"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamSegmentSinkWriteKey) GetSegmentWriteKey() string {
	if l == nil {
		return ""
	}
	return l.SegmentWriteKey
}

func (l *LogStreamSegmentSinkWriteKey) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamSegmentSinkWriteKey) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetSegmentWriteKey sets the SegmentWriteKey field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSegmentSinkWriteKey) SetSegmentWriteKey(segmentWriteKey string) {
	l.SegmentWriteKey = segmentWriteKey
	l.require(logStreamSegmentSinkWriteKeyFieldSegmentWriteKey)
}

func (l *LogStreamSegmentSinkWriteKey) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamSegmentSinkWriteKey
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamSegmentSinkWriteKey(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSegmentSinkWriteKey) MarshalJSON() ([]byte, error) {
	type embed LogStreamSegmentSinkWriteKey
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamSegmentSinkWriteKey) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type LogStreamSinkPatch struct {
	LogStreamHTTPSink          *LogStreamHTTPSink
	LogStreamDatadogSink       *LogStreamDatadogSink
	LogStreamSplunkSink        *LogStreamSplunkSink
	LogStreamSumoSink          *LogStreamSumoSink
	LogStreamSegmentSink       *LogStreamSegmentSink
	LogStreamMixpanelSinkPatch *LogStreamMixpanelSinkPatch

	typ string
}

func (l *LogStreamSinkPatch) GetLogStreamHTTPSink() *LogStreamHTTPSink {
	if l == nil {
		return nil
	}
	return l.LogStreamHTTPSink
}

func (l *LogStreamSinkPatch) GetLogStreamDatadogSink() *LogStreamDatadogSink {
	if l == nil {
		return nil
	}
	return l.LogStreamDatadogSink
}

func (l *LogStreamSinkPatch) GetLogStreamSplunkSink() *LogStreamSplunkSink {
	if l == nil {
		return nil
	}
	return l.LogStreamSplunkSink
}

func (l *LogStreamSinkPatch) GetLogStreamSumoSink() *LogStreamSumoSink {
	if l == nil {
		return nil
	}
	return l.LogStreamSumoSink
}

func (l *LogStreamSinkPatch) GetLogStreamSegmentSink() *LogStreamSegmentSink {
	if l == nil {
		return nil
	}
	return l.LogStreamSegmentSink
}

func (l *LogStreamSinkPatch) GetLogStreamMixpanelSinkPatch() *LogStreamMixpanelSinkPatch {
	if l == nil {
		return nil
	}
	return l.LogStreamMixpanelSinkPatch
}

func (l *LogStreamSinkPatch) UnmarshalJSON(data []byte) error {
	valueLogStreamHTTPSink := new(LogStreamHTTPSink)
	if err := json.Unmarshal(data, &valueLogStreamHTTPSink); err == nil {
		l.typ = "LogStreamHTTPSink"
		l.LogStreamHTTPSink = valueLogStreamHTTPSink
		return nil
	}
	valueLogStreamDatadogSink := new(LogStreamDatadogSink)
	if err := json.Unmarshal(data, &valueLogStreamDatadogSink); err == nil {
		l.typ = "LogStreamDatadogSink"
		l.LogStreamDatadogSink = valueLogStreamDatadogSink
		return nil
	}
	valueLogStreamSplunkSink := new(LogStreamSplunkSink)
	if err := json.Unmarshal(data, &valueLogStreamSplunkSink); err == nil {
		l.typ = "LogStreamSplunkSink"
		l.LogStreamSplunkSink = valueLogStreamSplunkSink
		return nil
	}
	valueLogStreamSumoSink := new(LogStreamSumoSink)
	if err := json.Unmarshal(data, &valueLogStreamSumoSink); err == nil {
		l.typ = "LogStreamSumoSink"
		l.LogStreamSumoSink = valueLogStreamSumoSink
		return nil
	}
	valueLogStreamSegmentSink := new(LogStreamSegmentSink)
	if err := json.Unmarshal(data, &valueLogStreamSegmentSink); err == nil {
		l.typ = "LogStreamSegmentSink"
		l.LogStreamSegmentSink = valueLogStreamSegmentSink
		return nil
	}
	valueLogStreamMixpanelSinkPatch := new(LogStreamMixpanelSinkPatch)
	if err := json.Unmarshal(data, &valueLogStreamMixpanelSinkPatch); err == nil {
		l.typ = "LogStreamMixpanelSinkPatch"
		l.LogStreamMixpanelSinkPatch = valueLogStreamMixpanelSinkPatch
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, l)
}

func (l LogStreamSinkPatch) MarshalJSON() ([]byte, error) {
	if l.typ == "LogStreamHTTPSink" || l.LogStreamHTTPSink != nil {
		return json.Marshal(l.LogStreamHTTPSink)
	}
	if l.typ == "LogStreamDatadogSink" || l.LogStreamDatadogSink != nil {
		return json.Marshal(l.LogStreamDatadogSink)
	}
	if l.typ == "LogStreamSplunkSink" || l.LogStreamSplunkSink != nil {
		return json.Marshal(l.LogStreamSplunkSink)
	}
	if l.typ == "LogStreamSumoSink" || l.LogStreamSumoSink != nil {
		return json.Marshal(l.LogStreamSumoSink)
	}
	if l.typ == "LogStreamSegmentSink" || l.LogStreamSegmentSink != nil {
		return json.Marshal(l.LogStreamSegmentSink)
	}
	if l.typ == "LogStreamMixpanelSinkPatch" || l.LogStreamMixpanelSinkPatch != nil {
		return json.Marshal(l.LogStreamMixpanelSinkPatch)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", l)
}

type LogStreamSinkPatchVisitor interface {
	VisitLogStreamHTTPSink(*LogStreamHTTPSink) error
	VisitLogStreamDatadogSink(*LogStreamDatadogSink) error
	VisitLogStreamSplunkSink(*LogStreamSplunkSink) error
	VisitLogStreamSumoSink(*LogStreamSumoSink) error
	VisitLogStreamSegmentSink(*LogStreamSegmentSink) error
	VisitLogStreamMixpanelSinkPatch(*LogStreamMixpanelSinkPatch) error
}

func (l *LogStreamSinkPatch) Accept(visitor LogStreamSinkPatchVisitor) error {
	if l.typ == "LogStreamHTTPSink" || l.LogStreamHTTPSink != nil {
		return visitor.VisitLogStreamHTTPSink(l.LogStreamHTTPSink)
	}
	if l.typ == "LogStreamDatadogSink" || l.LogStreamDatadogSink != nil {
		return visitor.VisitLogStreamDatadogSink(l.LogStreamDatadogSink)
	}
	if l.typ == "LogStreamSplunkSink" || l.LogStreamSplunkSink != nil {
		return visitor.VisitLogStreamSplunkSink(l.LogStreamSplunkSink)
	}
	if l.typ == "LogStreamSumoSink" || l.LogStreamSumoSink != nil {
		return visitor.VisitLogStreamSumoSink(l.LogStreamSumoSink)
	}
	if l.typ == "LogStreamSegmentSink" || l.LogStreamSegmentSink != nil {
		return visitor.VisitLogStreamSegmentSink(l.LogStreamSegmentSink)
	}
	if l.typ == "LogStreamMixpanelSinkPatch" || l.LogStreamMixpanelSinkPatch != nil {
		return visitor.VisitLogStreamMixpanelSinkPatch(l.LogStreamMixpanelSinkPatch)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", l)
}

type LogStreamSplunkEnum = string

var (
	logStreamSplunkResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamSplunkResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamSplunkResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamSplunkResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamSplunkResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamSplunkResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamSplunkResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamSplunkResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamSplunkResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string              `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamSplunkEnum `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter   `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig  `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSplunkSink `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamSplunkResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamSplunkResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamSplunkResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamSplunkResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamSplunkResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamSplunkResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamSplunkResponseSchema) GetSink() LogStreamSplunkSink {
	if l == nil || l.Sink == nil {
		return LogStreamSplunkSink{}
	}
	return *l.Sink
}

func (l *LogStreamSplunkResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamSplunkResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamSplunkResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamSplunkResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamSplunkResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetType(type_ *LogStreamSplunkEnum) {
	l.Type = type_
	l.require(logStreamSplunkResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamSplunkResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamSplunkResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamSplunkResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkResponseSchema) SetSink(sink *LogStreamSplunkSink) {
	l.Sink = sink
	l.require(logStreamSplunkResponseSchemaFieldSink)
}

func (l *LogStreamSplunkResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamSplunkResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamSplunkResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSplunkResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamSplunkResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamSplunkResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamSplunkSinkFieldSplunkDomain = big.NewInt(1 << 0)
	logStreamSplunkSinkFieldSplunkPort   = big.NewInt(1 << 1)
	logStreamSplunkSinkFieldSplunkToken  = big.NewInt(1 << 2)
	logStreamSplunkSinkFieldSplunkSecure = big.NewInt(1 << 3)
)

type LogStreamSplunkSink struct {
	// Splunk URL Endpoint
	SplunkDomain string `json:"splunkDomain" url:"splunkDomain"`
	// Port
	SplunkPort string `json:"splunkPort" url:"splunkPort"`
	// Splunk token
	SplunkToken string `json:"splunkToken" url:"splunkToken"`
	// Verify TLS certificate
	SplunkSecure bool `json:"splunkSecure" url:"splunkSecure"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamSplunkSink) GetSplunkDomain() string {
	if l == nil {
		return ""
	}
	return l.SplunkDomain
}

func (l *LogStreamSplunkSink) GetSplunkPort() string {
	if l == nil {
		return ""
	}
	return l.SplunkPort
}

func (l *LogStreamSplunkSink) GetSplunkToken() string {
	if l == nil {
		return ""
	}
	return l.SplunkToken
}

func (l *LogStreamSplunkSink) GetSplunkSecure() bool {
	if l == nil {
		return false
	}
	return l.SplunkSecure
}

func (l *LogStreamSplunkSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamSplunkSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetSplunkDomain sets the SplunkDomain field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkSink) SetSplunkDomain(splunkDomain string) {
	l.SplunkDomain = splunkDomain
	l.require(logStreamSplunkSinkFieldSplunkDomain)
}

// SetSplunkPort sets the SplunkPort field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkSink) SetSplunkPort(splunkPort string) {
	l.SplunkPort = splunkPort
	l.require(logStreamSplunkSinkFieldSplunkPort)
}

// SetSplunkToken sets the SplunkToken field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkSink) SetSplunkToken(splunkToken string) {
	l.SplunkToken = splunkToken
	l.require(logStreamSplunkSinkFieldSplunkToken)
}

// SetSplunkSecure sets the SplunkSecure field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSplunkSink) SetSplunkSecure(splunkSecure bool) {
	l.SplunkSecure = splunkSecure
	l.require(logStreamSplunkSinkFieldSplunkSecure)
}

func (l *LogStreamSplunkSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamSplunkSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamSplunkSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSplunkSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamSplunkSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamSplunkSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

// The status of the log stream. Possible values: `active`, `paused`, `suspended`
type LogStreamStatusEnum string

const (
	LogStreamStatusEnumActive    LogStreamStatusEnum = "active"
	LogStreamStatusEnumPaused    LogStreamStatusEnum = "paused"
	LogStreamStatusEnumSuspended LogStreamStatusEnum = "suspended"
)

func NewLogStreamStatusEnumFromString(s string) (LogStreamStatusEnum, error) {
	switch s {
	case "active":
		return LogStreamStatusEnumActive, nil
	case "paused":
		return LogStreamStatusEnumPaused, nil
	case "suspended":
		return LogStreamStatusEnumSuspended, nil
	}
	var t LogStreamStatusEnum
	return "", fmt.Errorf("%s is not a valid %T", s, t)
}

func (l LogStreamStatusEnum) Ptr() *LogStreamStatusEnum {
	return &l
}

type LogStreamSumoEnum = string

var (
	logStreamSumoResponseSchemaFieldID         = big.NewInt(1 << 0)
	logStreamSumoResponseSchemaFieldName       = big.NewInt(1 << 1)
	logStreamSumoResponseSchemaFieldStatus     = big.NewInt(1 << 2)
	logStreamSumoResponseSchemaFieldType       = big.NewInt(1 << 3)
	logStreamSumoResponseSchemaFieldIsPriority = big.NewInt(1 << 4)
	logStreamSumoResponseSchemaFieldFilters    = big.NewInt(1 << 5)
	logStreamSumoResponseSchemaFieldPiiConfig  = big.NewInt(1 << 6)
	logStreamSumoResponseSchemaFieldSink       = big.NewInt(1 << 7)
)

type LogStreamSumoResponseSchema struct {
	// The id of the log stream
	ID *string `json:"id,omitempty" url:"id,omitempty"`
	// log stream name
	Name   *string              `json:"name,omitempty" url:"name,omitempty"`
	Status *LogStreamStatusEnum `json:"status,omitempty" url:"status,omitempty"`
	Type   *LogStreamSumoEnum   `json:"type,omitempty" url:"type,omitempty"`
	// True for priority log streams, false for non-priority
	IsPriority *bool `json:"isPriority,omitempty" url:"isPriority,omitempty"`
	// Only logs events matching these filters will be delivered by the stream. If omitted or empty, all events will be delivered.
	Filters   []*LogStreamFilter  `json:"filters,omitempty" url:"filters,omitempty"`
	PiiConfig *LogStreamPiiConfig `json:"pii_config,omitempty" url:"pii_config,omitempty"`
	Sink      *LogStreamSumoSink  `json:"sink,omitempty" url:"sink,omitempty"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	ExtraProperties map[string]interface{} `json:"-" url:"-"`

	rawJSON json.RawMessage
}

func (l *LogStreamSumoResponseSchema) GetID() string {
	if l == nil || l.ID == nil {
		return ""
	}
	return *l.ID
}

func (l *LogStreamSumoResponseSchema) GetName() string {
	if l == nil || l.Name == nil {
		return ""
	}
	return *l.Name
}

func (l *LogStreamSumoResponseSchema) GetStatus() LogStreamStatusEnum {
	if l == nil || l.Status == nil {
		return ""
	}
	return *l.Status
}

func (l *LogStreamSumoResponseSchema) GetIsPriority() bool {
	if l == nil || l.IsPriority == nil {
		return false
	}
	return *l.IsPriority
}

func (l *LogStreamSumoResponseSchema) GetFilters() []*LogStreamFilter {
	if l == nil || l.Filters == nil {
		return nil
	}
	return l.Filters
}

func (l *LogStreamSumoResponseSchema) GetPiiConfig() LogStreamPiiConfig {
	if l == nil || l.PiiConfig == nil {
		return LogStreamPiiConfig{}
	}
	return *l.PiiConfig
}

func (l *LogStreamSumoResponseSchema) GetSink() LogStreamSumoSink {
	if l == nil || l.Sink == nil {
		return LogStreamSumoSink{}
	}
	return *l.Sink
}

func (l *LogStreamSumoResponseSchema) GetExtraProperties() map[string]interface{} {
	return l.ExtraProperties
}

func (l *LogStreamSumoResponseSchema) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetID sets the ID field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetID(id *string) {
	l.ID = id
	l.require(logStreamSumoResponseSchemaFieldID)
}

// SetName sets the Name field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetName(name *string) {
	l.Name = name
	l.require(logStreamSumoResponseSchemaFieldName)
}

// SetStatus sets the Status field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetStatus(status *LogStreamStatusEnum) {
	l.Status = status
	l.require(logStreamSumoResponseSchemaFieldStatus)
}

// SetType sets the Type field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetType(type_ *LogStreamSumoEnum) {
	l.Type = type_
	l.require(logStreamSumoResponseSchemaFieldType)
}

// SetIsPriority sets the IsPriority field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetIsPriority(isPriority *bool) {
	l.IsPriority = isPriority
	l.require(logStreamSumoResponseSchemaFieldIsPriority)
}

// SetFilters sets the Filters field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetFilters(filters []*LogStreamFilter) {
	l.Filters = filters
	l.require(logStreamSumoResponseSchemaFieldFilters)
}

// SetPiiConfig sets the PiiConfig field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetPiiConfig(piiConfig *LogStreamPiiConfig) {
	l.PiiConfig = piiConfig
	l.require(logStreamSumoResponseSchemaFieldPiiConfig)
}

// SetSink sets the Sink field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoResponseSchema) SetSink(sink *LogStreamSumoSink) {
	l.Sink = sink
	l.require(logStreamSumoResponseSchemaFieldSink)
}

func (l *LogStreamSumoResponseSchema) UnmarshalJSON(data []byte) error {
	type embed LogStreamSumoResponseSchema
	var unmarshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	if err := json.Unmarshal(data, &unmarshaler); err != nil {
		return err
	}
	*l = LogStreamSumoResponseSchema(unmarshaler.embed)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.ExtraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSumoResponseSchema) MarshalJSON() ([]byte, error) {
	type embed LogStreamSumoResponseSchema
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return internal.MarshalJSONWithExtraProperties(explicitMarshaler, l.ExtraProperties)
}

func (l *LogStreamSumoResponseSchema) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

var (
	logStreamSumoSinkFieldSumoSourceAddress = big.NewInt(1 << 0)
)

type LogStreamSumoSink struct {
	// HTTP Source Address
	SumoSourceAddress string `json:"sumoSourceAddress" url:"sumoSourceAddress"`

	// Private bitmask of fields set to an explicit value and therefore not to be omitted
	explicitFields *big.Int `json:"-" url:"-"`

	extraProperties map[string]interface{}
	rawJSON         json.RawMessage
}

func (l *LogStreamSumoSink) GetSumoSourceAddress() string {
	if l == nil {
		return ""
	}
	return l.SumoSourceAddress
}

func (l *LogStreamSumoSink) GetExtraProperties() map[string]interface{} {
	return l.extraProperties
}

func (l *LogStreamSumoSink) require(field *big.Int) {
	if l.explicitFields == nil {
		l.explicitFields = big.NewInt(0)
	}
	l.explicitFields.Or(l.explicitFields, field)
}

// SetSumoSourceAddress sets the SumoSourceAddress field and marks it as non-optional;
// this prevents an empty or null value for this field from being omitted during serialization.
func (l *LogStreamSumoSink) SetSumoSourceAddress(sumoSourceAddress string) {
	l.SumoSourceAddress = sumoSourceAddress
	l.require(logStreamSumoSinkFieldSumoSourceAddress)
}

func (l *LogStreamSumoSink) UnmarshalJSON(data []byte) error {
	type unmarshaler LogStreamSumoSink
	var value unmarshaler
	if err := json.Unmarshal(data, &value); err != nil {
		return err
	}
	*l = LogStreamSumoSink(value)
	extraProperties, err := internal.ExtractExtraProperties(data, *l)
	if err != nil {
		return err
	}
	l.extraProperties = extraProperties
	l.rawJSON = json.RawMessage(data)
	return nil
}

func (l *LogStreamSumoSink) MarshalJSON() ([]byte, error) {
	type embed LogStreamSumoSink
	var marshaler = struct {
		embed
	}{
		embed: embed(*l),
	}
	explicitMarshaler := internal.HandleExplicitFields(marshaler, l.explicitFields)
	return json.Marshal(explicitMarshaler)
}

func (l *LogStreamSumoSink) String() string {
	if len(l.rawJSON) > 0 {
		if value, err := internal.StringifyJSON(l.rawJSON); err == nil {
			return value
		}
	}
	if value, err := internal.StringifyJSON(l); err == nil {
		return value
	}
	return fmt.Sprintf("%#v", l)
}

type UpdateLogStreamResponseContent struct {
	LogStreamHTTPResponseSchema        *LogStreamHTTPResponseSchema
	LogStreamEventBridgeResponseSchema *LogStreamEventBridgeResponseSchema
	LogStreamEventGridResponseSchema   *LogStreamEventGridResponseSchema
	LogStreamDatadogResponseSchema     *LogStreamDatadogResponseSchema
	LogStreamSplunkResponseSchema      *LogStreamSplunkResponseSchema
	LogStreamSumoResponseSchema        *LogStreamSumoResponseSchema
	LogStreamSegmentResponseSchema     *LogStreamSegmentResponseSchema
	LogStreamMixpanelResponseSchema    *LogStreamMixpanelResponseSchema

	typ string
}

func (u *UpdateLogStreamResponseContent) GetLogStreamHTTPResponseSchema() *LogStreamHTTPResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamHTTPResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamEventBridgeResponseSchema() *LogStreamEventBridgeResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamEventBridgeResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamEventGridResponseSchema() *LogStreamEventGridResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamEventGridResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamDatadogResponseSchema() *LogStreamDatadogResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamDatadogResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamSplunkResponseSchema() *LogStreamSplunkResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamSplunkResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamSumoResponseSchema() *LogStreamSumoResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamSumoResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamSegmentResponseSchema() *LogStreamSegmentResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamSegmentResponseSchema
}

func (u *UpdateLogStreamResponseContent) GetLogStreamMixpanelResponseSchema() *LogStreamMixpanelResponseSchema {
	if u == nil {
		return nil
	}
	return u.LogStreamMixpanelResponseSchema
}

func (u *UpdateLogStreamResponseContent) UnmarshalJSON(data []byte) error {
	valueLogStreamHTTPResponseSchema := new(LogStreamHTTPResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamHTTPResponseSchema); err == nil {
		u.typ = "LogStreamHTTPResponseSchema"
		u.LogStreamHTTPResponseSchema = valueLogStreamHTTPResponseSchema
		return nil
	}
	valueLogStreamEventBridgeResponseSchema := new(LogStreamEventBridgeResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventBridgeResponseSchema); err == nil {
		u.typ = "LogStreamEventBridgeResponseSchema"
		u.LogStreamEventBridgeResponseSchema = valueLogStreamEventBridgeResponseSchema
		return nil
	}
	valueLogStreamEventGridResponseSchema := new(LogStreamEventGridResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamEventGridResponseSchema); err == nil {
		u.typ = "LogStreamEventGridResponseSchema"
		u.LogStreamEventGridResponseSchema = valueLogStreamEventGridResponseSchema
		return nil
	}
	valueLogStreamDatadogResponseSchema := new(LogStreamDatadogResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamDatadogResponseSchema); err == nil {
		u.typ = "LogStreamDatadogResponseSchema"
		u.LogStreamDatadogResponseSchema = valueLogStreamDatadogResponseSchema
		return nil
	}
	valueLogStreamSplunkResponseSchema := new(LogStreamSplunkResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSplunkResponseSchema); err == nil {
		u.typ = "LogStreamSplunkResponseSchema"
		u.LogStreamSplunkResponseSchema = valueLogStreamSplunkResponseSchema
		return nil
	}
	valueLogStreamSumoResponseSchema := new(LogStreamSumoResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSumoResponseSchema); err == nil {
		u.typ = "LogStreamSumoResponseSchema"
		u.LogStreamSumoResponseSchema = valueLogStreamSumoResponseSchema
		return nil
	}
	valueLogStreamSegmentResponseSchema := new(LogStreamSegmentResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamSegmentResponseSchema); err == nil {
		u.typ = "LogStreamSegmentResponseSchema"
		u.LogStreamSegmentResponseSchema = valueLogStreamSegmentResponseSchema
		return nil
	}
	valueLogStreamMixpanelResponseSchema := new(LogStreamMixpanelResponseSchema)
	if err := json.Unmarshal(data, &valueLogStreamMixpanelResponseSchema); err == nil {
		u.typ = "LogStreamMixpanelResponseSchema"
		u.LogStreamMixpanelResponseSchema = valueLogStreamMixpanelResponseSchema
		return nil
	}
	return fmt.Errorf("%s cannot be deserialized as a %T", data, u)
}

func (u UpdateLogStreamResponseContent) MarshalJSON() ([]byte, error) {
	if u.typ == "LogStreamHTTPResponseSchema" || u.LogStreamHTTPResponseSchema != nil {
		return json.Marshal(u.LogStreamHTTPResponseSchema)
	}
	if u.typ == "LogStreamEventBridgeResponseSchema" || u.LogStreamEventBridgeResponseSchema != nil {
		return json.Marshal(u.LogStreamEventBridgeResponseSchema)
	}
	if u.typ == "LogStreamEventGridResponseSchema" || u.LogStreamEventGridResponseSchema != nil {
		return json.Marshal(u.LogStreamEventGridResponseSchema)
	}
	if u.typ == "LogStreamDatadogResponseSchema" || u.LogStreamDatadogResponseSchema != nil {
		return json.Marshal(u.LogStreamDatadogResponseSchema)
	}
	if u.typ == "LogStreamSplunkResponseSchema" || u.LogStreamSplunkResponseSchema != nil {
		return json.Marshal(u.LogStreamSplunkResponseSchema)
	}
	if u.typ == "LogStreamSumoResponseSchema" || u.LogStreamSumoResponseSchema != nil {
		return json.Marshal(u.LogStreamSumoResponseSchema)
	}
	if u.typ == "LogStreamSegmentResponseSchema" || u.LogStreamSegmentResponseSchema != nil {
		return json.Marshal(u.LogStreamSegmentResponseSchema)
	}
	if u.typ == "LogStreamMixpanelResponseSchema" || u.LogStreamMixpanelResponseSchema != nil {
		return json.Marshal(u.LogStreamMixpanelResponseSchema)
	}
	return nil, fmt.Errorf("type %T does not include a non-empty union type", u)
}

type UpdateLogStreamResponseContentVisitor interface {
	VisitLogStreamHTTPResponseSchema(*LogStreamHTTPResponseSchema) error
	VisitLogStreamEventBridgeResponseSchema(*LogStreamEventBridgeResponseSchema) error
	VisitLogStreamEventGridResponseSchema(*LogStreamEventGridResponseSchema) error
	VisitLogStreamDatadogResponseSchema(*LogStreamDatadogResponseSchema) error
	VisitLogStreamSplunkResponseSchema(*LogStreamSplunkResponseSchema) error
	VisitLogStreamSumoResponseSchema(*LogStreamSumoResponseSchema) error
	VisitLogStreamSegmentResponseSchema(*LogStreamSegmentResponseSchema) error
	VisitLogStreamMixpanelResponseSchema(*LogStreamMixpanelResponseSchema) error
}

func (u *UpdateLogStreamResponseContent) Accept(visitor UpdateLogStreamResponseContentVisitor) error {
	if u.typ == "LogStreamHTTPResponseSchema" || u.LogStreamHTTPResponseSchema != nil {
		return visitor.VisitLogStreamHTTPResponseSchema(u.LogStreamHTTPResponseSchema)
	}
	if u.typ == "LogStreamEventBridgeResponseSchema" || u.LogStreamEventBridgeResponseSchema != nil {
		return visitor.VisitLogStreamEventBridgeResponseSchema(u.LogStreamEventBridgeResponseSchema)
	}
	if u.typ == "LogStreamEventGridResponseSchema" || u.LogStreamEventGridResponseSchema != nil {
		return visitor.VisitLogStreamEventGridResponseSchema(u.LogStreamEventGridResponseSchema)
	}
	if u.typ == "LogStreamDatadogResponseSchema" || u.LogStreamDatadogResponseSchema != nil {
		return visitor.VisitLogStreamDatadogResponseSchema(u.LogStreamDatadogResponseSchema)
	}
	if u.typ == "LogStreamSplunkResponseSchema" || u.LogStreamSplunkResponseSchema != nil {
		return visitor.VisitLogStreamSplunkResponseSchema(u.LogStreamSplunkResponseSchema)
	}
	if u.typ == "LogStreamSumoResponseSchema" || u.LogStreamSumoResponseSchema != nil {
		return visitor.VisitLogStreamSumoResponseSchema(u.LogStreamSumoResponseSchema)
	}
	if u.typ == "LogStreamSegmentResponseSchema" || u.LogStreamSegmentResponseSchema != nil {
		return visitor.VisitLogStreamSegmentResponseSchema(u.LogStreamSegmentResponseSchema)
	}
	if u.typ == "LogStreamMixpanelResponseSchema" || u.LogStreamMixpanelResponseSchema != nil {
		return visitor.VisitLogStreamMixpanelResponseSchema(u.LogStreamMixpanelResponseSchema)
	}
	return fmt.Errorf("type %T does not include a non-empty union type", u)
}
