diff --git a/go.mod b/go.mod index 795cf73..c1f8105 100644 --- a/go.mod +++ b/go.mod @@ -9,6 +9,7 @@ require ( github.com/stretchr/testify v1.11.1 golang.org/x/oauth2 v0.36.0 golang.org/x/tools v0.48.0 + gopkg.in/validator.v2 v2.0.1 ) require ( @@ -30,6 +31,5 @@ require ( golang.org/x/sys v0.47.0 // indirect golang.org/x/telemetry v0.0.0-20260708182218-49f421fb7959 // indirect google.golang.org/protobuf v1.36.10 // indirect - gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/go.sum b/go.sum index b9ed492..fc7067f 100644 --- a/go.sum +++ b/go.sum @@ -37,11 +37,8 @@ github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7 github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= @@ -126,6 +123,8 @@ google.golang.org/protobuf v1.36.10/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= +gopkg.in/validator.v2 v2.0.1 h1:xF0KWyGWXm/LM2G1TrEjqOu4pa6coO9AlWSf3msVfDY= +gopkg.in/validator.v2 v2.0.1/go.mod h1:lIUZBlB3Im4s/eYp39Ry/wkR02yOPhZ9IwIRBjuPuG8= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/navigator.go b/navigator.go new file mode 100644 index 0000000..b0f5956 --- /dev/null +++ b/navigator.go @@ -0,0 +1,104 @@ +package signalfx + +import ( + "bytes" + "context" + "encoding/json" + "io" + "net/http" + "net/url" + + "github.com/signalfx/signalfx-go/navigator" +) + +// NavigatorAPIURL is the base URL for interacting with navigator. +const NavigatorAPIURL = "/v2/navigator" + +// CreateNavigator creates a navigator. +func (c *Client) CreateNavigator(ctx context.Context, navigatorRequest *navigator.CreateNavigatorRequest) (*navigator.Navigator, error) { + return c.executeNavigatorRequest(ctx, NavigatorAPIURL, http.MethodPost, http.StatusOK, navigatorRequest, nil) +} + +// DeleteNavigator deletes a navigator. +func (c *Client) DeleteNavigator(ctx context.Context, id string) error { + _, err := c.executeNavigatorRequest(ctx, NavigatorAPIURL+"/"+id, http.MethodDelete, http.StatusOK, nil, nil) + if err == io.EOF { + // Expected error as delete request returns status 200 instead of 204 + return nil + } + return err +} + +// GetNavigator gets a navigator. +func (c *Client) GetNavigator(ctx context.Context, id string) (*navigator.Navigator, error) { + return c.executeNavigatorRequest(ctx, NavigatorAPIURL+"/"+id, http.MethodGet, http.StatusOK, nil, nil) +} + +// UpdateNavigator updates a navigator. +func (c *Client) UpdateNavigator(ctx context.Context, id string, navigatorRequest *navigator.UpdateNavigatorRequest) (*navigator.Navigator, error) { + return c.executeNavigatorUpdateRequest(ctx, NavigatorAPIURL+"/"+id, http.MethodPut, http.StatusOK, navigatorRequest, nil) +} + +func (c *Client) executeNavigatorRequest(ctx context.Context, url string, method string, expectedValidStatus int, navigatorRequest *navigator.CreateNavigatorRequest, params url.Values) (*navigator.Navigator, error) { + var body io.Reader + if navigatorRequest != nil { + payload, err := json.Marshal(navigatorRequest) + if err != nil { + return nil, err + } + + body = bytes.NewReader(payload) + } + + resp, err := c.doRequest(ctx, method, url, params, body) + if err != nil { + return nil, err + } + defer resp.Body.Close() + + if err := newResponseError(resp, expectedValidStatus); err != nil { + return nil, err + } + + if expectedValidStatus == http.StatusNoContent { + _, _ = io.Copy(io.Discard, resp.Body) + return nil, nil + } + + returnedNavigator := &navigator.Navigator{} + err = json.NewDecoder(resp.Body).Decode(returnedNavigator) + _, _ = io.Copy(io.Discard, resp.Body) + return returnedNavigator, err +} + +func (c *Client) executeNavigatorUpdateRequest(ctx context.Context, url string, method string, expectedValidStatus int, navigatorRequest *navigator.UpdateNavigatorRequest, params url.Values) (*navigator.Navigator, error) { + var body io.Reader + if navigatorRequest != nil { + payload, err := json.Marshal(navigatorRequest) + if err != nil { + return nil, err + } + + body = bytes.NewReader(payload) + } + + resp, err := c.doRequest(ctx, method, url, params, body) + if err != nil { + return nil, err + } + defer resp.Body.Close() + + if err := newResponseError(resp, expectedValidStatus); err != nil { + return nil, err + } + + if expectedValidStatus == http.StatusNoContent { + _, _ = io.Copy(io.Discard, resp.Body) + return nil, nil + } + + returnedNavigator := &navigator.Navigator{} + err = json.NewDecoder(resp.Body).Decode(returnedNavigator) + _, _ = io.Copy(io.Discard, resp.Body) + return returnedNavigator, err +} diff --git a/navigator/model_aggregate_dashboards_inner.go b/navigator/model_aggregate_dashboards_inner.go new file mode 100644 index 0000000..906f009 --- /dev/null +++ b/navigator/model_aggregate_dashboards_inner.go @@ -0,0 +1,793 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the AggregateDashboardsInner type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &AggregateDashboardsInner{} + +// AggregateDashboardsInner struct for AggregateDashboardsInner +type AggregateDashboardsInner struct { + AuthorizedWriters *DashboardAuthorizedWriters `json:"authorizedWriters,omitempty"` + ChartDensity *DashboardChartDensity `json:"chartDensity,omitempty"` + // List of chart IDs and settings for the charts associated with this dashboard + Charts []DashboardChartSettingsObject `json:"charts,omitempty"` + // Dashboard creation timestamp, in *nix time in milliseconds. Set by system. + Created *int64 `json:"created,omitempty"` + // User ID of dashboard creator. Set by system. + Creator *string `json:"creator,omitempty"` + // not used + CustomProperties *string `json:"customProperties,omitempty"` + // Dashboard description + Description *string `json:"description,omitempty"` + // Reserved for system use + DiscoveryOptions map[string]interface{} `json:"discoveryOptions,omitempty"` + // List of event overlays you can apply to charts in this dashboard + EventOverlays []DashboardEventOverlayFilter `json:"eventOverlays,omitempty"` + Filters *DashboardChartsFilters `json:"filters,omitempty"` + // ID of an existing dashboard group that you want to contain this dashboard + GroupId *string `json:"groupId,omitempty"` + // The ID of the dashboard. Set by system. + Id *string `json:"id,omitempty"` + // Dashboard last updated time, in *nix format in milliseconds. Set by system. + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of user who last updated the dashboard. Set by system. + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // In milliseconds, the time to wait for data points before ignoring them + MaxDelayOverride *int32 `json:"maxDelayOverride,omitempty"` + // Dashboard name in the user interface + Name *string `json:"name,omitempty"` + // List of active event overlays for charts in this dashboard + SelectedEventOverlays []DashboardChartEventOverlay `json:"selectedEventOverlays,omitempty"` + // not used + Tags []string `json:"tags,omitempty"` + Permissions *DashboardPermissions `json:"permissions,omitempty"` +} + +// NewAggregateDashboardsInner instantiates a new AggregateDashboardsInner object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAggregateDashboardsInner() *AggregateDashboardsInner { + this := AggregateDashboardsInner{} + var chartDensity DashboardChartDensity = DEFAULT + this.ChartDensity = &chartDensity + return &this +} + +// NewAggregateDashboardsInnerWithDefaults instantiates a new AggregateDashboardsInner object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAggregateDashboardsInnerWithDefaults() *AggregateDashboardsInner { + this := AggregateDashboardsInner{} + var chartDensity DashboardChartDensity = DEFAULT + this.ChartDensity = &chartDensity + return &this +} + +// GetAuthorizedWriters returns the AuthorizedWriters field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetAuthorizedWriters() DashboardAuthorizedWriters { + if o == nil || IsNil(o.AuthorizedWriters) { + var ret DashboardAuthorizedWriters + return ret + } + return *o.AuthorizedWriters +} + +// GetAuthorizedWritersOk returns a tuple with the AuthorizedWriters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetAuthorizedWritersOk() (*DashboardAuthorizedWriters, bool) { + if o == nil || IsNil(o.AuthorizedWriters) { + return nil, false + } + return o.AuthorizedWriters, true +} + +// HasAuthorizedWriters returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasAuthorizedWriters() bool { + if o != nil && !IsNil(o.AuthorizedWriters) { + return true + } + + return false +} + +// SetAuthorizedWriters gets a reference to the given DashboardAuthorizedWriters and assigns it to the AuthorizedWriters field. +func (o *AggregateDashboardsInner) SetAuthorizedWriters(v DashboardAuthorizedWriters) { + o.AuthorizedWriters = &v +} + +// GetChartDensity returns the ChartDensity field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetChartDensity() DashboardChartDensity { + if o == nil || IsNil(o.ChartDensity) { + var ret DashboardChartDensity + return ret + } + return *o.ChartDensity +} + +// GetChartDensityOk returns a tuple with the ChartDensity field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetChartDensityOk() (*DashboardChartDensity, bool) { + if o == nil || IsNil(o.ChartDensity) { + return nil, false + } + return o.ChartDensity, true +} + +// HasChartDensity returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasChartDensity() bool { + if o != nil && !IsNil(o.ChartDensity) { + return true + } + + return false +} + +// SetChartDensity gets a reference to the given DashboardChartDensity and assigns it to the ChartDensity field. +func (o *AggregateDashboardsInner) SetChartDensity(v DashboardChartDensity) { + o.ChartDensity = &v +} + +// GetCharts returns the Charts field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetCharts() []DashboardChartSettingsObject { + if o == nil || IsNil(o.Charts) { + var ret []DashboardChartSettingsObject + return ret + } + return o.Charts +} + +// GetChartsOk returns a tuple with the Charts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetChartsOk() ([]DashboardChartSettingsObject, bool) { + if o == nil || IsNil(o.Charts) { + return nil, false + } + return o.Charts, true +} + +// HasCharts returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasCharts() bool { + if o != nil && !IsNil(o.Charts) { + return true + } + + return false +} + +// SetCharts gets a reference to the given []DashboardChartSettingsObject and assigns it to the Charts field. +func (o *AggregateDashboardsInner) SetCharts(v []DashboardChartSettingsObject) { + o.Charts = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *AggregateDashboardsInner) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *AggregateDashboardsInner) SetCreator(v string) { + o.Creator = &v +} + +// GetCustomProperties returns the CustomProperties field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetCustomProperties() string { + if o == nil || IsNil(o.CustomProperties) { + var ret string + return ret + } + return *o.CustomProperties +} + +// GetCustomPropertiesOk returns a tuple with the CustomProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetCustomPropertiesOk() (*string, bool) { + if o == nil || IsNil(o.CustomProperties) { + return nil, false + } + return o.CustomProperties, true +} + +// HasCustomProperties returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasCustomProperties() bool { + if o != nil && !IsNil(o.CustomProperties) { + return true + } + + return false +} + +// SetCustomProperties gets a reference to the given string and assigns it to the CustomProperties field. +func (o *AggregateDashboardsInner) SetCustomProperties(v string) { + o.CustomProperties = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetDescription() string { + if o == nil || IsNil(o.Description) { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetDescriptionOk() (*string, bool) { + if o == nil || IsNil(o.Description) { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasDescription() bool { + if o != nil && !IsNil(o.Description) { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *AggregateDashboardsInner) SetDescription(v string) { + o.Description = &v +} + +// GetDiscoveryOptions returns the DiscoveryOptions field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetDiscoveryOptions() map[string]interface{} { + if o == nil || IsNil(o.DiscoveryOptions) { + var ret map[string]interface{} + return ret + } + return o.DiscoveryOptions +} + +// GetDiscoveryOptionsOk returns a tuple with the DiscoveryOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetDiscoveryOptionsOk() (map[string]interface{}, bool) { + if o == nil || IsNil(o.DiscoveryOptions) { + return map[string]interface{}{}, false + } + return o.DiscoveryOptions, true +} + +// HasDiscoveryOptions returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasDiscoveryOptions() bool { + if o != nil && !IsNil(o.DiscoveryOptions) { + return true + } + + return false +} + +// SetDiscoveryOptions gets a reference to the given map[string]interface{} and assigns it to the DiscoveryOptions field. +func (o *AggregateDashboardsInner) SetDiscoveryOptions(v map[string]interface{}) { + o.DiscoveryOptions = v +} + +// GetEventOverlays returns the EventOverlays field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetEventOverlays() []DashboardEventOverlayFilter { + if o == nil || IsNil(o.EventOverlays) { + var ret []DashboardEventOverlayFilter + return ret + } + return o.EventOverlays +} + +// GetEventOverlaysOk returns a tuple with the EventOverlays field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetEventOverlaysOk() ([]DashboardEventOverlayFilter, bool) { + if o == nil || IsNil(o.EventOverlays) { + return nil, false + } + return o.EventOverlays, true +} + +// HasEventOverlays returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasEventOverlays() bool { + if o != nil && !IsNil(o.EventOverlays) { + return true + } + + return false +} + +// SetEventOverlays gets a reference to the given []DashboardEventOverlayFilter and assigns it to the EventOverlays field. +func (o *AggregateDashboardsInner) SetEventOverlays(v []DashboardEventOverlayFilter) { + o.EventOverlays = v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetFilters() DashboardChartsFilters { + if o == nil || IsNil(o.Filters) { + var ret DashboardChartsFilters + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetFiltersOk() (*DashboardChartsFilters, bool) { + if o == nil || IsNil(o.Filters) { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasFilters() bool { + if o != nil && !IsNil(o.Filters) { + return true + } + + return false +} + +// SetFilters gets a reference to the given DashboardChartsFilters and assigns it to the Filters field. +func (o *AggregateDashboardsInner) SetFilters(v DashboardChartsFilters) { + o.Filters = &v +} + +// GetGroupId returns the GroupId field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetGroupId() string { + if o == nil || IsNil(o.GroupId) { + var ret string + return ret + } + return *o.GroupId +} + +// GetGroupIdOk returns a tuple with the GroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetGroupIdOk() (*string, bool) { + if o == nil || IsNil(o.GroupId) { + return nil, false + } + return o.GroupId, true +} + +// HasGroupId returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasGroupId() bool { + if o != nil && !IsNil(o.GroupId) { + return true + } + + return false +} + +// SetGroupId gets a reference to the given string and assigns it to the GroupId field. +func (o *AggregateDashboardsInner) SetGroupId(v string) { + o.GroupId = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *AggregateDashboardsInner) SetId(v string) { + o.Id = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *AggregateDashboardsInner) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *AggregateDashboardsInner) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetMaxDelayOverride returns the MaxDelayOverride field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetMaxDelayOverride() int32 { + if o == nil || IsNil(o.MaxDelayOverride) { + var ret int32 + return ret + } + return *o.MaxDelayOverride +} + +// GetMaxDelayOverrideOk returns a tuple with the MaxDelayOverride field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetMaxDelayOverrideOk() (*int32, bool) { + if o == nil || IsNil(o.MaxDelayOverride) { + return nil, false + } + return o.MaxDelayOverride, true +} + +// HasMaxDelayOverride returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasMaxDelayOverride() bool { + if o != nil && !IsNil(o.MaxDelayOverride) { + return true + } + + return false +} + +// SetMaxDelayOverride gets a reference to the given int32 and assigns it to the MaxDelayOverride field. +func (o *AggregateDashboardsInner) SetMaxDelayOverride(v int32) { + o.MaxDelayOverride = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *AggregateDashboardsInner) SetName(v string) { + o.Name = &v +} + +// GetSelectedEventOverlays returns the SelectedEventOverlays field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetSelectedEventOverlays() []DashboardChartEventOverlay { + if o == nil || IsNil(o.SelectedEventOverlays) { + var ret []DashboardChartEventOverlay + return ret + } + return o.SelectedEventOverlays +} + +// GetSelectedEventOverlaysOk returns a tuple with the SelectedEventOverlays field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetSelectedEventOverlaysOk() ([]DashboardChartEventOverlay, bool) { + if o == nil || IsNil(o.SelectedEventOverlays) { + return nil, false + } + return o.SelectedEventOverlays, true +} + +// HasSelectedEventOverlays returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasSelectedEventOverlays() bool { + if o != nil && !IsNil(o.SelectedEventOverlays) { + return true + } + + return false +} + +// SetSelectedEventOverlays gets a reference to the given []DashboardChartEventOverlay and assigns it to the SelectedEventOverlays field. +func (o *AggregateDashboardsInner) SetSelectedEventOverlays(v []DashboardChartEventOverlay) { + o.SelectedEventOverlays = v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetTags() []string { + if o == nil || IsNil(o.Tags) { + var ret []string + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetTagsOk() ([]string, bool) { + if o == nil || IsNil(o.Tags) { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *AggregateDashboardsInner) SetTags(v []string) { + o.Tags = v +} + +// GetPermissions returns the Permissions field value if set, zero value otherwise. +func (o *AggregateDashboardsInner) GetPermissions() DashboardPermissions { + if o == nil || IsNil(o.Permissions) { + var ret DashboardPermissions + return ret + } + return *o.Permissions +} + +// GetPermissionsOk returns a tuple with the Permissions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AggregateDashboardsInner) GetPermissionsOk() (*DashboardPermissions, bool) { + if o == nil || IsNil(o.Permissions) { + return nil, false + } + return o.Permissions, true +} + +// HasPermissions returns a boolean if a field has been set. +func (o *AggregateDashboardsInner) HasPermissions() bool { + if o != nil && !IsNil(o.Permissions) { + return true + } + + return false +} + +// SetPermissions gets a reference to the given DashboardPermissions and assigns it to the Permissions field. +func (o *AggregateDashboardsInner) SetPermissions(v DashboardPermissions) { + o.Permissions = &v +} + +func (o AggregateDashboardsInner) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o AggregateDashboardsInner) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AuthorizedWriters) { + toSerialize["authorizedWriters"] = o.AuthorizedWriters + } + if !IsNil(o.ChartDensity) { + toSerialize["chartDensity"] = o.ChartDensity + } + if !IsNil(o.Charts) { + toSerialize["charts"] = o.Charts + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.CustomProperties) { + toSerialize["customProperties"] = o.CustomProperties + } + if !IsNil(o.Description) { + toSerialize["description"] = o.Description + } + if !IsNil(o.DiscoveryOptions) { + toSerialize["discoveryOptions"] = o.DiscoveryOptions + } + if !IsNil(o.EventOverlays) { + toSerialize["eventOverlays"] = o.EventOverlays + } + if !IsNil(o.Filters) { + toSerialize["filters"] = o.Filters + } + if !IsNil(o.GroupId) { + toSerialize["groupId"] = o.GroupId + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.MaxDelayOverride) { + toSerialize["maxDelayOverride"] = o.MaxDelayOverride + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.SelectedEventOverlays) { + toSerialize["selectedEventOverlays"] = o.SelectedEventOverlays + } + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + if !IsNil(o.Permissions) { + toSerialize["permissions"] = o.Permissions + } + return toSerialize, nil +} + +type NullableAggregateDashboardsInner struct { + value *AggregateDashboardsInner + isSet bool +} + +func (v NullableAggregateDashboardsInner) Get() *AggregateDashboardsInner { + return v.value +} + +func (v *NullableAggregateDashboardsInner) Set(val *AggregateDashboardsInner) { + v.value = val + v.isSet = true +} + +func (v NullableAggregateDashboardsInner) IsSet() bool { + return v.isSet +} + +func (v *NullableAggregateDashboardsInner) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAggregateDashboardsInner(val *AggregateDashboardsInner) *NullableAggregateDashboardsInner { + return &NullableAggregateDashboardsInner{value: val, isSet: true} +} + +func (v NullableAggregateDashboardsInner) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAggregateDashboardsInner) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_category.go b/navigator/model_category.go new file mode 100644 index 0000000..a0688f5 --- /dev/null +++ b/navigator/model_category.go @@ -0,0 +1,233 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the Category type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Category{} + +// Category Navigator category +type Category struct { + // Category display name + CategoryName string `json:"categoryName"` + // Category group name + CategoryGroupName *string `json:"categoryGroupName,omitempty"` + // Category instance label + CategoryInstanceLabel *string `json:"categoryInstanceLabel,omitempty"` +} + +type _Category Category + +// NewCategory instantiates a new Category object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCategory(categoryName string) *Category { + this := Category{} + this.CategoryName = categoryName + return &this +} + +// NewCategoryWithDefaults instantiates a new Category object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCategoryWithDefaults() *Category { + this := Category{} + return &this +} + +// GetCategoryName returns the CategoryName field value +func (o *Category) GetCategoryName() string { + if o == nil { + var ret string + return ret + } + + return o.CategoryName +} + +// GetCategoryNameOk returns a tuple with the CategoryName field value +// and a boolean to check if the value has been set. +func (o *Category) GetCategoryNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.CategoryName, true +} + +// SetCategoryName sets field value +func (o *Category) SetCategoryName(v string) { + o.CategoryName = v +} + +// GetCategoryGroupName returns the CategoryGroupName field value if set, zero value otherwise. +func (o *Category) GetCategoryGroupName() string { + if o == nil || IsNil(o.CategoryGroupName) { + var ret string + return ret + } + return *o.CategoryGroupName +} + +// GetCategoryGroupNameOk returns a tuple with the CategoryGroupName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetCategoryGroupNameOk() (*string, bool) { + if o == nil || IsNil(o.CategoryGroupName) { + return nil, false + } + return o.CategoryGroupName, true +} + +// HasCategoryGroupName returns a boolean if a field has been set. +func (o *Category) HasCategoryGroupName() bool { + if o != nil && !IsNil(o.CategoryGroupName) { + return true + } + + return false +} + +// SetCategoryGroupName gets a reference to the given string and assigns it to the CategoryGroupName field. +func (o *Category) SetCategoryGroupName(v string) { + o.CategoryGroupName = &v +} + +// GetCategoryInstanceLabel returns the CategoryInstanceLabel field value if set, zero value otherwise. +func (o *Category) GetCategoryInstanceLabel() string { + if o == nil || IsNil(o.CategoryInstanceLabel) { + var ret string + return ret + } + return *o.CategoryInstanceLabel +} + +// GetCategoryInstanceLabelOk returns a tuple with the CategoryInstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Category) GetCategoryInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.CategoryInstanceLabel) { + return nil, false + } + return o.CategoryInstanceLabel, true +} + +// HasCategoryInstanceLabel returns a boolean if a field has been set. +func (o *Category) HasCategoryInstanceLabel() bool { + if o != nil && !IsNil(o.CategoryInstanceLabel) { + return true + } + + return false +} + +// SetCategoryInstanceLabel gets a reference to the given string and assigns it to the CategoryInstanceLabel field. +func (o *Category) SetCategoryInstanceLabel(v string) { + o.CategoryInstanceLabel = &v +} + +func (o Category) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Category) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["categoryName"] = o.CategoryName + if !IsNil(o.CategoryGroupName) { + toSerialize["categoryGroupName"] = o.CategoryGroupName + } + if !IsNil(o.CategoryInstanceLabel) { + toSerialize["categoryInstanceLabel"] = o.CategoryInstanceLabel + } + return toSerialize, nil +} + +func (o *Category) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "categoryName", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varCategory := _Category{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varCategory) + + if err != nil { + return err + } + + *o = Category(varCategory) + + return err +} + +type NullableCategory struct { + value *Category + isSet bool +} + +func (v NullableCategory) Get() *Category { + return v.value +} + +func (v *NullableCategory) Set(val *Category) { + v.value = val + v.isSet = true +} + +func (v NullableCategory) IsSet() bool { + return v.isSet +} + +func (v *NullableCategory) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCategory(val *Category) *NullableCategory { + return &NullableCategory{value: val, isSet: true} +} + +func (v NullableCategory) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCategory) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_chart_axes.go b/navigator/model_chart_axes.go new file mode 100644 index 0000000..02c612c --- /dev/null +++ b/navigator/model_chart_axes.go @@ -0,0 +1,349 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the ChartAxes type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ChartAxes{} + +// ChartAxes struct for ChartAxes +type ChartAxes struct { + // Max Y value of interest drawn as horizontal line + HighWatermark *float32 `json:"highWatermark,omitempty"` + // Label for line drawn for max Y value + HighWatermarkLabel *string `json:"highWatermarkLabel,omitempty"` + // Y axis label + Label *string `json:"label,omitempty"` + // Min Y value of interest drawn as horizontal line + LowWatermark *float32 `json:"lowWatermark,omitempty"` + // Label for line drawn for max Y value + LowWatermarkLabel *string `json:"lowWatermarkLabel,omitempty"` + // Largest value to display + Max *float32 `json:"max,omitempty"` + // Smallest value to display + Min *float32 `json:"min,omitempty"` +} + +// NewChartAxes instantiates a new ChartAxes object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChartAxes() *ChartAxes { + this := ChartAxes{} + return &this +} + +// NewChartAxesWithDefaults instantiates a new ChartAxes object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChartAxesWithDefaults() *ChartAxes { + this := ChartAxes{} + return &this +} + +// GetHighWatermark returns the HighWatermark field value if set, zero value otherwise. +func (o *ChartAxes) GetHighWatermark() float32 { + if o == nil || IsNil(o.HighWatermark) { + var ret float32 + return ret + } + return *o.HighWatermark +} + +// GetHighWatermarkOk returns a tuple with the HighWatermark field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetHighWatermarkOk() (*float32, bool) { + if o == nil || IsNil(o.HighWatermark) { + return nil, false + } + return o.HighWatermark, true +} + +// HasHighWatermark returns a boolean if a field has been set. +func (o *ChartAxes) HasHighWatermark() bool { + if o != nil && !IsNil(o.HighWatermark) { + return true + } + + return false +} + +// SetHighWatermark gets a reference to the given float32 and assigns it to the HighWatermark field. +func (o *ChartAxes) SetHighWatermark(v float32) { + o.HighWatermark = &v +} + +// GetHighWatermarkLabel returns the HighWatermarkLabel field value if set, zero value otherwise. +func (o *ChartAxes) GetHighWatermarkLabel() string { + if o == nil || IsNil(o.HighWatermarkLabel) { + var ret string + return ret + } + return *o.HighWatermarkLabel +} + +// GetHighWatermarkLabelOk returns a tuple with the HighWatermarkLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetHighWatermarkLabelOk() (*string, bool) { + if o == nil || IsNil(o.HighWatermarkLabel) { + return nil, false + } + return o.HighWatermarkLabel, true +} + +// HasHighWatermarkLabel returns a boolean if a field has been set. +func (o *ChartAxes) HasHighWatermarkLabel() bool { + if o != nil && !IsNil(o.HighWatermarkLabel) { + return true + } + + return false +} + +// SetHighWatermarkLabel gets a reference to the given string and assigns it to the HighWatermarkLabel field. +func (o *ChartAxes) SetHighWatermarkLabel(v string) { + o.HighWatermarkLabel = &v +} + +// GetLabel returns the Label field value if set, zero value otherwise. +func (o *ChartAxes) GetLabel() string { + if o == nil || IsNil(o.Label) { + var ret string + return ret + } + return *o.Label +} + +// GetLabelOk returns a tuple with the Label field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetLabelOk() (*string, bool) { + if o == nil || IsNil(o.Label) { + return nil, false + } + return o.Label, true +} + +// HasLabel returns a boolean if a field has been set. +func (o *ChartAxes) HasLabel() bool { + if o != nil && !IsNil(o.Label) { + return true + } + + return false +} + +// SetLabel gets a reference to the given string and assigns it to the Label field. +func (o *ChartAxes) SetLabel(v string) { + o.Label = &v +} + +// GetLowWatermark returns the LowWatermark field value if set, zero value otherwise. +func (o *ChartAxes) GetLowWatermark() float32 { + if o == nil || IsNil(o.LowWatermark) { + var ret float32 + return ret + } + return *o.LowWatermark +} + +// GetLowWatermarkOk returns a tuple with the LowWatermark field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetLowWatermarkOk() (*float32, bool) { + if o == nil || IsNil(o.LowWatermark) { + return nil, false + } + return o.LowWatermark, true +} + +// HasLowWatermark returns a boolean if a field has been set. +func (o *ChartAxes) HasLowWatermark() bool { + if o != nil && !IsNil(o.LowWatermark) { + return true + } + + return false +} + +// SetLowWatermark gets a reference to the given float32 and assigns it to the LowWatermark field. +func (o *ChartAxes) SetLowWatermark(v float32) { + o.LowWatermark = &v +} + +// GetLowWatermarkLabel returns the LowWatermarkLabel field value if set, zero value otherwise. +func (o *ChartAxes) GetLowWatermarkLabel() string { + if o == nil || IsNil(o.LowWatermarkLabel) { + var ret string + return ret + } + return *o.LowWatermarkLabel +} + +// GetLowWatermarkLabelOk returns a tuple with the LowWatermarkLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetLowWatermarkLabelOk() (*string, bool) { + if o == nil || IsNil(o.LowWatermarkLabel) { + return nil, false + } + return o.LowWatermarkLabel, true +} + +// HasLowWatermarkLabel returns a boolean if a field has been set. +func (o *ChartAxes) HasLowWatermarkLabel() bool { + if o != nil && !IsNil(o.LowWatermarkLabel) { + return true + } + + return false +} + +// SetLowWatermarkLabel gets a reference to the given string and assigns it to the LowWatermarkLabel field. +func (o *ChartAxes) SetLowWatermarkLabel(v string) { + o.LowWatermarkLabel = &v +} + +// GetMax returns the Max field value if set, zero value otherwise. +func (o *ChartAxes) GetMax() float32 { + if o == nil || IsNil(o.Max) { + var ret float32 + return ret + } + return *o.Max +} + +// GetMaxOk returns a tuple with the Max field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetMaxOk() (*float32, bool) { + if o == nil || IsNil(o.Max) { + return nil, false + } + return o.Max, true +} + +// HasMax returns a boolean if a field has been set. +func (o *ChartAxes) HasMax() bool { + if o != nil && !IsNil(o.Max) { + return true + } + + return false +} + +// SetMax gets a reference to the given float32 and assigns it to the Max field. +func (o *ChartAxes) SetMax(v float32) { + o.Max = &v +} + +// GetMin returns the Min field value if set, zero value otherwise. +func (o *ChartAxes) GetMin() float32 { + if o == nil || IsNil(o.Min) { + var ret float32 + return ret + } + return *o.Min +} + +// GetMinOk returns a tuple with the Min field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartAxes) GetMinOk() (*float32, bool) { + if o == nil || IsNil(o.Min) { + return nil, false + } + return o.Min, true +} + +// HasMin returns a boolean if a field has been set. +func (o *ChartAxes) HasMin() bool { + if o != nil && !IsNil(o.Min) { + return true + } + + return false +} + +// SetMin gets a reference to the given float32 and assigns it to the Min field. +func (o *ChartAxes) SetMin(v float32) { + o.Min = &v +} + +func (o ChartAxes) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ChartAxes) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.HighWatermark) { + toSerialize["highWatermark"] = o.HighWatermark + } + if !IsNil(o.HighWatermarkLabel) { + toSerialize["highWatermarkLabel"] = o.HighWatermarkLabel + } + if !IsNil(o.Label) { + toSerialize["label"] = o.Label + } + if !IsNil(o.LowWatermark) { + toSerialize["lowWatermark"] = o.LowWatermark + } + if !IsNil(o.LowWatermarkLabel) { + toSerialize["lowWatermarkLabel"] = o.LowWatermarkLabel + } + if !IsNil(o.Max) { + toSerialize["max"] = o.Max + } + if !IsNil(o.Min) { + toSerialize["min"] = o.Min + } + return toSerialize, nil +} + +type NullableChartAxes struct { + value *ChartAxes + isSet bool +} + +func (v NullableChartAxes) Get() *ChartAxes { + return v.value +} + +func (v *NullableChartAxes) Set(val *ChartAxes) { + v.value = val + v.isSet = true +} + +func (v NullableChartAxes) IsSet() bool { + return v.isSet +} + +func (v *NullableChartAxes) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChartAxes(val *ChartAxes) *NullableChartAxes { + return &NullableChartAxes{value: val, isSet: true} +} + +func (v NullableChartAxes) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChartAxes) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_chart_options.go b/navigator/model_chart_options.go new file mode 100644 index 0000000..32a73e8 --- /dev/null +++ b/navigator/model_chart_options.go @@ -0,0 +1,1336 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the ChartOptions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ChartOptions{} + +// ChartOptions struct for ChartOptions +type ChartOptions struct { + AreaChartOptions *PropertiesForAreaCharts `json:"areaChartOptions,omitempty"` + // Controls appearance of markers for data arrival times + Axes []ChartAxes `json:"axes,omitempty"` + // Precision of plot values + AxisPrecision *int32 `json:"axisPrecision,omitempty"` + // Sets mechanism for coloring values + ColorBy *string `json:"colorBy,omitempty"` + ColorRange *SpecifiesColorRangeOptionsForColoringAHeatmapChart `json:"colorRange,omitempty"` + ColorScale *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart `json:"colorScale,omitempty"` + // List of color range settings + ColorScale2 []ChartSecondaryVisualization `json:"colorScale2,omitempty"` + // Default type for plots in this chart + DefaultPlotType *string `json:"defaultPlotType,omitempty"` + // Chart properties + GroupBy []string `json:"groupBy,omitempty"` + // Sorts groups of values in table charts + GroupBySort *string `json:"groupBySort,omitempty"` + // Option to exclude missing metric values + HideMissingValues *bool `json:"hideMissingValues,omitempty"` + HistogramChartOptions *ChartOptionsHistogramChartOptions `json:"histogramChartOptions,omitempty"` + // Controls how 0 value affects Y-axis + IncludeZero *bool `json:"includeZero,omitempty"` + LegendOptions *SetsTableOptions `json:"legendOptions,omitempty"` + LineChartOptions *OptionsForALineChart `json:"lineChartOptions,omitempty"` + // Text to display in a text chart + Markdown *string `json:"markdown,omitempty"` + // Number of significant digits to use for data points in the chart + MaximumPrecision *int32 `json:"maximumPrecision,omitempty"` + OnChartLegendOptions *DisplayOptionsForTheChartLegend `json:"onChartLegendOptions,omitempty"` + ProgramOptions *GeneralOptionsForTheChart `json:"programOptions,omitempty"` + // List of options for each plot in the chart + PublishLabelOptions []ChartPublishLabelOptions `json:"publishLabelOptions,omitempty"` + // In milliseconds, refresh interval for chart + RefreshInterval *int32 `json:"refreshInterval,omitempty"` + SecondaryVisualization *string `json:"secondaryVisualization,omitempty"` + // Controls display of vertical line when an event occurs + ShowEventLines *bool `json:"showEventLines,omitempty"` + // Controls the display of a sparkline in a single value chart + ShowSparkLine *bool `json:"showSparkLine,omitempty"` + // Sort order of chart entries + SortBy *string `json:"sortBy,omitempty"` + // Sort direction of heatmap chart entries + SortDirection *string `json:"sortDirection,omitempty"` + // Custom property to sort on for a heatmap chart + SortProperty *string `json:"sortProperty,omitempty"` + // Controls display of stacked plots + Stacked *bool `json:"stacked,omitempty"` + Time *OptionsForTheTimeDisplayedInAChart `json:"time,omitempty"` + // Controls timestamp display with values + TimeStampHidden *bool `json:"timeStampHidden,omitempty"` + // Type of chart to display + Type string `json:"type"` + // Measure to use when displaying or labeling values + UnitPrefix *string `json:"unitPrefix,omitempty"` +} + +type _ChartOptions ChartOptions + +// NewChartOptions instantiates a new ChartOptions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChartOptions(type_ string) *ChartOptions { + this := ChartOptions{} + var axisPrecision int32 = 3 + this.AxisPrecision = &axisPrecision + var defaultPlotType string = "LineChart" + this.DefaultPlotType = &defaultPlotType + var hideMissingValues bool = false + this.HideMissingValues = &hideMissingValues + var includeZero bool = false + this.IncludeZero = &includeZero + var showEventLines bool = false + this.ShowEventLines = &showEventLines + var showSparkLine bool = false + this.ShowSparkLine = &showSparkLine + var sortDirection string = "Ascending" + this.SortDirection = &sortDirection + var stacked bool = false + this.Stacked = &stacked + var timeStampHidden bool = false + this.TimeStampHidden = &timeStampHidden + this.Type = type_ + var unitPrefix string = "Metric" + this.UnitPrefix = &unitPrefix + return &this +} + +// NewChartOptionsWithDefaults instantiates a new ChartOptions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChartOptionsWithDefaults() *ChartOptions { + this := ChartOptions{} + var axisPrecision int32 = 3 + this.AxisPrecision = &axisPrecision + var defaultPlotType string = "LineChart" + this.DefaultPlotType = &defaultPlotType + var hideMissingValues bool = false + this.HideMissingValues = &hideMissingValues + var includeZero bool = false + this.IncludeZero = &includeZero + var showEventLines bool = false + this.ShowEventLines = &showEventLines + var showSparkLine bool = false + this.ShowSparkLine = &showSparkLine + var sortDirection string = "Ascending" + this.SortDirection = &sortDirection + var stacked bool = false + this.Stacked = &stacked + var timeStampHidden bool = false + this.TimeStampHidden = &timeStampHidden + var unitPrefix string = "Metric" + this.UnitPrefix = &unitPrefix + return &this +} + +// GetAreaChartOptions returns the AreaChartOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetAreaChartOptions() PropertiesForAreaCharts { + if o == nil || IsNil(o.AreaChartOptions) { + var ret PropertiesForAreaCharts + return ret + } + return *o.AreaChartOptions +} + +// GetAreaChartOptionsOk returns a tuple with the AreaChartOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetAreaChartOptionsOk() (*PropertiesForAreaCharts, bool) { + if o == nil || IsNil(o.AreaChartOptions) { + return nil, false + } + return o.AreaChartOptions, true +} + +// HasAreaChartOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasAreaChartOptions() bool { + if o != nil && !IsNil(o.AreaChartOptions) { + return true + } + + return false +} + +// SetAreaChartOptions gets a reference to the given PropertiesForAreaCharts and assigns it to the AreaChartOptions field. +func (o *ChartOptions) SetAreaChartOptions(v PropertiesForAreaCharts) { + o.AreaChartOptions = &v +} + +// GetAxes returns the Axes field value if set, zero value otherwise. +func (o *ChartOptions) GetAxes() []ChartAxes { + if o == nil || IsNil(o.Axes) { + var ret []ChartAxes + return ret + } + return o.Axes +} + +// GetAxesOk returns a tuple with the Axes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetAxesOk() ([]ChartAxes, bool) { + if o == nil || IsNil(o.Axes) { + return nil, false + } + return o.Axes, true +} + +// HasAxes returns a boolean if a field has been set. +func (o *ChartOptions) HasAxes() bool { + if o != nil && !IsNil(o.Axes) { + return true + } + + return false +} + +// SetAxes gets a reference to the given []ChartAxes and assigns it to the Axes field. +func (o *ChartOptions) SetAxes(v []ChartAxes) { + o.Axes = v +} + +// GetAxisPrecision returns the AxisPrecision field value if set, zero value otherwise. +func (o *ChartOptions) GetAxisPrecision() int32 { + if o == nil || IsNil(o.AxisPrecision) { + var ret int32 + return ret + } + return *o.AxisPrecision +} + +// GetAxisPrecisionOk returns a tuple with the AxisPrecision field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetAxisPrecisionOk() (*int32, bool) { + if o == nil || IsNil(o.AxisPrecision) { + return nil, false + } + return o.AxisPrecision, true +} + +// HasAxisPrecision returns a boolean if a field has been set. +func (o *ChartOptions) HasAxisPrecision() bool { + if o != nil && !IsNil(o.AxisPrecision) { + return true + } + + return false +} + +// SetAxisPrecision gets a reference to the given int32 and assigns it to the AxisPrecision field. +func (o *ChartOptions) SetAxisPrecision(v int32) { + o.AxisPrecision = &v +} + +// GetColorBy returns the ColorBy field value if set, zero value otherwise. +func (o *ChartOptions) GetColorBy() string { + if o == nil || IsNil(o.ColorBy) { + var ret string + return ret + } + return *o.ColorBy +} + +// GetColorByOk returns a tuple with the ColorBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetColorByOk() (*string, bool) { + if o == nil || IsNil(o.ColorBy) { + return nil, false + } + return o.ColorBy, true +} + +// HasColorBy returns a boolean if a field has been set. +func (o *ChartOptions) HasColorBy() bool { + if o != nil && !IsNil(o.ColorBy) { + return true + } + + return false +} + +// SetColorBy gets a reference to the given string and assigns it to the ColorBy field. +func (o *ChartOptions) SetColorBy(v string) { + o.ColorBy = &v +} + +// GetColorRange returns the ColorRange field value if set, zero value otherwise. +func (o *ChartOptions) GetColorRange() SpecifiesColorRangeOptionsForColoringAHeatmapChart { + if o == nil || IsNil(o.ColorRange) { + var ret SpecifiesColorRangeOptionsForColoringAHeatmapChart + return ret + } + return *o.ColorRange +} + +// GetColorRangeOk returns a tuple with the ColorRange field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetColorRangeOk() (*SpecifiesColorRangeOptionsForColoringAHeatmapChart, bool) { + if o == nil || IsNil(o.ColorRange) { + return nil, false + } + return o.ColorRange, true +} + +// HasColorRange returns a boolean if a field has been set. +func (o *ChartOptions) HasColorRange() bool { + if o != nil && !IsNil(o.ColorRange) { + return true + } + + return false +} + +// SetColorRange gets a reference to the given SpecifiesColorRangeOptionsForColoringAHeatmapChart and assigns it to the ColorRange field. +func (o *ChartOptions) SetColorRange(v SpecifiesColorRangeOptionsForColoringAHeatmapChart) { + o.ColorRange = &v +} + +// GetColorScale returns the ColorScale field value if set, zero value otherwise. +func (o *ChartOptions) GetColorScale() SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart { + if o == nil || IsNil(o.ColorScale) { + var ret SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart + return ret + } + return *o.ColorScale +} + +// GetColorScaleOk returns a tuple with the ColorScale field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetColorScaleOk() (*SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart, bool) { + if o == nil || IsNil(o.ColorScale) { + return nil, false + } + return o.ColorScale, true +} + +// HasColorScale returns a boolean if a field has been set. +func (o *ChartOptions) HasColorScale() bool { + if o != nil && !IsNil(o.ColorScale) { + return true + } + + return false +} + +// SetColorScale gets a reference to the given SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart and assigns it to the ColorScale field. +func (o *ChartOptions) SetColorScale(v SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) { + o.ColorScale = &v +} + +// GetColorScale2 returns the ColorScale2 field value if set, zero value otherwise. +func (o *ChartOptions) GetColorScale2() []ChartSecondaryVisualization { + if o == nil || IsNil(o.ColorScale2) { + var ret []ChartSecondaryVisualization + return ret + } + return o.ColorScale2 +} + +// GetColorScale2Ok returns a tuple with the ColorScale2 field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetColorScale2Ok() ([]ChartSecondaryVisualization, bool) { + if o == nil || IsNil(o.ColorScale2) { + return nil, false + } + return o.ColorScale2, true +} + +// HasColorScale2 returns a boolean if a field has been set. +func (o *ChartOptions) HasColorScale2() bool { + if o != nil && !IsNil(o.ColorScale2) { + return true + } + + return false +} + +// SetColorScale2 gets a reference to the given []ChartSecondaryVisualization and assigns it to the ColorScale2 field. +func (o *ChartOptions) SetColorScale2(v []ChartSecondaryVisualization) { + o.ColorScale2 = v +} + +// GetDefaultPlotType returns the DefaultPlotType field value if set, zero value otherwise. +func (o *ChartOptions) GetDefaultPlotType() string { + if o == nil || IsNil(o.DefaultPlotType) { + var ret string + return ret + } + return *o.DefaultPlotType +} + +// GetDefaultPlotTypeOk returns a tuple with the DefaultPlotType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetDefaultPlotTypeOk() (*string, bool) { + if o == nil || IsNil(o.DefaultPlotType) { + return nil, false + } + return o.DefaultPlotType, true +} + +// HasDefaultPlotType returns a boolean if a field has been set. +func (o *ChartOptions) HasDefaultPlotType() bool { + if o != nil && !IsNil(o.DefaultPlotType) { + return true + } + + return false +} + +// SetDefaultPlotType gets a reference to the given string and assigns it to the DefaultPlotType field. +func (o *ChartOptions) SetDefaultPlotType(v string) { + o.DefaultPlotType = &v +} + +// GetGroupBy returns the GroupBy field value if set, zero value otherwise. +func (o *ChartOptions) GetGroupBy() []string { + if o == nil || IsNil(o.GroupBy) { + var ret []string + return ret + } + return o.GroupBy +} + +// GetGroupByOk returns a tuple with the GroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetGroupByOk() ([]string, bool) { + if o == nil || IsNil(o.GroupBy) { + return nil, false + } + return o.GroupBy, true +} + +// HasGroupBy returns a boolean if a field has been set. +func (o *ChartOptions) HasGroupBy() bool { + if o != nil && !IsNil(o.GroupBy) { + return true + } + + return false +} + +// SetGroupBy gets a reference to the given []string and assigns it to the GroupBy field. +func (o *ChartOptions) SetGroupBy(v []string) { + o.GroupBy = v +} + +// GetGroupBySort returns the GroupBySort field value if set, zero value otherwise. +func (o *ChartOptions) GetGroupBySort() string { + if o == nil || IsNil(o.GroupBySort) { + var ret string + return ret + } + return *o.GroupBySort +} + +// GetGroupBySortOk returns a tuple with the GroupBySort field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetGroupBySortOk() (*string, bool) { + if o == nil || IsNil(o.GroupBySort) { + return nil, false + } + return o.GroupBySort, true +} + +// HasGroupBySort returns a boolean if a field has been set. +func (o *ChartOptions) HasGroupBySort() bool { + if o != nil && !IsNil(o.GroupBySort) { + return true + } + + return false +} + +// SetGroupBySort gets a reference to the given string and assigns it to the GroupBySort field. +func (o *ChartOptions) SetGroupBySort(v string) { + o.GroupBySort = &v +} + +// GetHideMissingValues returns the HideMissingValues field value if set, zero value otherwise. +func (o *ChartOptions) GetHideMissingValues() bool { + if o == nil || IsNil(o.HideMissingValues) { + var ret bool + return ret + } + return *o.HideMissingValues +} + +// GetHideMissingValuesOk returns a tuple with the HideMissingValues field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetHideMissingValuesOk() (*bool, bool) { + if o == nil || IsNil(o.HideMissingValues) { + return nil, false + } + return o.HideMissingValues, true +} + +// HasHideMissingValues returns a boolean if a field has been set. +func (o *ChartOptions) HasHideMissingValues() bool { + if o != nil && !IsNil(o.HideMissingValues) { + return true + } + + return false +} + +// SetHideMissingValues gets a reference to the given bool and assigns it to the HideMissingValues field. +func (o *ChartOptions) SetHideMissingValues(v bool) { + o.HideMissingValues = &v +} + +// GetHistogramChartOptions returns the HistogramChartOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetHistogramChartOptions() ChartOptionsHistogramChartOptions { + if o == nil || IsNil(o.HistogramChartOptions) { + var ret ChartOptionsHistogramChartOptions + return ret + } + return *o.HistogramChartOptions +} + +// GetHistogramChartOptionsOk returns a tuple with the HistogramChartOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetHistogramChartOptionsOk() (*ChartOptionsHistogramChartOptions, bool) { + if o == nil || IsNil(o.HistogramChartOptions) { + return nil, false + } + return o.HistogramChartOptions, true +} + +// HasHistogramChartOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasHistogramChartOptions() bool { + if o != nil && !IsNil(o.HistogramChartOptions) { + return true + } + + return false +} + +// SetHistogramChartOptions gets a reference to the given ChartOptionsHistogramChartOptions and assigns it to the HistogramChartOptions field. +func (o *ChartOptions) SetHistogramChartOptions(v ChartOptionsHistogramChartOptions) { + o.HistogramChartOptions = &v +} + +// GetIncludeZero returns the IncludeZero field value if set, zero value otherwise. +func (o *ChartOptions) GetIncludeZero() bool { + if o == nil || IsNil(o.IncludeZero) { + var ret bool + return ret + } + return *o.IncludeZero +} + +// GetIncludeZeroOk returns a tuple with the IncludeZero field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetIncludeZeroOk() (*bool, bool) { + if o == nil || IsNil(o.IncludeZero) { + return nil, false + } + return o.IncludeZero, true +} + +// HasIncludeZero returns a boolean if a field has been set. +func (o *ChartOptions) HasIncludeZero() bool { + if o != nil && !IsNil(o.IncludeZero) { + return true + } + + return false +} + +// SetIncludeZero gets a reference to the given bool and assigns it to the IncludeZero field. +func (o *ChartOptions) SetIncludeZero(v bool) { + o.IncludeZero = &v +} + +// GetLegendOptions returns the LegendOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetLegendOptions() SetsTableOptions { + if o == nil || IsNil(o.LegendOptions) { + var ret SetsTableOptions + return ret + } + return *o.LegendOptions +} + +// GetLegendOptionsOk returns a tuple with the LegendOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetLegendOptionsOk() (*SetsTableOptions, bool) { + if o == nil || IsNil(o.LegendOptions) { + return nil, false + } + return o.LegendOptions, true +} + +// HasLegendOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasLegendOptions() bool { + if o != nil && !IsNil(o.LegendOptions) { + return true + } + + return false +} + +// SetLegendOptions gets a reference to the given SetsTableOptions and assigns it to the LegendOptions field. +func (o *ChartOptions) SetLegendOptions(v SetsTableOptions) { + o.LegendOptions = &v +} + +// GetLineChartOptions returns the LineChartOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetLineChartOptions() OptionsForALineChart { + if o == nil || IsNil(o.LineChartOptions) { + var ret OptionsForALineChart + return ret + } + return *o.LineChartOptions +} + +// GetLineChartOptionsOk returns a tuple with the LineChartOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetLineChartOptionsOk() (*OptionsForALineChart, bool) { + if o == nil || IsNil(o.LineChartOptions) { + return nil, false + } + return o.LineChartOptions, true +} + +// HasLineChartOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasLineChartOptions() bool { + if o != nil && !IsNil(o.LineChartOptions) { + return true + } + + return false +} + +// SetLineChartOptions gets a reference to the given OptionsForALineChart and assigns it to the LineChartOptions field. +func (o *ChartOptions) SetLineChartOptions(v OptionsForALineChart) { + o.LineChartOptions = &v +} + +// GetMarkdown returns the Markdown field value if set, zero value otherwise. +func (o *ChartOptions) GetMarkdown() string { + if o == nil || IsNil(o.Markdown) { + var ret string + return ret + } + return *o.Markdown +} + +// GetMarkdownOk returns a tuple with the Markdown field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetMarkdownOk() (*string, bool) { + if o == nil || IsNil(o.Markdown) { + return nil, false + } + return o.Markdown, true +} + +// HasMarkdown returns a boolean if a field has been set. +func (o *ChartOptions) HasMarkdown() bool { + if o != nil && !IsNil(o.Markdown) { + return true + } + + return false +} + +// SetMarkdown gets a reference to the given string and assigns it to the Markdown field. +func (o *ChartOptions) SetMarkdown(v string) { + o.Markdown = &v +} + +// GetMaximumPrecision returns the MaximumPrecision field value if set, zero value otherwise. +func (o *ChartOptions) GetMaximumPrecision() int32 { + if o == nil || IsNil(o.MaximumPrecision) { + var ret int32 + return ret + } + return *o.MaximumPrecision +} + +// GetMaximumPrecisionOk returns a tuple with the MaximumPrecision field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetMaximumPrecisionOk() (*int32, bool) { + if o == nil || IsNil(o.MaximumPrecision) { + return nil, false + } + return o.MaximumPrecision, true +} + +// HasMaximumPrecision returns a boolean if a field has been set. +func (o *ChartOptions) HasMaximumPrecision() bool { + if o != nil && !IsNil(o.MaximumPrecision) { + return true + } + + return false +} + +// SetMaximumPrecision gets a reference to the given int32 and assigns it to the MaximumPrecision field. +func (o *ChartOptions) SetMaximumPrecision(v int32) { + o.MaximumPrecision = &v +} + +// GetOnChartLegendOptions returns the OnChartLegendOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetOnChartLegendOptions() DisplayOptionsForTheChartLegend { + if o == nil || IsNil(o.OnChartLegendOptions) { + var ret DisplayOptionsForTheChartLegend + return ret + } + return *o.OnChartLegendOptions +} + +// GetOnChartLegendOptionsOk returns a tuple with the OnChartLegendOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetOnChartLegendOptionsOk() (*DisplayOptionsForTheChartLegend, bool) { + if o == nil || IsNil(o.OnChartLegendOptions) { + return nil, false + } + return o.OnChartLegendOptions, true +} + +// HasOnChartLegendOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasOnChartLegendOptions() bool { + if o != nil && !IsNil(o.OnChartLegendOptions) { + return true + } + + return false +} + +// SetOnChartLegendOptions gets a reference to the given DisplayOptionsForTheChartLegend and assigns it to the OnChartLegendOptions field. +func (o *ChartOptions) SetOnChartLegendOptions(v DisplayOptionsForTheChartLegend) { + o.OnChartLegendOptions = &v +} + +// GetProgramOptions returns the ProgramOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetProgramOptions() GeneralOptionsForTheChart { + if o == nil || IsNil(o.ProgramOptions) { + var ret GeneralOptionsForTheChart + return ret + } + return *o.ProgramOptions +} + +// GetProgramOptionsOk returns a tuple with the ProgramOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetProgramOptionsOk() (*GeneralOptionsForTheChart, bool) { + if o == nil || IsNil(o.ProgramOptions) { + return nil, false + } + return o.ProgramOptions, true +} + +// HasProgramOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasProgramOptions() bool { + if o != nil && !IsNil(o.ProgramOptions) { + return true + } + + return false +} + +// SetProgramOptions gets a reference to the given GeneralOptionsForTheChart and assigns it to the ProgramOptions field. +func (o *ChartOptions) SetProgramOptions(v GeneralOptionsForTheChart) { + o.ProgramOptions = &v +} + +// GetPublishLabelOptions returns the PublishLabelOptions field value if set, zero value otherwise. +func (o *ChartOptions) GetPublishLabelOptions() []ChartPublishLabelOptions { + if o == nil || IsNil(o.PublishLabelOptions) { + var ret []ChartPublishLabelOptions + return ret + } + return o.PublishLabelOptions +} + +// GetPublishLabelOptionsOk returns a tuple with the PublishLabelOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetPublishLabelOptionsOk() ([]ChartPublishLabelOptions, bool) { + if o == nil || IsNil(o.PublishLabelOptions) { + return nil, false + } + return o.PublishLabelOptions, true +} + +// HasPublishLabelOptions returns a boolean if a field has been set. +func (o *ChartOptions) HasPublishLabelOptions() bool { + if o != nil && !IsNil(o.PublishLabelOptions) { + return true + } + + return false +} + +// SetPublishLabelOptions gets a reference to the given []ChartPublishLabelOptions and assigns it to the PublishLabelOptions field. +func (o *ChartOptions) SetPublishLabelOptions(v []ChartPublishLabelOptions) { + o.PublishLabelOptions = v +} + +// GetRefreshInterval returns the RefreshInterval field value if set, zero value otherwise. +func (o *ChartOptions) GetRefreshInterval() int32 { + if o == nil || IsNil(o.RefreshInterval) { + var ret int32 + return ret + } + return *o.RefreshInterval +} + +// GetRefreshIntervalOk returns a tuple with the RefreshInterval field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetRefreshIntervalOk() (*int32, bool) { + if o == nil || IsNil(o.RefreshInterval) { + return nil, false + } + return o.RefreshInterval, true +} + +// HasRefreshInterval returns a boolean if a field has been set. +func (o *ChartOptions) HasRefreshInterval() bool { + if o != nil && !IsNil(o.RefreshInterval) { + return true + } + + return false +} + +// SetRefreshInterval gets a reference to the given int32 and assigns it to the RefreshInterval field. +func (o *ChartOptions) SetRefreshInterval(v int32) { + o.RefreshInterval = &v +} + +// GetSecondaryVisualization returns the SecondaryVisualization field value if set, zero value otherwise. +func (o *ChartOptions) GetSecondaryVisualization() string { + if o == nil || IsNil(o.SecondaryVisualization) { + var ret string + return ret + } + return *o.SecondaryVisualization +} + +// GetSecondaryVisualizationOk returns a tuple with the SecondaryVisualization field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetSecondaryVisualizationOk() (*string, bool) { + if o == nil || IsNil(o.SecondaryVisualization) { + return nil, false + } + return o.SecondaryVisualization, true +} + +// HasSecondaryVisualization returns a boolean if a field has been set. +func (o *ChartOptions) HasSecondaryVisualization() bool { + if o != nil && !IsNil(o.SecondaryVisualization) { + return true + } + + return false +} + +// SetSecondaryVisualization gets a reference to the given string and assigns it to the SecondaryVisualization field. +func (o *ChartOptions) SetSecondaryVisualization(v string) { + o.SecondaryVisualization = &v +} + +// GetShowEventLines returns the ShowEventLines field value if set, zero value otherwise. +func (o *ChartOptions) GetShowEventLines() bool { + if o == nil || IsNil(o.ShowEventLines) { + var ret bool + return ret + } + return *o.ShowEventLines +} + +// GetShowEventLinesOk returns a tuple with the ShowEventLines field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetShowEventLinesOk() (*bool, bool) { + if o == nil || IsNil(o.ShowEventLines) { + return nil, false + } + return o.ShowEventLines, true +} + +// HasShowEventLines returns a boolean if a field has been set. +func (o *ChartOptions) HasShowEventLines() bool { + if o != nil && !IsNil(o.ShowEventLines) { + return true + } + + return false +} + +// SetShowEventLines gets a reference to the given bool and assigns it to the ShowEventLines field. +func (o *ChartOptions) SetShowEventLines(v bool) { + o.ShowEventLines = &v +} + +// GetShowSparkLine returns the ShowSparkLine field value if set, zero value otherwise. +func (o *ChartOptions) GetShowSparkLine() bool { + if o == nil || IsNil(o.ShowSparkLine) { + var ret bool + return ret + } + return *o.ShowSparkLine +} + +// GetShowSparkLineOk returns a tuple with the ShowSparkLine field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetShowSparkLineOk() (*bool, bool) { + if o == nil || IsNil(o.ShowSparkLine) { + return nil, false + } + return o.ShowSparkLine, true +} + +// HasShowSparkLine returns a boolean if a field has been set. +func (o *ChartOptions) HasShowSparkLine() bool { + if o != nil && !IsNil(o.ShowSparkLine) { + return true + } + + return false +} + +// SetShowSparkLine gets a reference to the given bool and assigns it to the ShowSparkLine field. +func (o *ChartOptions) SetShowSparkLine(v bool) { + o.ShowSparkLine = &v +} + +// GetSortBy returns the SortBy field value if set, zero value otherwise. +func (o *ChartOptions) GetSortBy() string { + if o == nil || IsNil(o.SortBy) { + var ret string + return ret + } + return *o.SortBy +} + +// GetSortByOk returns a tuple with the SortBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetSortByOk() (*string, bool) { + if o == nil || IsNil(o.SortBy) { + return nil, false + } + return o.SortBy, true +} + +// HasSortBy returns a boolean if a field has been set. +func (o *ChartOptions) HasSortBy() bool { + if o != nil && !IsNil(o.SortBy) { + return true + } + + return false +} + +// SetSortBy gets a reference to the given string and assigns it to the SortBy field. +func (o *ChartOptions) SetSortBy(v string) { + o.SortBy = &v +} + +// GetSortDirection returns the SortDirection field value if set, zero value otherwise. +func (o *ChartOptions) GetSortDirection() string { + if o == nil || IsNil(o.SortDirection) { + var ret string + return ret + } + return *o.SortDirection +} + +// GetSortDirectionOk returns a tuple with the SortDirection field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetSortDirectionOk() (*string, bool) { + if o == nil || IsNil(o.SortDirection) { + return nil, false + } + return o.SortDirection, true +} + +// HasSortDirection returns a boolean if a field has been set. +func (o *ChartOptions) HasSortDirection() bool { + if o != nil && !IsNil(o.SortDirection) { + return true + } + + return false +} + +// SetSortDirection gets a reference to the given string and assigns it to the SortDirection field. +func (o *ChartOptions) SetSortDirection(v string) { + o.SortDirection = &v +} + +// GetSortProperty returns the SortProperty field value if set, zero value otherwise. +func (o *ChartOptions) GetSortProperty() string { + if o == nil || IsNil(o.SortProperty) { + var ret string + return ret + } + return *o.SortProperty +} + +// GetSortPropertyOk returns a tuple with the SortProperty field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetSortPropertyOk() (*string, bool) { + if o == nil || IsNil(o.SortProperty) { + return nil, false + } + return o.SortProperty, true +} + +// HasSortProperty returns a boolean if a field has been set. +func (o *ChartOptions) HasSortProperty() bool { + if o != nil && !IsNil(o.SortProperty) { + return true + } + + return false +} + +// SetSortProperty gets a reference to the given string and assigns it to the SortProperty field. +func (o *ChartOptions) SetSortProperty(v string) { + o.SortProperty = &v +} + +// GetStacked returns the Stacked field value if set, zero value otherwise. +func (o *ChartOptions) GetStacked() bool { + if o == nil || IsNil(o.Stacked) { + var ret bool + return ret + } + return *o.Stacked +} + +// GetStackedOk returns a tuple with the Stacked field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetStackedOk() (*bool, bool) { + if o == nil || IsNil(o.Stacked) { + return nil, false + } + return o.Stacked, true +} + +// HasStacked returns a boolean if a field has been set. +func (o *ChartOptions) HasStacked() bool { + if o != nil && !IsNil(o.Stacked) { + return true + } + + return false +} + +// SetStacked gets a reference to the given bool and assigns it to the Stacked field. +func (o *ChartOptions) SetStacked(v bool) { + o.Stacked = &v +} + +// GetTime returns the Time field value if set, zero value otherwise. +func (o *ChartOptions) GetTime() OptionsForTheTimeDisplayedInAChart { + if o == nil || IsNil(o.Time) { + var ret OptionsForTheTimeDisplayedInAChart + return ret + } + return *o.Time +} + +// GetTimeOk returns a tuple with the Time field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetTimeOk() (*OptionsForTheTimeDisplayedInAChart, bool) { + if o == nil || IsNil(o.Time) { + return nil, false + } + return o.Time, true +} + +// HasTime returns a boolean if a field has been set. +func (o *ChartOptions) HasTime() bool { + if o != nil && !IsNil(o.Time) { + return true + } + + return false +} + +// SetTime gets a reference to the given OptionsForTheTimeDisplayedInAChart and assigns it to the Time field. +func (o *ChartOptions) SetTime(v OptionsForTheTimeDisplayedInAChart) { + o.Time = &v +} + +// GetTimeStampHidden returns the TimeStampHidden field value if set, zero value otherwise. +func (o *ChartOptions) GetTimeStampHidden() bool { + if o == nil || IsNil(o.TimeStampHidden) { + var ret bool + return ret + } + return *o.TimeStampHidden +} + +// GetTimeStampHiddenOk returns a tuple with the TimeStampHidden field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetTimeStampHiddenOk() (*bool, bool) { + if o == nil || IsNil(o.TimeStampHidden) { + return nil, false + } + return o.TimeStampHidden, true +} + +// HasTimeStampHidden returns a boolean if a field has been set. +func (o *ChartOptions) HasTimeStampHidden() bool { + if o != nil && !IsNil(o.TimeStampHidden) { + return true + } + + return false +} + +// SetTimeStampHidden gets a reference to the given bool and assigns it to the TimeStampHidden field. +func (o *ChartOptions) SetTimeStampHidden(v bool) { + o.TimeStampHidden = &v +} + +// GetType returns the Type field value +func (o *ChartOptions) GetType() string { + if o == nil { + var ret string + return ret + } + + return o.Type +} + +// GetTypeOk returns a tuple with the Type field value +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Type, true +} + +// SetType sets field value +func (o *ChartOptions) SetType(v string) { + o.Type = v +} + +// GetUnitPrefix returns the UnitPrefix field value if set, zero value otherwise. +func (o *ChartOptions) GetUnitPrefix() string { + if o == nil || IsNil(o.UnitPrefix) { + var ret string + return ret + } + return *o.UnitPrefix +} + +// GetUnitPrefixOk returns a tuple with the UnitPrefix field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptions) GetUnitPrefixOk() (*string, bool) { + if o == nil || IsNil(o.UnitPrefix) { + return nil, false + } + return o.UnitPrefix, true +} + +// HasUnitPrefix returns a boolean if a field has been set. +func (o *ChartOptions) HasUnitPrefix() bool { + if o != nil && !IsNil(o.UnitPrefix) { + return true + } + + return false +} + +// SetUnitPrefix gets a reference to the given string and assigns it to the UnitPrefix field. +func (o *ChartOptions) SetUnitPrefix(v string) { + o.UnitPrefix = &v +} + +func (o ChartOptions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ChartOptions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AreaChartOptions) { + toSerialize["areaChartOptions"] = o.AreaChartOptions + } + if !IsNil(o.Axes) { + toSerialize["axes"] = o.Axes + } + if !IsNil(o.AxisPrecision) { + toSerialize["axisPrecision"] = o.AxisPrecision + } + if !IsNil(o.ColorBy) { + toSerialize["colorBy"] = o.ColorBy + } + if !IsNil(o.ColorRange) { + toSerialize["colorRange"] = o.ColorRange + } + if !IsNil(o.ColorScale) { + toSerialize["colorScale"] = o.ColorScale + } + if !IsNil(o.ColorScale2) { + toSerialize["colorScale2"] = o.ColorScale2 + } + if !IsNil(o.DefaultPlotType) { + toSerialize["defaultPlotType"] = o.DefaultPlotType + } + if !IsNil(o.GroupBy) { + toSerialize["groupBy"] = o.GroupBy + } + if !IsNil(o.GroupBySort) { + toSerialize["groupBySort"] = o.GroupBySort + } + if !IsNil(o.HideMissingValues) { + toSerialize["hideMissingValues"] = o.HideMissingValues + } + if !IsNil(o.HistogramChartOptions) { + toSerialize["histogramChartOptions"] = o.HistogramChartOptions + } + if !IsNil(o.IncludeZero) { + toSerialize["includeZero"] = o.IncludeZero + } + if !IsNil(o.LegendOptions) { + toSerialize["legendOptions"] = o.LegendOptions + } + if !IsNil(o.LineChartOptions) { + toSerialize["lineChartOptions"] = o.LineChartOptions + } + if !IsNil(o.Markdown) { + toSerialize["markdown"] = o.Markdown + } + if !IsNil(o.MaximumPrecision) { + toSerialize["maximumPrecision"] = o.MaximumPrecision + } + if !IsNil(o.OnChartLegendOptions) { + toSerialize["onChartLegendOptions"] = o.OnChartLegendOptions + } + if !IsNil(o.ProgramOptions) { + toSerialize["programOptions"] = o.ProgramOptions + } + if !IsNil(o.PublishLabelOptions) { + toSerialize["publishLabelOptions"] = o.PublishLabelOptions + } + if !IsNil(o.RefreshInterval) { + toSerialize["refreshInterval"] = o.RefreshInterval + } + if !IsNil(o.SecondaryVisualization) { + toSerialize["secondaryVisualization"] = o.SecondaryVisualization + } + if !IsNil(o.ShowEventLines) { + toSerialize["showEventLines"] = o.ShowEventLines + } + if !IsNil(o.ShowSparkLine) { + toSerialize["showSparkLine"] = o.ShowSparkLine + } + if !IsNil(o.SortBy) { + toSerialize["sortBy"] = o.SortBy + } + if !IsNil(o.SortDirection) { + toSerialize["sortDirection"] = o.SortDirection + } + if !IsNil(o.SortProperty) { + toSerialize["sortProperty"] = o.SortProperty + } + if !IsNil(o.Stacked) { + toSerialize["stacked"] = o.Stacked + } + if !IsNil(o.Time) { + toSerialize["time"] = o.Time + } + if !IsNil(o.TimeStampHidden) { + toSerialize["timeStampHidden"] = o.TimeStampHidden + } + toSerialize["type"] = o.Type + if !IsNil(o.UnitPrefix) { + toSerialize["unitPrefix"] = o.UnitPrefix + } + return toSerialize, nil +} + +func (o *ChartOptions) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "type", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varChartOptions := _ChartOptions{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varChartOptions) + + if err != nil { + return err + } + + *o = ChartOptions(varChartOptions) + + return err +} + +type NullableChartOptions struct { + value *ChartOptions + isSet bool +} + +func (v NullableChartOptions) Get() *ChartOptions { + return v.value +} + +func (v *NullableChartOptions) Set(val *ChartOptions) { + v.value = val + v.isSet = true +} + +func (v NullableChartOptions) IsSet() bool { + return v.isSet +} + +func (v *NullableChartOptions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChartOptions(val *ChartOptions) *NullableChartOptions { + return &NullableChartOptions{value: val, isSet: true} +} + +func (v NullableChartOptions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChartOptions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_chart_options_histogram_chart_options.go b/navigator/model_chart_options_histogram_chart_options.go new file mode 100644 index 0000000..f7cb91b --- /dev/null +++ b/navigator/model_chart_options_histogram_chart_options.go @@ -0,0 +1,131 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the ChartOptionsHistogramChartOptions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ChartOptionsHistogramChartOptions{} + +// ChartOptionsHistogramChartOptions struct for ChartOptionsHistogramChartOptions +type ChartOptionsHistogramChartOptions struct { + // Color palette index for histogram color theme + ColorThemeIndex *int32 `json:"colorThemeIndex,omitempty"` +} + +// NewChartOptionsHistogramChartOptions instantiates a new ChartOptionsHistogramChartOptions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChartOptionsHistogramChartOptions() *ChartOptionsHistogramChartOptions { + this := ChartOptionsHistogramChartOptions{} + var colorThemeIndex int32 = 15 + this.ColorThemeIndex = &colorThemeIndex + return &this +} + +// NewChartOptionsHistogramChartOptionsWithDefaults instantiates a new ChartOptionsHistogramChartOptions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChartOptionsHistogramChartOptionsWithDefaults() *ChartOptionsHistogramChartOptions { + this := ChartOptionsHistogramChartOptions{} + var colorThemeIndex int32 = 15 + this.ColorThemeIndex = &colorThemeIndex + return &this +} + +// GetColorThemeIndex returns the ColorThemeIndex field value if set, zero value otherwise. +func (o *ChartOptionsHistogramChartOptions) GetColorThemeIndex() int32 { + if o == nil || IsNil(o.ColorThemeIndex) { + var ret int32 + return ret + } + return *o.ColorThemeIndex +} + +// GetColorThemeIndexOk returns a tuple with the ColorThemeIndex field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartOptionsHistogramChartOptions) GetColorThemeIndexOk() (*int32, bool) { + if o == nil || IsNil(o.ColorThemeIndex) { + return nil, false + } + return o.ColorThemeIndex, true +} + +// HasColorThemeIndex returns a boolean if a field has been set. +func (o *ChartOptionsHistogramChartOptions) HasColorThemeIndex() bool { + if o != nil && !IsNil(o.ColorThemeIndex) { + return true + } + + return false +} + +// SetColorThemeIndex gets a reference to the given int32 and assigns it to the ColorThemeIndex field. +func (o *ChartOptionsHistogramChartOptions) SetColorThemeIndex(v int32) { + o.ColorThemeIndex = &v +} + +func (o ChartOptionsHistogramChartOptions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ChartOptionsHistogramChartOptions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ColorThemeIndex) { + toSerialize["colorThemeIndex"] = o.ColorThemeIndex + } + return toSerialize, nil +} + +type NullableChartOptionsHistogramChartOptions struct { + value *ChartOptionsHistogramChartOptions + isSet bool +} + +func (v NullableChartOptionsHistogramChartOptions) Get() *ChartOptionsHistogramChartOptions { + return v.value +} + +func (v *NullableChartOptionsHistogramChartOptions) Set(val *ChartOptionsHistogramChartOptions) { + v.value = val + v.isSet = true +} + +func (v NullableChartOptionsHistogramChartOptions) IsSet() bool { + return v.isSet +} + +func (v *NullableChartOptionsHistogramChartOptions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChartOptionsHistogramChartOptions(val *ChartOptionsHistogramChartOptions) *NullableChartOptionsHistogramChartOptions { + return &NullableChartOptionsHistogramChartOptions{value: val, isSet: true} +} + +func (v NullableChartOptionsHistogramChartOptions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChartOptionsHistogramChartOptions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_chart_publish_label_options.go b/navigator/model_chart_publish_label_options.go new file mode 100644 index 0000000..db5d479 --- /dev/null +++ b/navigator/model_chart_publish_label_options.go @@ -0,0 +1,422 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the ChartPublishLabelOptions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ChartPublishLabelOptions{} + +// ChartPublishLabelOptions Plot options +type ChartPublishLabelOptions struct { + // Alternate plot name, displayed in Data Table + DisplayName *string `json:"displayName,omitempty"` + // Label of `publish()` object for this plot + Label string `json:"label"` + // Plot color palette index + PaletteIndex *int32 `json:"paletteIndex,omitempty"` + // Visualization override for this plot + PlotType *string `json:"plotType,omitempty"` + // String prepended to values + ValuePrefix *string `json:"valuePrefix,omitempty"` + // String appended to values + ValueSuffix *string `json:"valueSuffix,omitempty"` + // Unit of measure for values + ValueUnit *string `json:"valueUnit,omitempty"` + // Y-axis position in plot + YAxis *int32 `json:"yAxis,omitempty"` +} + +type _ChartPublishLabelOptions ChartPublishLabelOptions + +// NewChartPublishLabelOptions instantiates a new ChartPublishLabelOptions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChartPublishLabelOptions(label string) *ChartPublishLabelOptions { + this := ChartPublishLabelOptions{} + this.Label = label + var yAxis int32 = 0 + this.YAxis = &yAxis + return &this +} + +// NewChartPublishLabelOptionsWithDefaults instantiates a new ChartPublishLabelOptions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChartPublishLabelOptionsWithDefaults() *ChartPublishLabelOptions { + this := ChartPublishLabelOptions{} + var yAxis int32 = 0 + this.YAxis = &yAxis + return &this +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *ChartPublishLabelOptions) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetLabel returns the Label field value +func (o *ChartPublishLabelOptions) GetLabel() string { + if o == nil { + var ret string + return ret + } + + return o.Label +} + +// GetLabelOk returns a tuple with the Label field value +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetLabelOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Label, true +} + +// SetLabel sets field value +func (o *ChartPublishLabelOptions) SetLabel(v string) { + o.Label = v +} + +// GetPaletteIndex returns the PaletteIndex field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetPaletteIndex() int32 { + if o == nil || IsNil(o.PaletteIndex) { + var ret int32 + return ret + } + return *o.PaletteIndex +} + +// GetPaletteIndexOk returns a tuple with the PaletteIndex field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetPaletteIndexOk() (*int32, bool) { + if o == nil || IsNil(o.PaletteIndex) { + return nil, false + } + return o.PaletteIndex, true +} + +// HasPaletteIndex returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasPaletteIndex() bool { + if o != nil && !IsNil(o.PaletteIndex) { + return true + } + + return false +} + +// SetPaletteIndex gets a reference to the given int32 and assigns it to the PaletteIndex field. +func (o *ChartPublishLabelOptions) SetPaletteIndex(v int32) { + o.PaletteIndex = &v +} + +// GetPlotType returns the PlotType field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetPlotType() string { + if o == nil || IsNil(o.PlotType) { + var ret string + return ret + } + return *o.PlotType +} + +// GetPlotTypeOk returns a tuple with the PlotType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetPlotTypeOk() (*string, bool) { + if o == nil || IsNil(o.PlotType) { + return nil, false + } + return o.PlotType, true +} + +// HasPlotType returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasPlotType() bool { + if o != nil && !IsNil(o.PlotType) { + return true + } + + return false +} + +// SetPlotType gets a reference to the given string and assigns it to the PlotType field. +func (o *ChartPublishLabelOptions) SetPlotType(v string) { + o.PlotType = &v +} + +// GetValuePrefix returns the ValuePrefix field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetValuePrefix() string { + if o == nil || IsNil(o.ValuePrefix) { + var ret string + return ret + } + return *o.ValuePrefix +} + +// GetValuePrefixOk returns a tuple with the ValuePrefix field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetValuePrefixOk() (*string, bool) { + if o == nil || IsNil(o.ValuePrefix) { + return nil, false + } + return o.ValuePrefix, true +} + +// HasValuePrefix returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasValuePrefix() bool { + if o != nil && !IsNil(o.ValuePrefix) { + return true + } + + return false +} + +// SetValuePrefix gets a reference to the given string and assigns it to the ValuePrefix field. +func (o *ChartPublishLabelOptions) SetValuePrefix(v string) { + o.ValuePrefix = &v +} + +// GetValueSuffix returns the ValueSuffix field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetValueSuffix() string { + if o == nil || IsNil(o.ValueSuffix) { + var ret string + return ret + } + return *o.ValueSuffix +} + +// GetValueSuffixOk returns a tuple with the ValueSuffix field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetValueSuffixOk() (*string, bool) { + if o == nil || IsNil(o.ValueSuffix) { + return nil, false + } + return o.ValueSuffix, true +} + +// HasValueSuffix returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasValueSuffix() bool { + if o != nil && !IsNil(o.ValueSuffix) { + return true + } + + return false +} + +// SetValueSuffix gets a reference to the given string and assigns it to the ValueSuffix field. +func (o *ChartPublishLabelOptions) SetValueSuffix(v string) { + o.ValueSuffix = &v +} + +// GetValueUnit returns the ValueUnit field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetValueUnit() string { + if o == nil || IsNil(o.ValueUnit) { + var ret string + return ret + } + return *o.ValueUnit +} + +// GetValueUnitOk returns a tuple with the ValueUnit field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetValueUnitOk() (*string, bool) { + if o == nil || IsNil(o.ValueUnit) { + return nil, false + } + return o.ValueUnit, true +} + +// HasValueUnit returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasValueUnit() bool { + if o != nil && !IsNil(o.ValueUnit) { + return true + } + + return false +} + +// SetValueUnit gets a reference to the given string and assigns it to the ValueUnit field. +func (o *ChartPublishLabelOptions) SetValueUnit(v string) { + o.ValueUnit = &v +} + +// GetYAxis returns the YAxis field value if set, zero value otherwise. +func (o *ChartPublishLabelOptions) GetYAxis() int32 { + if o == nil || IsNil(o.YAxis) { + var ret int32 + return ret + } + return *o.YAxis +} + +// GetYAxisOk returns a tuple with the YAxis field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartPublishLabelOptions) GetYAxisOk() (*int32, bool) { + if o == nil || IsNil(o.YAxis) { + return nil, false + } + return o.YAxis, true +} + +// HasYAxis returns a boolean if a field has been set. +func (o *ChartPublishLabelOptions) HasYAxis() bool { + if o != nil && !IsNil(o.YAxis) { + return true + } + + return false +} + +// SetYAxis gets a reference to the given int32 and assigns it to the YAxis field. +func (o *ChartPublishLabelOptions) SetYAxis(v int32) { + o.YAxis = &v +} + +func (o ChartPublishLabelOptions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ChartPublishLabelOptions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + toSerialize["label"] = o.Label + if !IsNil(o.PaletteIndex) { + toSerialize["paletteIndex"] = o.PaletteIndex + } + if !IsNil(o.PlotType) { + toSerialize["plotType"] = o.PlotType + } + if !IsNil(o.ValuePrefix) { + toSerialize["valuePrefix"] = o.ValuePrefix + } + if !IsNil(o.ValueSuffix) { + toSerialize["valueSuffix"] = o.ValueSuffix + } + if !IsNil(o.ValueUnit) { + toSerialize["valueUnit"] = o.ValueUnit + } + if !IsNil(o.YAxis) { + toSerialize["yAxis"] = o.YAxis + } + return toSerialize, nil +} + +func (o *ChartPublishLabelOptions) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "label", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varChartPublishLabelOptions := _ChartPublishLabelOptions{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varChartPublishLabelOptions) + + if err != nil { + return err + } + + *o = ChartPublishLabelOptions(varChartPublishLabelOptions) + + return err +} + +type NullableChartPublishLabelOptions struct { + value *ChartPublishLabelOptions + isSet bool +} + +func (v NullableChartPublishLabelOptions) Get() *ChartPublishLabelOptions { + return v.value +} + +func (v *NullableChartPublishLabelOptions) Set(val *ChartPublishLabelOptions) { + v.value = val + v.isSet = true +} + +func (v NullableChartPublishLabelOptions) IsSet() bool { + return v.isSet +} + +func (v *NullableChartPublishLabelOptions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChartPublishLabelOptions(val *ChartPublishLabelOptions) *NullableChartPublishLabelOptions { + return &NullableChartPublishLabelOptions{value: val, isSet: true} +} + +func (v NullableChartPublishLabelOptions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChartPublishLabelOptions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_chart_secondary_visualization.go b/navigator/model_chart_secondary_visualization.go new file mode 100644 index 0000000..f01ea20 --- /dev/null +++ b/navigator/model_chart_secondary_visualization.go @@ -0,0 +1,307 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the ChartSecondaryVisualization type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ChartSecondaryVisualization{} + +// ChartSecondaryVisualization struct for ChartSecondaryVisualization +type ChartSecondaryVisualization struct { + // Non-inclusive color range lower threshold + Gt *float32 `json:"gt,omitempty"` + // Color range lower threshold, inclusive + Gte *float32 `json:"gte,omitempty"` + // Color range upper threshold, non-inclusive + Lt *float32 `json:"lt,omitempty"` + // Color range upper threshold, inclusive + Lte *float32 `json:"lte,omitempty"` + // data point color palette index + PaletteIndex int32 `json:"paletteIndex"` +} + +type _ChartSecondaryVisualization ChartSecondaryVisualization + +// NewChartSecondaryVisualization instantiates a new ChartSecondaryVisualization object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewChartSecondaryVisualization(paletteIndex int32) *ChartSecondaryVisualization { + this := ChartSecondaryVisualization{} + this.PaletteIndex = paletteIndex + return &this +} + +// NewChartSecondaryVisualizationWithDefaults instantiates a new ChartSecondaryVisualization object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewChartSecondaryVisualizationWithDefaults() *ChartSecondaryVisualization { + this := ChartSecondaryVisualization{} + return &this +} + +// GetGt returns the Gt field value if set, zero value otherwise. +func (o *ChartSecondaryVisualization) GetGt() float32 { + if o == nil || IsNil(o.Gt) { + var ret float32 + return ret + } + return *o.Gt +} + +// GetGtOk returns a tuple with the Gt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartSecondaryVisualization) GetGtOk() (*float32, bool) { + if o == nil || IsNil(o.Gt) { + return nil, false + } + return o.Gt, true +} + +// HasGt returns a boolean if a field has been set. +func (o *ChartSecondaryVisualization) HasGt() bool { + if o != nil && !IsNil(o.Gt) { + return true + } + + return false +} + +// SetGt gets a reference to the given float32 and assigns it to the Gt field. +func (o *ChartSecondaryVisualization) SetGt(v float32) { + o.Gt = &v +} + +// GetGte returns the Gte field value if set, zero value otherwise. +func (o *ChartSecondaryVisualization) GetGte() float32 { + if o == nil || IsNil(o.Gte) { + var ret float32 + return ret + } + return *o.Gte +} + +// GetGteOk returns a tuple with the Gte field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartSecondaryVisualization) GetGteOk() (*float32, bool) { + if o == nil || IsNil(o.Gte) { + return nil, false + } + return o.Gte, true +} + +// HasGte returns a boolean if a field has been set. +func (o *ChartSecondaryVisualization) HasGte() bool { + if o != nil && !IsNil(o.Gte) { + return true + } + + return false +} + +// SetGte gets a reference to the given float32 and assigns it to the Gte field. +func (o *ChartSecondaryVisualization) SetGte(v float32) { + o.Gte = &v +} + +// GetLt returns the Lt field value if set, zero value otherwise. +func (o *ChartSecondaryVisualization) GetLt() float32 { + if o == nil || IsNil(o.Lt) { + var ret float32 + return ret + } + return *o.Lt +} + +// GetLtOk returns a tuple with the Lt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartSecondaryVisualization) GetLtOk() (*float32, bool) { + if o == nil || IsNil(o.Lt) { + return nil, false + } + return o.Lt, true +} + +// HasLt returns a boolean if a field has been set. +func (o *ChartSecondaryVisualization) HasLt() bool { + if o != nil && !IsNil(o.Lt) { + return true + } + + return false +} + +// SetLt gets a reference to the given float32 and assigns it to the Lt field. +func (o *ChartSecondaryVisualization) SetLt(v float32) { + o.Lt = &v +} + +// GetLte returns the Lte field value if set, zero value otherwise. +func (o *ChartSecondaryVisualization) GetLte() float32 { + if o == nil || IsNil(o.Lte) { + var ret float32 + return ret + } + return *o.Lte +} + +// GetLteOk returns a tuple with the Lte field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ChartSecondaryVisualization) GetLteOk() (*float32, bool) { + if o == nil || IsNil(o.Lte) { + return nil, false + } + return o.Lte, true +} + +// HasLte returns a boolean if a field has been set. +func (o *ChartSecondaryVisualization) HasLte() bool { + if o != nil && !IsNil(o.Lte) { + return true + } + + return false +} + +// SetLte gets a reference to the given float32 and assigns it to the Lte field. +func (o *ChartSecondaryVisualization) SetLte(v float32) { + o.Lte = &v +} + +// GetPaletteIndex returns the PaletteIndex field value +func (o *ChartSecondaryVisualization) GetPaletteIndex() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.PaletteIndex +} + +// GetPaletteIndexOk returns a tuple with the PaletteIndex field value +// and a boolean to check if the value has been set. +func (o *ChartSecondaryVisualization) GetPaletteIndexOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.PaletteIndex, true +} + +// SetPaletteIndex sets field value +func (o *ChartSecondaryVisualization) SetPaletteIndex(v int32) { + o.PaletteIndex = v +} + +func (o ChartSecondaryVisualization) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ChartSecondaryVisualization) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Gt) { + toSerialize["gt"] = o.Gt + } + if !IsNil(o.Gte) { + toSerialize["gte"] = o.Gte + } + if !IsNil(o.Lt) { + toSerialize["lt"] = o.Lt + } + if !IsNil(o.Lte) { + toSerialize["lte"] = o.Lte + } + toSerialize["paletteIndex"] = o.PaletteIndex + return toSerialize, nil +} + +func (o *ChartSecondaryVisualization) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "paletteIndex", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varChartSecondaryVisualization := _ChartSecondaryVisualization{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varChartSecondaryVisualization) + + if err != nil { + return err + } + + *o = ChartSecondaryVisualization(varChartSecondaryVisualization) + + return err +} + +type NullableChartSecondaryVisualization struct { + value *ChartSecondaryVisualization + isSet bool +} + +func (v NullableChartSecondaryVisualization) Get() *ChartSecondaryVisualization { + return v.value +} + +func (v *NullableChartSecondaryVisualization) Set(val *ChartSecondaryVisualization) { + v.value = val + v.isSet = true +} + +func (v NullableChartSecondaryVisualization) IsSet() bool { + return v.isSet +} + +func (v *NullableChartSecondaryVisualization) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableChartSecondaryVisualization(val *ChartSecondaryVisualization) *NullableChartSecondaryVisualization { + return &NullableChartSecondaryVisualization{value: val, isSet: true} +} + +func (v NullableChartSecondaryVisualization) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableChartSecondaryVisualization) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_coloring_scheme.go b/navigator/model_coloring_scheme.go new file mode 100644 index 0000000..98b304c --- /dev/null +++ b/navigator/model_coloring_scheme.go @@ -0,0 +1,238 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the ColoringScheme type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ColoringScheme{} + +// ColoringScheme Metric coloring scheme +type ColoringScheme struct { + // Optional lower bound used for default coloring + MinValue *int64 `json:"minValue,omitempty"` + // Optional upper bound used for default coloring + MaxValue *int64 `json:"maxValue,omitempty"` + // Color palette of the scheme + Palette *string `json:"palette,omitempty"` + // Optional list of thresholds to determine colors + Thresholds []ColoringThreshold `json:"thresholds,omitempty"` +} + +// NewColoringScheme instantiates a new ColoringScheme object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewColoringScheme() *ColoringScheme { + this := ColoringScheme{} + return &this +} + +// NewColoringSchemeWithDefaults instantiates a new ColoringScheme object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewColoringSchemeWithDefaults() *ColoringScheme { + this := ColoringScheme{} + return &this +} + +// GetMinValue returns the MinValue field value if set, zero value otherwise. +func (o *ColoringScheme) GetMinValue() int64 { + if o == nil || IsNil(o.MinValue) { + var ret int64 + return ret + } + return *o.MinValue +} + +// GetMinValueOk returns a tuple with the MinValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringScheme) GetMinValueOk() (*int64, bool) { + if o == nil || IsNil(o.MinValue) { + return nil, false + } + return o.MinValue, true +} + +// HasMinValue returns a boolean if a field has been set. +func (o *ColoringScheme) HasMinValue() bool { + if o != nil && !IsNil(o.MinValue) { + return true + } + + return false +} + +// SetMinValue gets a reference to the given int64 and assigns it to the MinValue field. +func (o *ColoringScheme) SetMinValue(v int64) { + o.MinValue = &v +} + +// GetMaxValue returns the MaxValue field value if set, zero value otherwise. +func (o *ColoringScheme) GetMaxValue() int64 { + if o == nil || IsNil(o.MaxValue) { + var ret int64 + return ret + } + return *o.MaxValue +} + +// GetMaxValueOk returns a tuple with the MaxValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringScheme) GetMaxValueOk() (*int64, bool) { + if o == nil || IsNil(o.MaxValue) { + return nil, false + } + return o.MaxValue, true +} + +// HasMaxValue returns a boolean if a field has been set. +func (o *ColoringScheme) HasMaxValue() bool { + if o != nil && !IsNil(o.MaxValue) { + return true + } + + return false +} + +// SetMaxValue gets a reference to the given int64 and assigns it to the MaxValue field. +func (o *ColoringScheme) SetMaxValue(v int64) { + o.MaxValue = &v +} + +// GetPalette returns the Palette field value if set, zero value otherwise. +func (o *ColoringScheme) GetPalette() string { + if o == nil || IsNil(o.Palette) { + var ret string + return ret + } + return *o.Palette +} + +// GetPaletteOk returns a tuple with the Palette field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringScheme) GetPaletteOk() (*string, bool) { + if o == nil || IsNil(o.Palette) { + return nil, false + } + return o.Palette, true +} + +// HasPalette returns a boolean if a field has been set. +func (o *ColoringScheme) HasPalette() bool { + if o != nil && !IsNil(o.Palette) { + return true + } + + return false +} + +// SetPalette gets a reference to the given string and assigns it to the Palette field. +func (o *ColoringScheme) SetPalette(v string) { + o.Palette = &v +} + +// GetThresholds returns the Thresholds field value if set, zero value otherwise. +func (o *ColoringScheme) GetThresholds() []ColoringThreshold { + if o == nil || IsNil(o.Thresholds) { + var ret []ColoringThreshold + return ret + } + return o.Thresholds +} + +// GetThresholdsOk returns a tuple with the Thresholds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringScheme) GetThresholdsOk() ([]ColoringThreshold, bool) { + if o == nil || IsNil(o.Thresholds) { + return nil, false + } + return o.Thresholds, true +} + +// HasThresholds returns a boolean if a field has been set. +func (o *ColoringScheme) HasThresholds() bool { + if o != nil && !IsNil(o.Thresholds) { + return true + } + + return false +} + +// SetThresholds gets a reference to the given []ColoringThreshold and assigns it to the Thresholds field. +func (o *ColoringScheme) SetThresholds(v []ColoringThreshold) { + o.Thresholds = v +} + +func (o ColoringScheme) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ColoringScheme) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.MinValue) { + toSerialize["minValue"] = o.MinValue + } + if !IsNil(o.MaxValue) { + toSerialize["maxValue"] = o.MaxValue + } + if !IsNil(o.Palette) { + toSerialize["palette"] = o.Palette + } + if !IsNil(o.Thresholds) { + toSerialize["thresholds"] = o.Thresholds + } + return toSerialize, nil +} + +type NullableColoringScheme struct { + value *ColoringScheme + isSet bool +} + +func (v NullableColoringScheme) Get() *ColoringScheme { + return v.value +} + +func (v *NullableColoringScheme) Set(val *ColoringScheme) { + v.value = val + v.isSet = true +} + +func (v NullableColoringScheme) IsSet() bool { + return v.isSet +} + +func (v *NullableColoringScheme) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableColoringScheme(val *ColoringScheme) *NullableColoringScheme { + return &NullableColoringScheme{value: val, isSet: true} +} + +func (v NullableColoringScheme) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableColoringScheme) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_coloring_threshold.go b/navigator/model_coloring_threshold.go new file mode 100644 index 0000000..2edf0eb --- /dev/null +++ b/navigator/model_coloring_threshold.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the ColoringThreshold type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ColoringThreshold{} + +// ColoringThreshold Single coloring threshold +type ColoringThreshold struct { + // Lower limit of the threshold + LowerLimit *int32 `json:"lowerLimit,omitempty"` + // 0-based index that specifies which color in the gradient is assigned to the range bounded at the lower limit by this threshold + PaletteIndex *int64 `json:"paletteIndex,omitempty"` +} + +// NewColoringThreshold instantiates a new ColoringThreshold object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewColoringThreshold() *ColoringThreshold { + this := ColoringThreshold{} + return &this +} + +// NewColoringThresholdWithDefaults instantiates a new ColoringThreshold object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewColoringThresholdWithDefaults() *ColoringThreshold { + this := ColoringThreshold{} + return &this +} + +// GetLowerLimit returns the LowerLimit field value if set, zero value otherwise. +func (o *ColoringThreshold) GetLowerLimit() int32 { + if o == nil || IsNil(o.LowerLimit) { + var ret int32 + return ret + } + return *o.LowerLimit +} + +// GetLowerLimitOk returns a tuple with the LowerLimit field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringThreshold) GetLowerLimitOk() (*int32, bool) { + if o == nil || IsNil(o.LowerLimit) { + return nil, false + } + return o.LowerLimit, true +} + +// HasLowerLimit returns a boolean if a field has been set. +func (o *ColoringThreshold) HasLowerLimit() bool { + if o != nil && !IsNil(o.LowerLimit) { + return true + } + + return false +} + +// SetLowerLimit gets a reference to the given int32 and assigns it to the LowerLimit field. +func (o *ColoringThreshold) SetLowerLimit(v int32) { + o.LowerLimit = &v +} + +// GetPaletteIndex returns the PaletteIndex field value if set, zero value otherwise. +func (o *ColoringThreshold) GetPaletteIndex() int64 { + if o == nil || IsNil(o.PaletteIndex) { + var ret int64 + return ret + } + return *o.PaletteIndex +} + +// GetPaletteIndexOk returns a tuple with the PaletteIndex field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ColoringThreshold) GetPaletteIndexOk() (*int64, bool) { + if o == nil || IsNil(o.PaletteIndex) { + return nil, false + } + return o.PaletteIndex, true +} + +// HasPaletteIndex returns a boolean if a field has been set. +func (o *ColoringThreshold) HasPaletteIndex() bool { + if o != nil && !IsNil(o.PaletteIndex) { + return true + } + + return false +} + +// SetPaletteIndex gets a reference to the given int64 and assigns it to the PaletteIndex field. +func (o *ColoringThreshold) SetPaletteIndex(v int64) { + o.PaletteIndex = &v +} + +func (o ColoringThreshold) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ColoringThreshold) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.LowerLimit) { + toSerialize["lowerLimit"] = o.LowerLimit + } + if !IsNil(o.PaletteIndex) { + toSerialize["paletteIndex"] = o.PaletteIndex + } + return toSerialize, nil +} + +type NullableColoringThreshold struct { + value *ColoringThreshold + isSet bool +} + +func (v NullableColoringThreshold) Get() *ColoringThreshold { + return v.value +} + +func (v *NullableColoringThreshold) Set(val *ColoringThreshold) { + v.value = val + v.isSet = true +} + +func (v NullableColoringThreshold) IsSet() bool { + return v.isSet +} + +func (v *NullableColoringThreshold) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableColoringThreshold(val *ColoringThreshold) *NullableColoringThreshold { + return &NullableColoringThreshold{value: val, isSet: true} +} + +func (v NullableColoringThreshold) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableColoringThreshold) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_create_navigator_customization_request.go b/navigator/model_create_navigator_customization_request.go new file mode 100644 index 0000000..1306210 --- /dev/null +++ b/navigator/model_create_navigator_customization_request.go @@ -0,0 +1,423 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the CreateNavigatorCustomizationRequest type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateNavigatorCustomizationRequest{} + +// CreateNavigatorCustomizationRequest struct for CreateNavigatorCustomizationRequest +type CreateNavigatorCustomizationRequest struct { + // Navigator customization system ID + Id *string `json:"id,omitempty"` + // Navigator customization display name + Name *string `json:"name,omitempty"` + // Navigator system ID + NavigatorId *string `json:"navigatorId,omitempty"` + // Array of dashboard IDs to use for aggregate display. Specific to GET /navigator/{id}/navigatorcustomization. + AggregateDashboards []string `json:"aggregateDashboards,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator/{id}/navigatorcustomization. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Navigator customization creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator customization + Creator *string `json:"creator,omitempty"` + // Time at which the navigator customization was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator customization + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` +} + +// NewCreateNavigatorCustomizationRequest instantiates a new CreateNavigatorCustomizationRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNavigatorCustomizationRequest() *CreateNavigatorCustomizationRequest { + this := CreateNavigatorCustomizationRequest{} + return &this +} + +// NewCreateNavigatorCustomizationRequestWithDefaults instantiates a new CreateNavigatorCustomizationRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNavigatorCustomizationRequestWithDefaults() *CreateNavigatorCustomizationRequest { + this := CreateNavigatorCustomizationRequest{} + return &this +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *CreateNavigatorCustomizationRequest) SetId(v string) { + o.Id = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *CreateNavigatorCustomizationRequest) SetName(v string) { + o.Name = &v +} + +// GetNavigatorId returns the NavigatorId field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetNavigatorId() string { + if o == nil || IsNil(o.NavigatorId) { + var ret string + return ret + } + return *o.NavigatorId +} + +// GetNavigatorIdOk returns a tuple with the NavigatorId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetNavigatorIdOk() (*string, bool) { + if o == nil || IsNil(o.NavigatorId) { + return nil, false + } + return o.NavigatorId, true +} + +// HasNavigatorId returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasNavigatorId() bool { + if o != nil && !IsNil(o.NavigatorId) { + return true + } + + return false +} + +// SetNavigatorId gets a reference to the given string and assigns it to the NavigatorId field. +func (o *CreateNavigatorCustomizationRequest) SetNavigatorId(v string) { + o.NavigatorId = &v +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetAggregateDashboards() []string { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []string + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetAggregateDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []string and assigns it to the AggregateDashboards field. +func (o *CreateNavigatorCustomizationRequest) SetAggregateDashboards(v []string) { + o.AggregateDashboards = v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *CreateNavigatorCustomizationRequest) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *CreateNavigatorCustomizationRequest) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *CreateNavigatorCustomizationRequest) SetCreator(v string) { + o.Creator = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *CreateNavigatorCustomizationRequest) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *CreateNavigatorCustomizationRequest) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorCustomizationRequest) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *CreateNavigatorCustomizationRequest) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *CreateNavigatorCustomizationRequest) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +func (o CreateNavigatorCustomizationRequest) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CreateNavigatorCustomizationRequest) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.NavigatorId) { + toSerialize["navigatorId"] = o.NavigatorId + } + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + return toSerialize, nil +} + +type NullableCreateNavigatorCustomizationRequest struct { + value *CreateNavigatorCustomizationRequest + isSet bool +} + +func (v NullableCreateNavigatorCustomizationRequest) Get() *CreateNavigatorCustomizationRequest { + return v.value +} + +func (v *NullableCreateNavigatorCustomizationRequest) Set(val *CreateNavigatorCustomizationRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNavigatorCustomizationRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNavigatorCustomizationRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNavigatorCustomizationRequest(val *CreateNavigatorCustomizationRequest) *NullableCreateNavigatorCustomizationRequest { + return &NullableCreateNavigatorCustomizationRequest{value: val, isSet: true} +} + +func (v NullableCreateNavigatorCustomizationRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNavigatorCustomizationRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_create_navigator_request.go b/navigator/model_create_navigator_request.go new file mode 100644 index 0000000..3045f2a --- /dev/null +++ b/navigator/model_create_navigator_request.go @@ -0,0 +1,719 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the CreateNavigatorRequest type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateNavigatorRequest{} + +// CreateNavigatorRequest Create navigator request body +type CreateNavigatorRequest struct { + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName string `json:"displayName"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate string `json:"propertyIdentifierTemplate"` + // Properties shared by all instances + RequiredProperties []string `json:"requiredProperties"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +type _CreateNavigatorRequest CreateNavigatorRequest + +// NewCreateNavigatorRequest instantiates a new CreateNavigatorRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNavigatorRequest(categories []Category, displayName string, entityMetrics []Metric, propertyIdentifierTemplate string, requiredProperties []string) *CreateNavigatorRequest { + this := CreateNavigatorRequest{} + this.Categories = categories + this.DisplayName = displayName + this.EntityMetrics = entityMetrics + this.PropertyIdentifierTemplate = propertyIdentifierTemplate + this.RequiredProperties = requiredProperties + return &this +} + +// NewCreateNavigatorRequestWithDefaults instantiates a new CreateNavigatorRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNavigatorRequestWithDefaults() *CreateNavigatorRequest { + this := CreateNavigatorRequest{} + return &this +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *CreateNavigatorRequest) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value +func (o *CreateNavigatorRequest) GetCategories() []Category { + if o == nil { + var ret []Category + return ret + } + + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetCategoriesOk() ([]Category, bool) { + if o == nil { + return nil, false + } + return o.Categories, true +} + +// SetCategories sets field value +func (o *CreateNavigatorRequest) SetCategories(v []Category) { + o.Categories = v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *CreateNavigatorRequest) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value +func (o *CreateNavigatorRequest) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CreateNavigatorRequest) SetDisplayName(v string) { + o.DisplayName = v +} + +// GetEntityMetrics returns the EntityMetrics field value +func (o *CreateNavigatorRequest) GetEntityMetrics() []Metric { + if o == nil { + var ret []Metric + return ret + } + + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil { + return nil, false + } + return o.EntityMetrics, true +} + +// SetEntityMetrics sets field value +func (o *CreateNavigatorRequest) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *CreateNavigatorRequest) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *CreateNavigatorRequest) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *CreateNavigatorRequest) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *CreateNavigatorRequest) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *CreateNavigatorRequest) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *CreateNavigatorRequest) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value +func (o *CreateNavigatorRequest) GetPropertyIdentifierTemplate() string { + if o == nil { + var ret string + return ret + } + + return o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.PropertyIdentifierTemplate, true +} + +// SetPropertyIdentifierTemplate sets field value +func (o *CreateNavigatorRequest) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = v +} + +// GetRequiredProperties returns the RequiredProperties field value +func (o *CreateNavigatorRequest) GetRequiredProperties() []string { + if o == nil { + var ret []string + return ret + } + + return o.RequiredProperties +} + +// GetRequiredPropertiesOk returns a tuple with the RequiredProperties field value +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetRequiredPropertiesOk() ([]string, bool) { + if o == nil { + return nil, false + } + return o.RequiredProperties, true +} + +// SetRequiredProperties sets field value +func (o *CreateNavigatorRequest) SetRequiredProperties(v []string) { + o.RequiredProperties = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *CreateNavigatorRequest) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *CreateNavigatorRequest) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *CreateNavigatorRequest) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *CreateNavigatorRequest) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorRequest) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *CreateNavigatorRequest) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *CreateNavigatorRequest) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o CreateNavigatorRequest) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CreateNavigatorRequest) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + toSerialize["categories"] = o.Categories + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + toSerialize["displayName"] = o.DisplayName + toSerialize["entityMetrics"] = o.EntityMetrics + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + toSerialize["requiredProperties"] = o.RequiredProperties + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +func (o *CreateNavigatorRequest) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "categories", + "displayName", + "entityMetrics", + "propertyIdentifierTemplate", + "requiredProperties", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varCreateNavigatorRequest := _CreateNavigatorRequest{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varCreateNavigatorRequest) + + if err != nil { + return err + } + + *o = CreateNavigatorRequest(varCreateNavigatorRequest) + + return err +} + +type NullableCreateNavigatorRequest struct { + value *CreateNavigatorRequest + isSet bool +} + +func (v NullableCreateNavigatorRequest) Get() *CreateNavigatorRequest { + return v.value +} + +func (v *NullableCreateNavigatorRequest) Set(val *CreateNavigatorRequest) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNavigatorRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNavigatorRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNavigatorRequest(val *CreateNavigatorRequest) *NullableCreateNavigatorRequest { + return &NullableCreateNavigatorRequest{value: val, isSet: true} +} + +func (v NullableCreateNavigatorRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNavigatorRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_create_navigator_response.go b/navigator/model_create_navigator_response.go new file mode 100644 index 0000000..d4293af --- /dev/null +++ b/navigator/model_create_navigator_response.go @@ -0,0 +1,903 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the CreateNavigatorResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateNavigatorResponse{} + +// CreateNavigatorResponse Create navigator response body +type CreateNavigatorResponse struct { + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator + Creator *string `json:"creator,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // Time at which the navigator was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + OwnerScope *OwnerScope `json:"ownerScope,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Properties shared by all instances + RequiredProperties []string `json:"requiredProperties,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewCreateNavigatorResponse instantiates a new CreateNavigatorResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateNavigatorResponse() *CreateNavigatorResponse { + this := CreateNavigatorResponse{} + return &this +} + +// NewCreateNavigatorResponseWithDefaults instantiates a new CreateNavigatorResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateNavigatorResponseWithDefaults() *CreateNavigatorResponse { + this := CreateNavigatorResponse{} + return &this +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *CreateNavigatorResponse) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *CreateNavigatorResponse) SetCategories(v []Category) { + o.Categories = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *CreateNavigatorResponse) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *CreateNavigatorResponse) SetCreator(v string) { + o.Creator = &v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *CreateNavigatorResponse) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *CreateNavigatorResponse) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *CreateNavigatorResponse) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *CreateNavigatorResponse) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *CreateNavigatorResponse) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *CreateNavigatorResponse) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *CreateNavigatorResponse) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *CreateNavigatorResponse) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *CreateNavigatorResponse) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *CreateNavigatorResponse) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *CreateNavigatorResponse) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetOwnerScope returns the OwnerScope field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetOwnerScope() OwnerScope { + if o == nil || IsNil(o.OwnerScope) { + var ret OwnerScope + return ret + } + return *o.OwnerScope +} + +// GetOwnerScopeOk returns a tuple with the OwnerScope field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetOwnerScopeOk() (*OwnerScope, bool) { + if o == nil || IsNil(o.OwnerScope) { + return nil, false + } + return o.OwnerScope, true +} + +// HasOwnerScope returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasOwnerScope() bool { + if o != nil && !IsNil(o.OwnerScope) { + return true + } + + return false +} + +// SetOwnerScope gets a reference to the given OwnerScope and assigns it to the OwnerScope field. +func (o *CreateNavigatorResponse) SetOwnerScope(v OwnerScope) { + o.OwnerScope = &v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *CreateNavigatorResponse) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetRequiredProperties returns the RequiredProperties field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetRequiredProperties() []string { + if o == nil || IsNil(o.RequiredProperties) { + var ret []string + return ret + } + return o.RequiredProperties +} + +// GetRequiredPropertiesOk returns a tuple with the RequiredProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetRequiredPropertiesOk() ([]string, bool) { + if o == nil || IsNil(o.RequiredProperties) { + return nil, false + } + return o.RequiredProperties, true +} + +// HasRequiredProperties returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasRequiredProperties() bool { + if o != nil && !IsNil(o.RequiredProperties) { + return true + } + + return false +} + +// SetRequiredProperties gets a reference to the given []string and assigns it to the RequiredProperties field. +func (o *CreateNavigatorResponse) SetRequiredProperties(v []string) { + o.RequiredProperties = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *CreateNavigatorResponse) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *CreateNavigatorResponse) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *CreateNavigatorResponse) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *CreateNavigatorResponse) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateNavigatorResponse) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *CreateNavigatorResponse) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *CreateNavigatorResponse) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o CreateNavigatorResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CreateNavigatorResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.OwnerScope) { + toSerialize["ownerScope"] = o.OwnerScope + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.RequiredProperties) { + toSerialize["requiredProperties"] = o.RequiredProperties + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableCreateNavigatorResponse struct { + value *CreateNavigatorResponse + isSet bool +} + +func (v NullableCreateNavigatorResponse) Get() *CreateNavigatorResponse { + return v.value +} + +func (v *NullableCreateNavigatorResponse) Set(val *CreateNavigatorResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateNavigatorResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateNavigatorResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateNavigatorResponse(val *CreateNavigatorResponse) *NullableCreateNavigatorResponse { + return &NullableCreateNavigatorResponse{value: val, isSet: true} +} + +func (v NullableCreateNavigatorResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateNavigatorResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_create_single_navigator_400_response.go b/navigator/model_create_single_navigator_400_response.go new file mode 100644 index 0000000..51658ab --- /dev/null +++ b/navigator/model_create_single_navigator_400_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the CreateSingleNavigator400Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateSingleNavigator400Response{} + +// CreateSingleNavigator400Response struct for CreateSingleNavigator400Response +type CreateSingleNavigator400Response struct { + // HTTP response code + Code *int32 `json:"code,omitempty"` + // Error explanation + Message *string `json:"message,omitempty"` +} + +// NewCreateSingleNavigator400Response instantiates a new CreateSingleNavigator400Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewCreateSingleNavigator400Response() *CreateSingleNavigator400Response { + this := CreateSingleNavigator400Response{} + return &this +} + +// NewCreateSingleNavigator400ResponseWithDefaults instantiates a new CreateSingleNavigator400Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewCreateSingleNavigator400ResponseWithDefaults() *CreateSingleNavigator400Response { + this := CreateSingleNavigator400Response{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *CreateSingleNavigator400Response) GetCode() int32 { + if o == nil || IsNil(o.Code) { + var ret int32 + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSingleNavigator400Response) GetCodeOk() (*int32, bool) { + if o == nil || IsNil(o.Code) { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *CreateSingleNavigator400Response) HasCode() bool { + if o != nil && !IsNil(o.Code) { + return true + } + + return false +} + +// SetCode gets a reference to the given int32 and assigns it to the Code field. +func (o *CreateSingleNavigator400Response) SetCode(v int32) { + o.Code = &v +} + +// GetMessage returns the Message field value if set, zero value otherwise. +func (o *CreateSingleNavigator400Response) GetMessage() string { + if o == nil || IsNil(o.Message) { + var ret string + return ret + } + return *o.Message +} + +// GetMessageOk returns a tuple with the Message field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateSingleNavigator400Response) GetMessageOk() (*string, bool) { + if o == nil || IsNil(o.Message) { + return nil, false + } + return o.Message, true +} + +// HasMessage returns a boolean if a field has been set. +func (o *CreateSingleNavigator400Response) HasMessage() bool { + if o != nil && !IsNil(o.Message) { + return true + } + + return false +} + +// SetMessage gets a reference to the given string and assigns it to the Message field. +func (o *CreateSingleNavigator400Response) SetMessage(v string) { + o.Message = &v +} + +func (o CreateSingleNavigator400Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o CreateSingleNavigator400Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Code) { + toSerialize["code"] = o.Code + } + if !IsNil(o.Message) { + toSerialize["message"] = o.Message + } + return toSerialize, nil +} + +type NullableCreateSingleNavigator400Response struct { + value *CreateSingleNavigator400Response + isSet bool +} + +func (v NullableCreateSingleNavigator400Response) Get() *CreateSingleNavigator400Response { + return v.value +} + +func (v *NullableCreateSingleNavigator400Response) Set(val *CreateSingleNavigator400Response) { + v.value = val + v.isSet = true +} + +func (v NullableCreateSingleNavigator400Response) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateSingleNavigator400Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateSingleNavigator400Response(val *CreateSingleNavigator400Response) *NullableCreateSingleNavigator400Response { + return &NullableCreateSingleNavigator400Response{value: val, isSet: true} +} + +func (v NullableCreateSingleNavigator400Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateSingleNavigator400Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_acl.go b/navigator/model_dashboard_acl.go new file mode 100644 index 0000000..fd47368 --- /dev/null +++ b/navigator/model_dashboard_acl.go @@ -0,0 +1,201 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardACL type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardACL{} + +// DashboardACL A permission configuration for a user, team, or organization. +type DashboardACL struct { + // Action the user, team, or organization can take. + Actions []string `json:"actions,omitempty"` + // Clarify whether this permission configuration is for a user, a team, or an organization. + PrincipalType *string `json:"principalType,omitempty"` + // ID of the user, team, or organization. + PrincipalId *string `json:"principalId,omitempty"` +} + +// NewDashboardACL instantiates a new DashboardACL object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardACL() *DashboardACL { + this := DashboardACL{} + return &this +} + +// NewDashboardACLWithDefaults instantiates a new DashboardACL object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardACLWithDefaults() *DashboardACL { + this := DashboardACL{} + return &this +} + +// GetActions returns the Actions field value if set, zero value otherwise. +func (o *DashboardACL) GetActions() []string { + if o == nil || IsNil(o.Actions) { + var ret []string + return ret + } + return o.Actions +} + +// GetActionsOk returns a tuple with the Actions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardACL) GetActionsOk() ([]string, bool) { + if o == nil || IsNil(o.Actions) { + return nil, false + } + return o.Actions, true +} + +// HasActions returns a boolean if a field has been set. +func (o *DashboardACL) HasActions() bool { + if o != nil && !IsNil(o.Actions) { + return true + } + + return false +} + +// SetActions gets a reference to the given []string and assigns it to the Actions field. +func (o *DashboardACL) SetActions(v []string) { + o.Actions = v +} + +// GetPrincipalType returns the PrincipalType field value if set, zero value otherwise. +func (o *DashboardACL) GetPrincipalType() string { + if o == nil || IsNil(o.PrincipalType) { + var ret string + return ret + } + return *o.PrincipalType +} + +// GetPrincipalTypeOk returns a tuple with the PrincipalType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardACL) GetPrincipalTypeOk() (*string, bool) { + if o == nil || IsNil(o.PrincipalType) { + return nil, false + } + return o.PrincipalType, true +} + +// HasPrincipalType returns a boolean if a field has been set. +func (o *DashboardACL) HasPrincipalType() bool { + if o != nil && !IsNil(o.PrincipalType) { + return true + } + + return false +} + +// SetPrincipalType gets a reference to the given string and assigns it to the PrincipalType field. +func (o *DashboardACL) SetPrincipalType(v string) { + o.PrincipalType = &v +} + +// GetPrincipalId returns the PrincipalId field value if set, zero value otherwise. +func (o *DashboardACL) GetPrincipalId() string { + if o == nil || IsNil(o.PrincipalId) { + var ret string + return ret + } + return *o.PrincipalId +} + +// GetPrincipalIdOk returns a tuple with the PrincipalId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardACL) GetPrincipalIdOk() (*string, bool) { + if o == nil || IsNil(o.PrincipalId) { + return nil, false + } + return o.PrincipalId, true +} + +// HasPrincipalId returns a boolean if a field has been set. +func (o *DashboardACL) HasPrincipalId() bool { + if o != nil && !IsNil(o.PrincipalId) { + return true + } + + return false +} + +// SetPrincipalId gets a reference to the given string and assigns it to the PrincipalId field. +func (o *DashboardACL) SetPrincipalId(v string) { + o.PrincipalId = &v +} + +func (o DashboardACL) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardACL) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Actions) { + toSerialize["actions"] = o.Actions + } + if !IsNil(o.PrincipalType) { + toSerialize["principalType"] = o.PrincipalType + } + if !IsNil(o.PrincipalId) { + toSerialize["principalId"] = o.PrincipalId + } + return toSerialize, nil +} + +type NullableDashboardACL struct { + value *DashboardACL + isSet bool +} + +func (v NullableDashboardACL) Get() *DashboardACL { + return v.value +} + +func (v *NullableDashboardACL) Set(val *DashboardACL) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardACL) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardACL) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardACL(val *DashboardACL) *NullableDashboardACL { + return &NullableDashboardACL{value: val, isSet: true} +} + +func (v NullableDashboardACL) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardACL) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_authorized_writers.go b/navigator/model_dashboard_authorized_writers.go new file mode 100644 index 0000000..f0c73a7 --- /dev/null +++ b/navigator/model_dashboard_authorized_writers.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardAuthorizedWriters type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardAuthorizedWriters{} + +// DashboardAuthorizedWriters List of user and team IDs that can modify charts in this dashboard +type DashboardAuthorizedWriters struct { + // List of teams that can modify charts in this dashboard + Teams []string `json:"teams,omitempty"` + // List of teams that can modify charts in this dashboard + Users []string `json:"users,omitempty"` +} + +// NewDashboardAuthorizedWriters instantiates a new DashboardAuthorizedWriters object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardAuthorizedWriters() *DashboardAuthorizedWriters { + this := DashboardAuthorizedWriters{} + return &this +} + +// NewDashboardAuthorizedWritersWithDefaults instantiates a new DashboardAuthorizedWriters object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardAuthorizedWritersWithDefaults() *DashboardAuthorizedWriters { + this := DashboardAuthorizedWriters{} + return &this +} + +// GetTeams returns the Teams field value if set, zero value otherwise. +func (o *DashboardAuthorizedWriters) GetTeams() []string { + if o == nil || IsNil(o.Teams) { + var ret []string + return ret + } + return o.Teams +} + +// GetTeamsOk returns a tuple with the Teams field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardAuthorizedWriters) GetTeamsOk() ([]string, bool) { + if o == nil || IsNil(o.Teams) { + return nil, false + } + return o.Teams, true +} + +// HasTeams returns a boolean if a field has been set. +func (o *DashboardAuthorizedWriters) HasTeams() bool { + if o != nil && !IsNil(o.Teams) { + return true + } + + return false +} + +// SetTeams gets a reference to the given []string and assigns it to the Teams field. +func (o *DashboardAuthorizedWriters) SetTeams(v []string) { + o.Teams = v +} + +// GetUsers returns the Users field value if set, zero value otherwise. +func (o *DashboardAuthorizedWriters) GetUsers() []string { + if o == nil || IsNil(o.Users) { + var ret []string + return ret + } + return o.Users +} + +// GetUsersOk returns a tuple with the Users field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardAuthorizedWriters) GetUsersOk() ([]string, bool) { + if o == nil || IsNil(o.Users) { + return nil, false + } + return o.Users, true +} + +// HasUsers returns a boolean if a field has been set. +func (o *DashboardAuthorizedWriters) HasUsers() bool { + if o != nil && !IsNil(o.Users) { + return true + } + + return false +} + +// SetUsers gets a reference to the given []string and assigns it to the Users field. +func (o *DashboardAuthorizedWriters) SetUsers(v []string) { + o.Users = v +} + +func (o DashboardAuthorizedWriters) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardAuthorizedWriters) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Teams) { + toSerialize["teams"] = o.Teams + } + if !IsNil(o.Users) { + toSerialize["users"] = o.Users + } + return toSerialize, nil +} + +type NullableDashboardAuthorizedWriters struct { + value *DashboardAuthorizedWriters + isSet bool +} + +func (v NullableDashboardAuthorizedWriters) Get() *DashboardAuthorizedWriters { + return v.value +} + +func (v *NullableDashboardAuthorizedWriters) Set(val *DashboardAuthorizedWriters) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardAuthorizedWriters) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardAuthorizedWriters) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardAuthorizedWriters(val *DashboardAuthorizedWriters) *NullableDashboardAuthorizedWriters { + return &NullableDashboardAuthorizedWriters{value: val, isSet: true} +} + +func (v NullableDashboardAuthorizedWriters) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardAuthorizedWriters) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_chart_density.go b/navigator/model_dashboard_chart_density.go new file mode 100644 index 0000000..48aaa2b --- /dev/null +++ b/navigator/model_dashboard_chart_density.go @@ -0,0 +1,115 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "fmt" +) + +// DashboardChartDensity Number of data points displayed in charts in this dashboard +type DashboardChartDensity string + +// List of DashboardChartDensity +const ( + DEFAULT DashboardChartDensity = "DEFAULT" + LOW DashboardChartDensity = "LOW" + HIGH DashboardChartDensity = "HIGH" + HIGHEST DashboardChartDensity = "HIGHEST" +) + +// All allowed values of DashboardChartDensity enum +var AllowedDashboardChartDensityEnumValues = []DashboardChartDensity{ + "DEFAULT", + "LOW", + "HIGH", + "HIGHEST", +} + +func (v *DashboardChartDensity) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := DashboardChartDensity(value) + for _, existing := range AllowedDashboardChartDensityEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + return fmt.Errorf("%+v is not a valid DashboardChartDensity", value) +} + +// NewDashboardChartDensityFromValue returns a pointer to a valid DashboardChartDensity +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewDashboardChartDensityFromValue(v string) (*DashboardChartDensity, error) { + ev := DashboardChartDensity(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for DashboardChartDensity: valid values are %v", v, AllowedDashboardChartDensityEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v DashboardChartDensity) IsValid() bool { + for _, existing := range AllowedDashboardChartDensityEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to DashboardChartDensity value +func (v DashboardChartDensity) Ptr() *DashboardChartDensity { + return &v +} + +type NullableDashboardChartDensity struct { + value *DashboardChartDensity + isSet bool +} + +func (v NullableDashboardChartDensity) Get() *DashboardChartDensity { + return v.value +} + +func (v *NullableDashboardChartDensity) Set(val *DashboardChartDensity) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartDensity) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartDensity) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartDensity(val *DashboardChartDensity) *NullableDashboardChartDensity { + return &NullableDashboardChartDensity{value: val, isSet: true} +} + +func (v NullableDashboardChartDensity) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartDensity) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + diff --git a/navigator/model_dashboard_chart_event_overlay.go b/navigator/model_dashboard_chart_event_overlay.go new file mode 100644 index 0000000..b1bbdee --- /dev/null +++ b/navigator/model_dashboard_chart_event_overlay.go @@ -0,0 +1,232 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the DashboardChartEventOverlay type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartEventOverlay{} + +// DashboardChartEventOverlay Properties of an event overlay applied to each chart in a dashboard +type DashboardChartEventOverlay struct { + EventSignal DashboardEventSignal `json:"eventSignal"` + // Event overlay ID. Set by system. + OverlayId *string `json:"overlayId,omitempty"` + // List of filters to apply to events for this overlay + Sources []DashboardEventSources `json:"sources,omitempty"` +} + +type _DashboardChartEventOverlay DashboardChartEventOverlay + +// NewDashboardChartEventOverlay instantiates a new DashboardChartEventOverlay object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartEventOverlay(eventSignal DashboardEventSignal) *DashboardChartEventOverlay { + this := DashboardChartEventOverlay{} + this.EventSignal = eventSignal + return &this +} + +// NewDashboardChartEventOverlayWithDefaults instantiates a new DashboardChartEventOverlay object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartEventOverlayWithDefaults() *DashboardChartEventOverlay { + this := DashboardChartEventOverlay{} + return &this +} + +// GetEventSignal returns the EventSignal field value +func (o *DashboardChartEventOverlay) GetEventSignal() DashboardEventSignal { + if o == nil { + var ret DashboardEventSignal + return ret + } + + return o.EventSignal +} + +// GetEventSignalOk returns a tuple with the EventSignal field value +// and a boolean to check if the value has been set. +func (o *DashboardChartEventOverlay) GetEventSignalOk() (*DashboardEventSignal, bool) { + if o == nil { + return nil, false + } + return &o.EventSignal, true +} + +// SetEventSignal sets field value +func (o *DashboardChartEventOverlay) SetEventSignal(v DashboardEventSignal) { + o.EventSignal = v +} + +// GetOverlayId returns the OverlayId field value if set, zero value otherwise. +func (o *DashboardChartEventOverlay) GetOverlayId() string { + if o == nil || IsNil(o.OverlayId) { + var ret string + return ret + } + return *o.OverlayId +} + +// GetOverlayIdOk returns a tuple with the OverlayId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartEventOverlay) GetOverlayIdOk() (*string, bool) { + if o == nil || IsNil(o.OverlayId) { + return nil, false + } + return o.OverlayId, true +} + +// HasOverlayId returns a boolean if a field has been set. +func (o *DashboardChartEventOverlay) HasOverlayId() bool { + if o != nil && !IsNil(o.OverlayId) { + return true + } + + return false +} + +// SetOverlayId gets a reference to the given string and assigns it to the OverlayId field. +func (o *DashboardChartEventOverlay) SetOverlayId(v string) { + o.OverlayId = &v +} + +// GetSources returns the Sources field value if set, zero value otherwise. +func (o *DashboardChartEventOverlay) GetSources() []DashboardEventSources { + if o == nil || IsNil(o.Sources) { + var ret []DashboardEventSources + return ret + } + return o.Sources +} + +// GetSourcesOk returns a tuple with the Sources field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartEventOverlay) GetSourcesOk() ([]DashboardEventSources, bool) { + if o == nil || IsNil(o.Sources) { + return nil, false + } + return o.Sources, true +} + +// HasSources returns a boolean if a field has been set. +func (o *DashboardChartEventOverlay) HasSources() bool { + if o != nil && !IsNil(o.Sources) { + return true + } + + return false +} + +// SetSources gets a reference to the given []DashboardEventSources and assigns it to the Sources field. +func (o *DashboardChartEventOverlay) SetSources(v []DashboardEventSources) { + o.Sources = v +} + +func (o DashboardChartEventOverlay) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartEventOverlay) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["eventSignal"] = o.EventSignal + if !IsNil(o.OverlayId) { + toSerialize["overlayId"] = o.OverlayId + } + if !IsNil(o.Sources) { + toSerialize["sources"] = o.Sources + } + return toSerialize, nil +} + +func (o *DashboardChartEventOverlay) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "eventSignal", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDashboardChartEventOverlay := _DashboardChartEventOverlay{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varDashboardChartEventOverlay) + + if err != nil { + return err + } + + *o = DashboardChartEventOverlay(varDashboardChartEventOverlay) + + return err +} + +type NullableDashboardChartEventOverlay struct { + value *DashboardChartEventOverlay + isSet bool +} + +func (v NullableDashboardChartEventOverlay) Get() *DashboardChartEventOverlay { + return v.value +} + +func (v *NullableDashboardChartEventOverlay) Set(val *DashboardChartEventOverlay) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartEventOverlay) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartEventOverlay) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartEventOverlay(val *DashboardChartEventOverlay) *NullableDashboardChartEventOverlay { + return &NullableDashboardChartEventOverlay{value: val, isSet: true} +} + +func (v NullableDashboardChartEventOverlay) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartEventOverlay) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_chart_settings_object.go b/navigator/model_dashboard_chart_settings_object.go new file mode 100644 index 0000000..97af13f --- /dev/null +++ b/navigator/model_dashboard_chart_settings_object.go @@ -0,0 +1,275 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the DashboardChartSettingsObject type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartSettingsObject{} + +// DashboardChartSettingsObject The dashboard settings for a chart in a dashboard. +type DashboardChartSettingsObject struct { + // ID of an existing chart. + ChartId string `json:"chartId"` + // Index of the horizontal position of the chart in the dashboard display + Column int32 `json:"column"` + // Number of rows this chart should span + Height int32 `json:"height"` + // Index of the vertical position of the chart in the dashboard display + Row int32 `json:"row"` + // Number of columns this chart should span in the dashboard display + Width int32 `json:"width"` +} + +type _DashboardChartSettingsObject DashboardChartSettingsObject + +// NewDashboardChartSettingsObject instantiates a new DashboardChartSettingsObject object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartSettingsObject(chartId string, column int32, height int32, row int32, width int32) *DashboardChartSettingsObject { + this := DashboardChartSettingsObject{} + this.ChartId = chartId + this.Column = column + this.Height = height + this.Row = row + this.Width = width + return &this +} + +// NewDashboardChartSettingsObjectWithDefaults instantiates a new DashboardChartSettingsObject object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartSettingsObjectWithDefaults() *DashboardChartSettingsObject { + this := DashboardChartSettingsObject{} + return &this +} + +// GetChartId returns the ChartId field value +func (o *DashboardChartSettingsObject) GetChartId() string { + if o == nil { + var ret string + return ret + } + + return o.ChartId +} + +// GetChartIdOk returns a tuple with the ChartId field value +// and a boolean to check if the value has been set. +func (o *DashboardChartSettingsObject) GetChartIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.ChartId, true +} + +// SetChartId sets field value +func (o *DashboardChartSettingsObject) SetChartId(v string) { + o.ChartId = v +} + +// GetColumn returns the Column field value +func (o *DashboardChartSettingsObject) GetColumn() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Column +} + +// GetColumnOk returns a tuple with the Column field value +// and a boolean to check if the value has been set. +func (o *DashboardChartSettingsObject) GetColumnOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Column, true +} + +// SetColumn sets field value +func (o *DashboardChartSettingsObject) SetColumn(v int32) { + o.Column = v +} + +// GetHeight returns the Height field value +func (o *DashboardChartSettingsObject) GetHeight() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Height +} + +// GetHeightOk returns a tuple with the Height field value +// and a boolean to check if the value has been set. +func (o *DashboardChartSettingsObject) GetHeightOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Height, true +} + +// SetHeight sets field value +func (o *DashboardChartSettingsObject) SetHeight(v int32) { + o.Height = v +} + +// GetRow returns the Row field value +func (o *DashboardChartSettingsObject) GetRow() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Row +} + +// GetRowOk returns a tuple with the Row field value +// and a boolean to check if the value has been set. +func (o *DashboardChartSettingsObject) GetRowOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Row, true +} + +// SetRow sets field value +func (o *DashboardChartSettingsObject) SetRow(v int32) { + o.Row = v +} + +// GetWidth returns the Width field value +func (o *DashboardChartSettingsObject) GetWidth() int32 { + if o == nil { + var ret int32 + return ret + } + + return o.Width +} + +// GetWidthOk returns a tuple with the Width field value +// and a boolean to check if the value has been set. +func (o *DashboardChartSettingsObject) GetWidthOk() (*int32, bool) { + if o == nil { + return nil, false + } + return &o.Width, true +} + +// SetWidth sets field value +func (o *DashboardChartSettingsObject) SetWidth(v int32) { + o.Width = v +} + +func (o DashboardChartSettingsObject) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartSettingsObject) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["chartId"] = o.ChartId + toSerialize["column"] = o.Column + toSerialize["height"] = o.Height + toSerialize["row"] = o.Row + toSerialize["width"] = o.Width + return toSerialize, nil +} + +func (o *DashboardChartSettingsObject) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "chartId", + "column", + "height", + "row", + "width", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDashboardChartSettingsObject := _DashboardChartSettingsObject{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varDashboardChartSettingsObject) + + if err != nil { + return err + } + + *o = DashboardChartSettingsObject(varDashboardChartSettingsObject) + + return err +} + +type NullableDashboardChartSettingsObject struct { + value *DashboardChartSettingsObject + isSet bool +} + +func (v NullableDashboardChartSettingsObject) Get() *DashboardChartSettingsObject { + return v.value +} + +func (v *NullableDashboardChartSettingsObject) Set(val *DashboardChartSettingsObject) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartSettingsObject) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartSettingsObject) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartSettingsObject(val *DashboardChartSettingsObject) *NullableDashboardChartSettingsObject { + return &NullableDashboardChartSettingsObject{value: val, isSet: true} +} + +func (v NullableDashboardChartSettingsObject) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartSettingsObject) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_charts_filters.go b/navigator/model_dashboard_charts_filters.go new file mode 100644 index 0000000..c5565ce --- /dev/null +++ b/navigator/model_dashboard_charts_filters.go @@ -0,0 +1,200 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardChartsFilters type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartsFilters{} + +// DashboardChartsFilters List of filters to apply to all the charts in a dashboard +type DashboardChartsFilters struct { + // List of filters to apply to charts in the dashboard + Sources []DashboardChartsSingleFilter `json:"sources,omitempty"` + Time *DashboardChartsFiltersTime `json:"time,omitempty"` + // List of filters for use in the UI + Variables []DashboardChartsWebUIFilter `json:"variables,omitempty"` +} + +// NewDashboardChartsFilters instantiates a new DashboardChartsFilters object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartsFilters() *DashboardChartsFilters { + this := DashboardChartsFilters{} + return &this +} + +// NewDashboardChartsFiltersWithDefaults instantiates a new DashboardChartsFilters object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartsFiltersWithDefaults() *DashboardChartsFilters { + this := DashboardChartsFilters{} + return &this +} + +// GetSources returns the Sources field value if set, zero value otherwise. +func (o *DashboardChartsFilters) GetSources() []DashboardChartsSingleFilter { + if o == nil || IsNil(o.Sources) { + var ret []DashboardChartsSingleFilter + return ret + } + return o.Sources +} + +// GetSourcesOk returns a tuple with the Sources field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsFilters) GetSourcesOk() ([]DashboardChartsSingleFilter, bool) { + if o == nil || IsNil(o.Sources) { + return nil, false + } + return o.Sources, true +} + +// HasSources returns a boolean if a field has been set. +func (o *DashboardChartsFilters) HasSources() bool { + if o != nil && !IsNil(o.Sources) { + return true + } + + return false +} + +// SetSources gets a reference to the given []DashboardChartsSingleFilter and assigns it to the Sources field. +func (o *DashboardChartsFilters) SetSources(v []DashboardChartsSingleFilter) { + o.Sources = v +} + +// GetTime returns the Time field value if set, zero value otherwise. +func (o *DashboardChartsFilters) GetTime() DashboardChartsFiltersTime { + if o == nil || IsNil(o.Time) { + var ret DashboardChartsFiltersTime + return ret + } + return *o.Time +} + +// GetTimeOk returns a tuple with the Time field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsFilters) GetTimeOk() (*DashboardChartsFiltersTime, bool) { + if o == nil || IsNil(o.Time) { + return nil, false + } + return o.Time, true +} + +// HasTime returns a boolean if a field has been set. +func (o *DashboardChartsFilters) HasTime() bool { + if o != nil && !IsNil(o.Time) { + return true + } + + return false +} + +// SetTime gets a reference to the given DashboardChartsFiltersTime and assigns it to the Time field. +func (o *DashboardChartsFilters) SetTime(v DashboardChartsFiltersTime) { + o.Time = &v +} + +// GetVariables returns the Variables field value if set, zero value otherwise. +func (o *DashboardChartsFilters) GetVariables() []DashboardChartsWebUIFilter { + if o == nil || IsNil(o.Variables) { + var ret []DashboardChartsWebUIFilter + return ret + } + return o.Variables +} + +// GetVariablesOk returns a tuple with the Variables field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsFilters) GetVariablesOk() ([]DashboardChartsWebUIFilter, bool) { + if o == nil || IsNil(o.Variables) { + return nil, false + } + return o.Variables, true +} + +// HasVariables returns a boolean if a field has been set. +func (o *DashboardChartsFilters) HasVariables() bool { + if o != nil && !IsNil(o.Variables) { + return true + } + + return false +} + +// SetVariables gets a reference to the given []DashboardChartsWebUIFilter and assigns it to the Variables field. +func (o *DashboardChartsFilters) SetVariables(v []DashboardChartsWebUIFilter) { + o.Variables = v +} + +func (o DashboardChartsFilters) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartsFilters) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Sources) { + toSerialize["sources"] = o.Sources + } + if !IsNil(o.Time) { + toSerialize["time"] = o.Time + } + if !IsNil(o.Variables) { + toSerialize["variables"] = o.Variables + } + return toSerialize, nil +} + +type NullableDashboardChartsFilters struct { + value *DashboardChartsFilters + isSet bool +} + +func (v NullableDashboardChartsFilters) Get() *DashboardChartsFilters { + return v.value +} + +func (v *NullableDashboardChartsFilters) Set(val *DashboardChartsFilters) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartsFilters) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartsFilters) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartsFilters(val *DashboardChartsFilters) *NullableDashboardChartsFilters { + return &NullableDashboardChartsFilters{value: val, isSet: true} +} + +func (v NullableDashboardChartsFilters) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartsFilters) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_charts_filters_time.go b/navigator/model_dashboard_charts_filters_time.go new file mode 100644 index 0000000..75afc20 --- /dev/null +++ b/navigator/model_dashboard_charts_filters_time.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardChartsFiltersTime type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartsFiltersTime{} + +// DashboardChartsFiltersTime Time range to show in all charts in the dashboard +type DashboardChartsFiltersTime struct { + // End of the time range to show for the charts in this dashboard + End *string `json:"end,omitempty"` + // Start of the time range to show for the charts in this dashboard. + Start *string `json:"start,omitempty"` +} + +// NewDashboardChartsFiltersTime instantiates a new DashboardChartsFiltersTime object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartsFiltersTime() *DashboardChartsFiltersTime { + this := DashboardChartsFiltersTime{} + return &this +} + +// NewDashboardChartsFiltersTimeWithDefaults instantiates a new DashboardChartsFiltersTime object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartsFiltersTimeWithDefaults() *DashboardChartsFiltersTime { + this := DashboardChartsFiltersTime{} + return &this +} + +// GetEnd returns the End field value if set, zero value otherwise. +func (o *DashboardChartsFiltersTime) GetEnd() string { + if o == nil || IsNil(o.End) { + var ret string + return ret + } + return *o.End +} + +// GetEndOk returns a tuple with the End field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsFiltersTime) GetEndOk() (*string, bool) { + if o == nil || IsNil(o.End) { + return nil, false + } + return o.End, true +} + +// HasEnd returns a boolean if a field has been set. +func (o *DashboardChartsFiltersTime) HasEnd() bool { + if o != nil && !IsNil(o.End) { + return true + } + + return false +} + +// SetEnd gets a reference to the given string and assigns it to the End field. +func (o *DashboardChartsFiltersTime) SetEnd(v string) { + o.End = &v +} + +// GetStart returns the Start field value if set, zero value otherwise. +func (o *DashboardChartsFiltersTime) GetStart() string { + if o == nil || IsNil(o.Start) { + var ret string + return ret + } + return *o.Start +} + +// GetStartOk returns a tuple with the Start field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsFiltersTime) GetStartOk() (*string, bool) { + if o == nil || IsNil(o.Start) { + return nil, false + } + return o.Start, true +} + +// HasStart returns a boolean if a field has been set. +func (o *DashboardChartsFiltersTime) HasStart() bool { + if o != nil && !IsNil(o.Start) { + return true + } + + return false +} + +// SetStart gets a reference to the given string and assigns it to the Start field. +func (o *DashboardChartsFiltersTime) SetStart(v string) { + o.Start = &v +} + +func (o DashboardChartsFiltersTime) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartsFiltersTime) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.End) { + toSerialize["end"] = o.End + } + if !IsNil(o.Start) { + toSerialize["start"] = o.Start + } + return toSerialize, nil +} + +type NullableDashboardChartsFiltersTime struct { + value *DashboardChartsFiltersTime + isSet bool +} + +func (v NullableDashboardChartsFiltersTime) Get() *DashboardChartsFiltersTime { + return v.value +} + +func (v *NullableDashboardChartsFiltersTime) Set(val *DashboardChartsFiltersTime) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartsFiltersTime) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartsFiltersTime) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartsFiltersTime(val *DashboardChartsFiltersTime) *NullableDashboardChartsFiltersTime { + return &NullableDashboardChartsFiltersTime{value: val, isSet: true} +} + +func (v NullableDashboardChartsFiltersTime) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartsFiltersTime) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_charts_single_filter.go b/navigator/model_dashboard_charts_single_filter.go new file mode 100644 index 0000000..fc38a94 --- /dev/null +++ b/navigator/model_dashboard_charts_single_filter.go @@ -0,0 +1,229 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the DashboardChartsSingleFilter type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartsSingleFilter{} + +// DashboardChartsSingleFilter Single filter applied to charts in the dashboard +type DashboardChartsSingleFilter struct { + // Inverts the filter comparison + NOT *bool `json:"NOT,omitempty"` + // Custom property or dimension for which you want to test the value + Property string `json:"property"` + // List of values to test against the property or dimension + Value []string `json:"value"` +} + +type _DashboardChartsSingleFilter DashboardChartsSingleFilter + +// NewDashboardChartsSingleFilter instantiates a new DashboardChartsSingleFilter object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartsSingleFilter(property string, value []string) *DashboardChartsSingleFilter { + this := DashboardChartsSingleFilter{} + var nOT bool = false + this.NOT = &nOT + this.Property = property + this.Value = value + return &this +} + +// NewDashboardChartsSingleFilterWithDefaults instantiates a new DashboardChartsSingleFilter object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartsSingleFilterWithDefaults() *DashboardChartsSingleFilter { + this := DashboardChartsSingleFilter{} + var nOT bool = false + this.NOT = &nOT + return &this +} + +// GetNOT returns the NOT field value if set, zero value otherwise. +func (o *DashboardChartsSingleFilter) GetNOT() bool { + if o == nil || IsNil(o.NOT) { + var ret bool + return ret + } + return *o.NOT +} + +// GetNOTOk returns a tuple with the NOT field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsSingleFilter) GetNOTOk() (*bool, bool) { + if o == nil || IsNil(o.NOT) { + return nil, false + } + return o.NOT, true +} + +// HasNOT returns a boolean if a field has been set. +func (o *DashboardChartsSingleFilter) HasNOT() bool { + if o != nil && !IsNil(o.NOT) { + return true + } + + return false +} + +// SetNOT gets a reference to the given bool and assigns it to the NOT field. +func (o *DashboardChartsSingleFilter) SetNOT(v bool) { + o.NOT = &v +} + +// GetProperty returns the Property field value +func (o *DashboardChartsSingleFilter) GetProperty() string { + if o == nil { + var ret string + return ret + } + + return o.Property +} + +// GetPropertyOk returns a tuple with the Property field value +// and a boolean to check if the value has been set. +func (o *DashboardChartsSingleFilter) GetPropertyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Property, true +} + +// SetProperty sets field value +func (o *DashboardChartsSingleFilter) SetProperty(v string) { + o.Property = v +} + +// GetValue returns the Value field value +func (o *DashboardChartsSingleFilter) GetValue() []string { + if o == nil { + var ret []string + return ret + } + + return o.Value +} + +// GetValueOk returns a tuple with the Value field value +// and a boolean to check if the value has been set. +func (o *DashboardChartsSingleFilter) GetValueOk() ([]string, bool) { + if o == nil { + return nil, false + } + return o.Value, true +} + +// SetValue sets field value +func (o *DashboardChartsSingleFilter) SetValue(v []string) { + o.Value = v +} + +func (o DashboardChartsSingleFilter) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartsSingleFilter) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.NOT) { + toSerialize["NOT"] = o.NOT + } + toSerialize["property"] = o.Property + toSerialize["value"] = o.Value + return toSerialize, nil +} + +func (o *DashboardChartsSingleFilter) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "property", + "value", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDashboardChartsSingleFilter := _DashboardChartsSingleFilter{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varDashboardChartsSingleFilter) + + if err != nil { + return err + } + + *o = DashboardChartsSingleFilter(varDashboardChartsSingleFilter) + + return err +} + +type NullableDashboardChartsSingleFilter struct { + value *DashboardChartsSingleFilter + isSet bool +} + +func (v NullableDashboardChartsSingleFilter) Get() *DashboardChartsSingleFilter { + return v.value +} + +func (v *NullableDashboardChartsSingleFilter) Set(val *DashboardChartsSingleFilter) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartsSingleFilter) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartsSingleFilter) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartsSingleFilter(val *DashboardChartsSingleFilter) *NullableDashboardChartsSingleFilter { + return &NullableDashboardChartsSingleFilter{value: val, isSet: true} +} + +func (v NullableDashboardChartsSingleFilter) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartsSingleFilter) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_charts_web_ui_filter.go b/navigator/model_dashboard_charts_web_ui_filter.go new file mode 100644 index 0000000..6f79d14 --- /dev/null +++ b/navigator/model_dashboard_charts_web_ui_filter.go @@ -0,0 +1,344 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the DashboardChartsWebUIFilter type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardChartsWebUIFilter{} + +// DashboardChartsWebUIFilter Filter that compares a dimension or property to a value +type DashboardChartsWebUIFilter struct { + // Label for the filter + Alias *string `json:"alias,omitempty"` + // List of of values to place at the top of the values dropdown list + PreferredSuggestions []string `json:"preferredSuggestions,omitempty"` + // Custom property or dimension name + Property string `json:"property"` + // Controls display of chart data + Required *bool `json:"required,omitempty"` + // Controls values allowed in the filter + Restricted *bool `json:"restricted,omitempty"` + // List of values to compare to the dimension or custom property + Value []string `json:"value"` +} + +type _DashboardChartsWebUIFilter DashboardChartsWebUIFilter + +// NewDashboardChartsWebUIFilter instantiates a new DashboardChartsWebUIFilter object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardChartsWebUIFilter(property string, value []string) *DashboardChartsWebUIFilter { + this := DashboardChartsWebUIFilter{} + this.Property = property + var required bool = false + this.Required = &required + var restricted bool = false + this.Restricted = &restricted + this.Value = value + return &this +} + +// NewDashboardChartsWebUIFilterWithDefaults instantiates a new DashboardChartsWebUIFilter object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardChartsWebUIFilterWithDefaults() *DashboardChartsWebUIFilter { + this := DashboardChartsWebUIFilter{} + var required bool = false + this.Required = &required + var restricted bool = false + this.Restricted = &restricted + return &this +} + +// GetAlias returns the Alias field value if set, zero value otherwise. +func (o *DashboardChartsWebUIFilter) GetAlias() string { + if o == nil || IsNil(o.Alias) { + var ret string + return ret + } + return *o.Alias +} + +// GetAliasOk returns a tuple with the Alias field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetAliasOk() (*string, bool) { + if o == nil || IsNil(o.Alias) { + return nil, false + } + return o.Alias, true +} + +// HasAlias returns a boolean if a field has been set. +func (o *DashboardChartsWebUIFilter) HasAlias() bool { + if o != nil && !IsNil(o.Alias) { + return true + } + + return false +} + +// SetAlias gets a reference to the given string and assigns it to the Alias field. +func (o *DashboardChartsWebUIFilter) SetAlias(v string) { + o.Alias = &v +} + +// GetPreferredSuggestions returns the PreferredSuggestions field value if set, zero value otherwise. +func (o *DashboardChartsWebUIFilter) GetPreferredSuggestions() []string { + if o == nil || IsNil(o.PreferredSuggestions) { + var ret []string + return ret + } + return o.PreferredSuggestions +} + +// GetPreferredSuggestionsOk returns a tuple with the PreferredSuggestions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetPreferredSuggestionsOk() ([]string, bool) { + if o == nil || IsNil(o.PreferredSuggestions) { + return nil, false + } + return o.PreferredSuggestions, true +} + +// HasPreferredSuggestions returns a boolean if a field has been set. +func (o *DashboardChartsWebUIFilter) HasPreferredSuggestions() bool { + if o != nil && !IsNil(o.PreferredSuggestions) { + return true + } + + return false +} + +// SetPreferredSuggestions gets a reference to the given []string and assigns it to the PreferredSuggestions field. +func (o *DashboardChartsWebUIFilter) SetPreferredSuggestions(v []string) { + o.PreferredSuggestions = v +} + +// GetProperty returns the Property field value +func (o *DashboardChartsWebUIFilter) GetProperty() string { + if o == nil { + var ret string + return ret + } + + return o.Property +} + +// GetPropertyOk returns a tuple with the Property field value +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetPropertyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Property, true +} + +// SetProperty sets field value +func (o *DashboardChartsWebUIFilter) SetProperty(v string) { + o.Property = v +} + +// GetRequired returns the Required field value if set, zero value otherwise. +func (o *DashboardChartsWebUIFilter) GetRequired() bool { + if o == nil || IsNil(o.Required) { + var ret bool + return ret + } + return *o.Required +} + +// GetRequiredOk returns a tuple with the Required field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetRequiredOk() (*bool, bool) { + if o == nil || IsNil(o.Required) { + return nil, false + } + return o.Required, true +} + +// HasRequired returns a boolean if a field has been set. +func (o *DashboardChartsWebUIFilter) HasRequired() bool { + if o != nil && !IsNil(o.Required) { + return true + } + + return false +} + +// SetRequired gets a reference to the given bool and assigns it to the Required field. +func (o *DashboardChartsWebUIFilter) SetRequired(v bool) { + o.Required = &v +} + +// GetRestricted returns the Restricted field value if set, zero value otherwise. +func (o *DashboardChartsWebUIFilter) GetRestricted() bool { + if o == nil || IsNil(o.Restricted) { + var ret bool + return ret + } + return *o.Restricted +} + +// GetRestrictedOk returns a tuple with the Restricted field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetRestrictedOk() (*bool, bool) { + if o == nil || IsNil(o.Restricted) { + return nil, false + } + return o.Restricted, true +} + +// HasRestricted returns a boolean if a field has been set. +func (o *DashboardChartsWebUIFilter) HasRestricted() bool { + if o != nil && !IsNil(o.Restricted) { + return true + } + + return false +} + +// SetRestricted gets a reference to the given bool and assigns it to the Restricted field. +func (o *DashboardChartsWebUIFilter) SetRestricted(v bool) { + o.Restricted = &v +} + +// GetValue returns the Value field value +func (o *DashboardChartsWebUIFilter) GetValue() []string { + if o == nil { + var ret []string + return ret + } + + return o.Value +} + +// GetValueOk returns a tuple with the Value field value +// and a boolean to check if the value has been set. +func (o *DashboardChartsWebUIFilter) GetValueOk() ([]string, bool) { + if o == nil { + return nil, false + } + return o.Value, true +} + +// SetValue sets field value +func (o *DashboardChartsWebUIFilter) SetValue(v []string) { + o.Value = v +} + +func (o DashboardChartsWebUIFilter) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardChartsWebUIFilter) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Alias) { + toSerialize["alias"] = o.Alias + } + if !IsNil(o.PreferredSuggestions) { + toSerialize["preferredSuggestions"] = o.PreferredSuggestions + } + toSerialize["property"] = o.Property + if !IsNil(o.Required) { + toSerialize["required"] = o.Required + } + if !IsNil(o.Restricted) { + toSerialize["restricted"] = o.Restricted + } + toSerialize["value"] = o.Value + return toSerialize, nil +} + +func (o *DashboardChartsWebUIFilter) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "property", + "value", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDashboardChartsWebUIFilter := _DashboardChartsWebUIFilter{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varDashboardChartsWebUIFilter) + + if err != nil { + return err + } + + *o = DashboardChartsWebUIFilter(varDashboardChartsWebUIFilter) + + return err +} + +type NullableDashboardChartsWebUIFilter struct { + value *DashboardChartsWebUIFilter + isSet bool +} + +func (v NullableDashboardChartsWebUIFilter) Get() *DashboardChartsWebUIFilter { + return v.value +} + +func (v *NullableDashboardChartsWebUIFilter) Set(val *DashboardChartsWebUIFilter) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardChartsWebUIFilter) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardChartsWebUIFilter) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardChartsWebUIFilter(val *DashboardChartsWebUIFilter) *NullableDashboardChartsWebUIFilter { + return &NullableDashboardChartsWebUIFilter{value: val, isSet: true} +} + +func (v NullableDashboardChartsWebUIFilter) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardChartsWebUIFilter) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_event_overlay_filter.go b/navigator/model_dashboard_event_overlay_filter.go new file mode 100644 index 0000000..cef2609 --- /dev/null +++ b/navigator/model_dashboard_event_overlay_filter.go @@ -0,0 +1,241 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardEventOverlayFilter type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardEventOverlayFilter{} + +// DashboardEventOverlayFilter List of filters to apply to event overlays used in this dashboard +type DashboardEventOverlayFilter struct { + EventSignal *DashboardEventSignal `json:"eventSignal,omitempty"` + // Event marker color palette index + EventColorIndex *int32 `json:"eventColorIndex,omitempty"` + // Controls the display of vertical lines marking events + EventLine *bool `json:"eventLine,omitempty"` + // List of filters to apply to events for this overlay + Sources []DashboardEventSources `json:"sources,omitempty"` +} + +// NewDashboardEventOverlayFilter instantiates a new DashboardEventOverlayFilter object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardEventOverlayFilter() *DashboardEventOverlayFilter { + this := DashboardEventOverlayFilter{} + var eventLine bool = false + this.EventLine = &eventLine + return &this +} + +// NewDashboardEventOverlayFilterWithDefaults instantiates a new DashboardEventOverlayFilter object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardEventOverlayFilterWithDefaults() *DashboardEventOverlayFilter { + this := DashboardEventOverlayFilter{} + var eventLine bool = false + this.EventLine = &eventLine + return &this +} + +// GetEventSignal returns the EventSignal field value if set, zero value otherwise. +func (o *DashboardEventOverlayFilter) GetEventSignal() DashboardEventSignal { + if o == nil || IsNil(o.EventSignal) { + var ret DashboardEventSignal + return ret + } + return *o.EventSignal +} + +// GetEventSignalOk returns a tuple with the EventSignal field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventOverlayFilter) GetEventSignalOk() (*DashboardEventSignal, bool) { + if o == nil || IsNil(o.EventSignal) { + return nil, false + } + return o.EventSignal, true +} + +// HasEventSignal returns a boolean if a field has been set. +func (o *DashboardEventOverlayFilter) HasEventSignal() bool { + if o != nil && !IsNil(o.EventSignal) { + return true + } + + return false +} + +// SetEventSignal gets a reference to the given DashboardEventSignal and assigns it to the EventSignal field. +func (o *DashboardEventOverlayFilter) SetEventSignal(v DashboardEventSignal) { + o.EventSignal = &v +} + +// GetEventColorIndex returns the EventColorIndex field value if set, zero value otherwise. +func (o *DashboardEventOverlayFilter) GetEventColorIndex() int32 { + if o == nil || IsNil(o.EventColorIndex) { + var ret int32 + return ret + } + return *o.EventColorIndex +} + +// GetEventColorIndexOk returns a tuple with the EventColorIndex field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventOverlayFilter) GetEventColorIndexOk() (*int32, bool) { + if o == nil || IsNil(o.EventColorIndex) { + return nil, false + } + return o.EventColorIndex, true +} + +// HasEventColorIndex returns a boolean if a field has been set. +func (o *DashboardEventOverlayFilter) HasEventColorIndex() bool { + if o != nil && !IsNil(o.EventColorIndex) { + return true + } + + return false +} + +// SetEventColorIndex gets a reference to the given int32 and assigns it to the EventColorIndex field. +func (o *DashboardEventOverlayFilter) SetEventColorIndex(v int32) { + o.EventColorIndex = &v +} + +// GetEventLine returns the EventLine field value if set, zero value otherwise. +func (o *DashboardEventOverlayFilter) GetEventLine() bool { + if o == nil || IsNil(o.EventLine) { + var ret bool + return ret + } + return *o.EventLine +} + +// GetEventLineOk returns a tuple with the EventLine field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventOverlayFilter) GetEventLineOk() (*bool, bool) { + if o == nil || IsNil(o.EventLine) { + return nil, false + } + return o.EventLine, true +} + +// HasEventLine returns a boolean if a field has been set. +func (o *DashboardEventOverlayFilter) HasEventLine() bool { + if o != nil && !IsNil(o.EventLine) { + return true + } + + return false +} + +// SetEventLine gets a reference to the given bool and assigns it to the EventLine field. +func (o *DashboardEventOverlayFilter) SetEventLine(v bool) { + o.EventLine = &v +} + +// GetSources returns the Sources field value if set, zero value otherwise. +func (o *DashboardEventOverlayFilter) GetSources() []DashboardEventSources { + if o == nil || IsNil(o.Sources) { + var ret []DashboardEventSources + return ret + } + return o.Sources +} + +// GetSourcesOk returns a tuple with the Sources field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventOverlayFilter) GetSourcesOk() ([]DashboardEventSources, bool) { + if o == nil || IsNil(o.Sources) { + return nil, false + } + return o.Sources, true +} + +// HasSources returns a boolean if a field has been set. +func (o *DashboardEventOverlayFilter) HasSources() bool { + if o != nil && !IsNil(o.Sources) { + return true + } + + return false +} + +// SetSources gets a reference to the given []DashboardEventSources and assigns it to the Sources field. +func (o *DashboardEventOverlayFilter) SetSources(v []DashboardEventSources) { + o.Sources = v +} + +func (o DashboardEventOverlayFilter) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardEventOverlayFilter) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.EventSignal) { + toSerialize["eventSignal"] = o.EventSignal + } + if !IsNil(o.EventColorIndex) { + toSerialize["eventColorIndex"] = o.EventColorIndex + } + if !IsNil(o.EventLine) { + toSerialize["eventLine"] = o.EventLine + } + if !IsNil(o.Sources) { + toSerialize["sources"] = o.Sources + } + return toSerialize, nil +} + +type NullableDashboardEventOverlayFilter struct { + value *DashboardEventOverlayFilter + isSet bool +} + +func (v NullableDashboardEventOverlayFilter) Get() *DashboardEventOverlayFilter { + return v.value +} + +func (v *NullableDashboardEventOverlayFilter) Set(val *DashboardEventOverlayFilter) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardEventOverlayFilter) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardEventOverlayFilter) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardEventOverlayFilter(val *DashboardEventOverlayFilter) *NullableDashboardEventOverlayFilter { + return &NullableDashboardEventOverlayFilter{value: val, isSet: true} +} + +func (v NullableDashboardEventOverlayFilter) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardEventOverlayFilter) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_event_signal.go b/navigator/model_dashboard_event_signal.go new file mode 100644 index 0000000..a8b874f --- /dev/null +++ b/navigator/model_dashboard_event_signal.go @@ -0,0 +1,196 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the DashboardEventSignal type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardEventSignal{} + +// DashboardEventSignal Filter that selects the charts to overlay with events +type DashboardEventSignal struct { + // Event name query that Splunk Observability Cloud uses to suggest event overlays + EventSearchText string `json:"eventSearchText"` + // Specifies the event source + EventType *string `json:"eventType,omitempty"` +} + +type _DashboardEventSignal DashboardEventSignal + +// NewDashboardEventSignal instantiates a new DashboardEventSignal object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardEventSignal(eventSearchText string) *DashboardEventSignal { + this := DashboardEventSignal{} + this.EventSearchText = eventSearchText + return &this +} + +// NewDashboardEventSignalWithDefaults instantiates a new DashboardEventSignal object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardEventSignalWithDefaults() *DashboardEventSignal { + this := DashboardEventSignal{} + return &this +} + +// GetEventSearchText returns the EventSearchText field value +func (o *DashboardEventSignal) GetEventSearchText() string { + if o == nil { + var ret string + return ret + } + + return o.EventSearchText +} + +// GetEventSearchTextOk returns a tuple with the EventSearchText field value +// and a boolean to check if the value has been set. +func (o *DashboardEventSignal) GetEventSearchTextOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.EventSearchText, true +} + +// SetEventSearchText sets field value +func (o *DashboardEventSignal) SetEventSearchText(v string) { + o.EventSearchText = v +} + +// GetEventType returns the EventType field value if set, zero value otherwise. +func (o *DashboardEventSignal) GetEventType() string { + if o == nil || IsNil(o.EventType) { + var ret string + return ret + } + return *o.EventType +} + +// GetEventTypeOk returns a tuple with the EventType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventSignal) GetEventTypeOk() (*string, bool) { + if o == nil || IsNil(o.EventType) { + return nil, false + } + return o.EventType, true +} + +// HasEventType returns a boolean if a field has been set. +func (o *DashboardEventSignal) HasEventType() bool { + if o != nil && !IsNil(o.EventType) { + return true + } + + return false +} + +// SetEventType gets a reference to the given string and assigns it to the EventType field. +func (o *DashboardEventSignal) SetEventType(v string) { + o.EventType = &v +} + +func (o DashboardEventSignal) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardEventSignal) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["eventSearchText"] = o.EventSearchText + if !IsNil(o.EventType) { + toSerialize["eventType"] = o.EventType + } + return toSerialize, nil +} + +func (o *DashboardEventSignal) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "eventSearchText", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varDashboardEventSignal := _DashboardEventSignal{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varDashboardEventSignal) + + if err != nil { + return err + } + + *o = DashboardEventSignal(varDashboardEventSignal) + + return err +} + +type NullableDashboardEventSignal struct { + value *DashboardEventSignal + isSet bool +} + +func (v NullableDashboardEventSignal) Get() *DashboardEventSignal { + return v.value +} + +func (v *NullableDashboardEventSignal) Set(val *DashboardEventSignal) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardEventSignal) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardEventSignal) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardEventSignal(val *DashboardEventSignal) *NullableDashboardEventSignal { + return &NullableDashboardEventSignal{value: val, isSet: true} +} + +func (v NullableDashboardEventSignal) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardEventSignal) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_event_sources.go b/navigator/model_dashboard_event_sources.go new file mode 100644 index 0000000..a5677af --- /dev/null +++ b/navigator/model_dashboard_event_sources.go @@ -0,0 +1,205 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardEventSources type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardEventSources{} + +// DashboardEventSources struct for DashboardEventSources +type DashboardEventSources struct { + // Inverts the filter comparison + NOT *bool `json:"NOT,omitempty"` + // Custom property or dimension for which you want to test the value + Property *string `json:"property,omitempty"` + // List of values to test against the property or dimension + Value []string `json:"value,omitempty"` +} + +// NewDashboardEventSources instantiates a new DashboardEventSources object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardEventSources() *DashboardEventSources { + this := DashboardEventSources{} + var nOT bool = false + this.NOT = &nOT + return &this +} + +// NewDashboardEventSourcesWithDefaults instantiates a new DashboardEventSources object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardEventSourcesWithDefaults() *DashboardEventSources { + this := DashboardEventSources{} + var nOT bool = false + this.NOT = &nOT + return &this +} + +// GetNOT returns the NOT field value if set, zero value otherwise. +func (o *DashboardEventSources) GetNOT() bool { + if o == nil || IsNil(o.NOT) { + var ret bool + return ret + } + return *o.NOT +} + +// GetNOTOk returns a tuple with the NOT field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventSources) GetNOTOk() (*bool, bool) { + if o == nil || IsNil(o.NOT) { + return nil, false + } + return o.NOT, true +} + +// HasNOT returns a boolean if a field has been set. +func (o *DashboardEventSources) HasNOT() bool { + if o != nil && !IsNil(o.NOT) { + return true + } + + return false +} + +// SetNOT gets a reference to the given bool and assigns it to the NOT field. +func (o *DashboardEventSources) SetNOT(v bool) { + o.NOT = &v +} + +// GetProperty returns the Property field value if set, zero value otherwise. +func (o *DashboardEventSources) GetProperty() string { + if o == nil || IsNil(o.Property) { + var ret string + return ret + } + return *o.Property +} + +// GetPropertyOk returns a tuple with the Property field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventSources) GetPropertyOk() (*string, bool) { + if o == nil || IsNil(o.Property) { + return nil, false + } + return o.Property, true +} + +// HasProperty returns a boolean if a field has been set. +func (o *DashboardEventSources) HasProperty() bool { + if o != nil && !IsNil(o.Property) { + return true + } + + return false +} + +// SetProperty gets a reference to the given string and assigns it to the Property field. +func (o *DashboardEventSources) SetProperty(v string) { + o.Property = &v +} + +// GetValue returns the Value field value if set, zero value otherwise. +func (o *DashboardEventSources) GetValue() []string { + if o == nil || IsNil(o.Value) { + var ret []string + return ret + } + return o.Value +} + +// GetValueOk returns a tuple with the Value field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardEventSources) GetValueOk() ([]string, bool) { + if o == nil || IsNil(o.Value) { + return nil, false + } + return o.Value, true +} + +// HasValue returns a boolean if a field has been set. +func (o *DashboardEventSources) HasValue() bool { + if o != nil && !IsNil(o.Value) { + return true + } + + return false +} + +// SetValue gets a reference to the given []string and assigns it to the Value field. +func (o *DashboardEventSources) SetValue(v []string) { + o.Value = v +} + +func (o DashboardEventSources) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardEventSources) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.NOT) { + toSerialize["NOT"] = o.NOT + } + if !IsNil(o.Property) { + toSerialize["property"] = o.Property + } + if !IsNil(o.Value) { + toSerialize["value"] = o.Value + } + return toSerialize, nil +} + +type NullableDashboardEventSources struct { + value *DashboardEventSources + isSet bool +} + +func (v NullableDashboardEventSources) Get() *DashboardEventSources { + return v.value +} + +func (v *NullableDashboardEventSources) Set(val *DashboardEventSources) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardEventSources) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardEventSources) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardEventSources(val *DashboardEventSources) *NullableDashboardEventSources { + return &NullableDashboardEventSources{value: val, isSet: true} +} + +func (v NullableDashboardEventSources) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardEventSources) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_dashboard_permissions.go b/navigator/model_dashboard_permissions.go new file mode 100644 index 0000000..3ce60ea --- /dev/null +++ b/navigator/model_dashboard_permissions.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DashboardPermissions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DashboardPermissions{} + +// DashboardPermissions Read and write permission configuration for dashboards +type DashboardPermissions struct { + // List of permission configurations + Acl []DashboardACL `json:"acl,omitempty"` + // ID of the dashboard group to inherit permissions from + Parent *string `json:"parent,omitempty"` +} + +// NewDashboardPermissions instantiates a new DashboardPermissions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDashboardPermissions() *DashboardPermissions { + this := DashboardPermissions{} + return &this +} + +// NewDashboardPermissionsWithDefaults instantiates a new DashboardPermissions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDashboardPermissionsWithDefaults() *DashboardPermissions { + this := DashboardPermissions{} + return &this +} + +// GetAcl returns the Acl field value if set, zero value otherwise. +func (o *DashboardPermissions) GetAcl() []DashboardACL { + if o == nil || IsNil(o.Acl) { + var ret []DashboardACL + return ret + } + return o.Acl +} + +// GetAclOk returns a tuple with the Acl field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardPermissions) GetAclOk() ([]DashboardACL, bool) { + if o == nil || IsNil(o.Acl) { + return nil, false + } + return o.Acl, true +} + +// HasAcl returns a boolean if a field has been set. +func (o *DashboardPermissions) HasAcl() bool { + if o != nil && !IsNil(o.Acl) { + return true + } + + return false +} + +// SetAcl gets a reference to the given []DashboardACL and assigns it to the Acl field. +func (o *DashboardPermissions) SetAcl(v []DashboardACL) { + o.Acl = v +} + +// GetParent returns the Parent field value if set, zero value otherwise. +func (o *DashboardPermissions) GetParent() string { + if o == nil || IsNil(o.Parent) { + var ret string + return ret + } + return *o.Parent +} + +// GetParentOk returns a tuple with the Parent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DashboardPermissions) GetParentOk() (*string, bool) { + if o == nil || IsNil(o.Parent) { + return nil, false + } + return o.Parent, true +} + +// HasParent returns a boolean if a field has been set. +func (o *DashboardPermissions) HasParent() bool { + if o != nil && !IsNil(o.Parent) { + return true + } + + return false +} + +// SetParent gets a reference to the given string and assigns it to the Parent field. +func (o *DashboardPermissions) SetParent(v string) { + o.Parent = &v +} + +func (o DashboardPermissions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DashboardPermissions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Acl) { + toSerialize["acl"] = o.Acl + } + if !IsNil(o.Parent) { + toSerialize["parent"] = o.Parent + } + return toSerialize, nil +} + +type NullableDashboardPermissions struct { + value *DashboardPermissions + isSet bool +} + +func (v NullableDashboardPermissions) Get() *DashboardPermissions { + return v.value +} + +func (v *NullableDashboardPermissions) Set(val *DashboardPermissions) { + v.value = val + v.isSet = true +} + +func (v NullableDashboardPermissions) IsSet() bool { + return v.isSet +} + +func (v *NullableDashboardPermissions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDashboardPermissions(val *DashboardPermissions) *NullableDashboardPermissions { + return &NullableDashboardPermissions{value: val, isSet: true} +} + +func (v NullableDashboardPermissions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDashboardPermissions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_delete_single_navigator_403_response.go b/navigator/model_delete_single_navigator_403_response.go new file mode 100644 index 0000000..bec3206 --- /dev/null +++ b/navigator/model_delete_single_navigator_403_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DeleteSingleNavigator403Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DeleteSingleNavigator403Response{} + +// DeleteSingleNavigator403Response struct for DeleteSingleNavigator403Response +type DeleteSingleNavigator403Response struct { + // HTTP response code + Code *int32 `json:"code,omitempty"` + // Error explanation + Message *string `json:"message,omitempty"` +} + +// NewDeleteSingleNavigator403Response instantiates a new DeleteSingleNavigator403Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDeleteSingleNavigator403Response() *DeleteSingleNavigator403Response { + this := DeleteSingleNavigator403Response{} + return &this +} + +// NewDeleteSingleNavigator403ResponseWithDefaults instantiates a new DeleteSingleNavigator403Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDeleteSingleNavigator403ResponseWithDefaults() *DeleteSingleNavigator403Response { + this := DeleteSingleNavigator403Response{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *DeleteSingleNavigator403Response) GetCode() int32 { + if o == nil || IsNil(o.Code) { + var ret int32 + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSingleNavigator403Response) GetCodeOk() (*int32, bool) { + if o == nil || IsNil(o.Code) { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *DeleteSingleNavigator403Response) HasCode() bool { + if o != nil && !IsNil(o.Code) { + return true + } + + return false +} + +// SetCode gets a reference to the given int32 and assigns it to the Code field. +func (o *DeleteSingleNavigator403Response) SetCode(v int32) { + o.Code = &v +} + +// GetMessage returns the Message field value if set, zero value otherwise. +func (o *DeleteSingleNavigator403Response) GetMessage() string { + if o == nil || IsNil(o.Message) { + var ret string + return ret + } + return *o.Message +} + +// GetMessageOk returns a tuple with the Message field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DeleteSingleNavigator403Response) GetMessageOk() (*string, bool) { + if o == nil || IsNil(o.Message) { + return nil, false + } + return o.Message, true +} + +// HasMessage returns a boolean if a field has been set. +func (o *DeleteSingleNavigator403Response) HasMessage() bool { + if o != nil && !IsNil(o.Message) { + return true + } + + return false +} + +// SetMessage gets a reference to the given string and assigns it to the Message field. +func (o *DeleteSingleNavigator403Response) SetMessage(v string) { + o.Message = &v +} + +func (o DeleteSingleNavigator403Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DeleteSingleNavigator403Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Code) { + toSerialize["code"] = o.Code + } + if !IsNil(o.Message) { + toSerialize["message"] = o.Message + } + return toSerialize, nil +} + +type NullableDeleteSingleNavigator403Response struct { + value *DeleteSingleNavigator403Response + isSet bool +} + +func (v NullableDeleteSingleNavigator403Response) Get() *DeleteSingleNavigator403Response { + return v.value +} + +func (v *NullableDeleteSingleNavigator403Response) Set(val *DeleteSingleNavigator403Response) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteSingleNavigator403Response) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteSingleNavigator403Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteSingleNavigator403Response(val *DeleteSingleNavigator403Response) *NullableDeleteSingleNavigator403Response { + return &NullableDeleteSingleNavigator403Response{value: val, isSet: true} +} + +func (v NullableDeleteSingleNavigator403Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteSingleNavigator403Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_display_options_for_the_chart_legend.go b/navigator/model_display_options_for_the_chart_legend.go new file mode 100644 index 0000000..08fb91b --- /dev/null +++ b/navigator/model_display_options_for_the_chart_legend.go @@ -0,0 +1,168 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the DisplayOptionsForTheChartLegend type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DisplayOptionsForTheChartLegend{} + +// DisplayOptionsForTheChartLegend Controls the display of a legend and the dimensions to show in it +type DisplayOptionsForTheChartLegend struct { + // The dimension to show in the legend + DimensionInLegend *string `json:"dimensionInLegend,omitempty"` + // Controls the display of a chart legend + ShowLegend *bool `json:"showLegend,omitempty"` +} + +// NewDisplayOptionsForTheChartLegend instantiates a new DisplayOptionsForTheChartLegend object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewDisplayOptionsForTheChartLegend() *DisplayOptionsForTheChartLegend { + this := DisplayOptionsForTheChartLegend{} + var showLegend bool = false + this.ShowLegend = &showLegend + return &this +} + +// NewDisplayOptionsForTheChartLegendWithDefaults instantiates a new DisplayOptionsForTheChartLegend object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewDisplayOptionsForTheChartLegendWithDefaults() *DisplayOptionsForTheChartLegend { + this := DisplayOptionsForTheChartLegend{} + var showLegend bool = false + this.ShowLegend = &showLegend + return &this +} + +// GetDimensionInLegend returns the DimensionInLegend field value if set, zero value otherwise. +func (o *DisplayOptionsForTheChartLegend) GetDimensionInLegend() string { + if o == nil || IsNil(o.DimensionInLegend) { + var ret string + return ret + } + return *o.DimensionInLegend +} + +// GetDimensionInLegendOk returns a tuple with the DimensionInLegend field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DisplayOptionsForTheChartLegend) GetDimensionInLegendOk() (*string, bool) { + if o == nil || IsNil(o.DimensionInLegend) { + return nil, false + } + return o.DimensionInLegend, true +} + +// HasDimensionInLegend returns a boolean if a field has been set. +func (o *DisplayOptionsForTheChartLegend) HasDimensionInLegend() bool { + if o != nil && !IsNil(o.DimensionInLegend) { + return true + } + + return false +} + +// SetDimensionInLegend gets a reference to the given string and assigns it to the DimensionInLegend field. +func (o *DisplayOptionsForTheChartLegend) SetDimensionInLegend(v string) { + o.DimensionInLegend = &v +} + +// GetShowLegend returns the ShowLegend field value if set, zero value otherwise. +func (o *DisplayOptionsForTheChartLegend) GetShowLegend() bool { + if o == nil || IsNil(o.ShowLegend) { + var ret bool + return ret + } + return *o.ShowLegend +} + +// GetShowLegendOk returns a tuple with the ShowLegend field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *DisplayOptionsForTheChartLegend) GetShowLegendOk() (*bool, bool) { + if o == nil || IsNil(o.ShowLegend) { + return nil, false + } + return o.ShowLegend, true +} + +// HasShowLegend returns a boolean if a field has been set. +func (o *DisplayOptionsForTheChartLegend) HasShowLegend() bool { + if o != nil && !IsNil(o.ShowLegend) { + return true + } + + return false +} + +// SetShowLegend gets a reference to the given bool and assigns it to the ShowLegend field. +func (o *DisplayOptionsForTheChartLegend) SetShowLegend(v bool) { + o.ShowLegend = &v +} + +func (o DisplayOptionsForTheChartLegend) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o DisplayOptionsForTheChartLegend) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.DimensionInLegend) { + toSerialize["dimensionInLegend"] = o.DimensionInLegend + } + if !IsNil(o.ShowLegend) { + toSerialize["showLegend"] = o.ShowLegend + } + return toSerialize, nil +} + +type NullableDisplayOptionsForTheChartLegend struct { + value *DisplayOptionsForTheChartLegend + isSet bool +} + +func (v NullableDisplayOptionsForTheChartLegend) Get() *DisplayOptionsForTheChartLegend { + return v.value +} + +func (v *NullableDisplayOptionsForTheChartLegend) Set(val *DisplayOptionsForTheChartLegend) { + v.value = val + v.isSet = true +} + +func (v NullableDisplayOptionsForTheChartLegend) IsSet() bool { + return v.isSet +} + +func (v *NullableDisplayOptionsForTheChartLegend) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDisplayOptionsForTheChartLegend(val *DisplayOptionsForTheChartLegend) *NullableDisplayOptionsForTheChartLegend { + return &NullableDisplayOptionsForTheChartLegend{value: val, isSet: true} +} + +func (v NullableDisplayOptionsForTheChartLegend) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDisplayOptionsForTheChartLegend) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_general_options_for_the_chart.go b/navigator/model_general_options_for_the_chart.go new file mode 100644 index 0000000..46c455f --- /dev/null +++ b/navigator/model_general_options_for_the_chart.go @@ -0,0 +1,205 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GeneralOptionsForTheChart type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GeneralOptionsForTheChart{} + +// GeneralOptionsForTheChart Set of options that control the appearance and operation of the chart +type GeneralOptionsForTheChart struct { + // Controls sampling display + DisableSampling *bool `json:"disableSampling,omitempty"` + // In milliseconds, the time to wait before ignoring future data points + MaxDelay *int32 `json:"maxDelay,omitempty"` + // Minimum computation resolution + MinimumResolution *int32 `json:"minimumResolution,omitempty"` +} + +// NewGeneralOptionsForTheChart instantiates a new GeneralOptionsForTheChart object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGeneralOptionsForTheChart() *GeneralOptionsForTheChart { + this := GeneralOptionsForTheChart{} + var disableSampling bool = false + this.DisableSampling = &disableSampling + return &this +} + +// NewGeneralOptionsForTheChartWithDefaults instantiates a new GeneralOptionsForTheChart object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGeneralOptionsForTheChartWithDefaults() *GeneralOptionsForTheChart { + this := GeneralOptionsForTheChart{} + var disableSampling bool = false + this.DisableSampling = &disableSampling + return &this +} + +// GetDisableSampling returns the DisableSampling field value if set, zero value otherwise. +func (o *GeneralOptionsForTheChart) GetDisableSampling() bool { + if o == nil || IsNil(o.DisableSampling) { + var ret bool + return ret + } + return *o.DisableSampling +} + +// GetDisableSamplingOk returns a tuple with the DisableSampling field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GeneralOptionsForTheChart) GetDisableSamplingOk() (*bool, bool) { + if o == nil || IsNil(o.DisableSampling) { + return nil, false + } + return o.DisableSampling, true +} + +// HasDisableSampling returns a boolean if a field has been set. +func (o *GeneralOptionsForTheChart) HasDisableSampling() bool { + if o != nil && !IsNil(o.DisableSampling) { + return true + } + + return false +} + +// SetDisableSampling gets a reference to the given bool and assigns it to the DisableSampling field. +func (o *GeneralOptionsForTheChart) SetDisableSampling(v bool) { + o.DisableSampling = &v +} + +// GetMaxDelay returns the MaxDelay field value if set, zero value otherwise. +func (o *GeneralOptionsForTheChart) GetMaxDelay() int32 { + if o == nil || IsNil(o.MaxDelay) { + var ret int32 + return ret + } + return *o.MaxDelay +} + +// GetMaxDelayOk returns a tuple with the MaxDelay field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GeneralOptionsForTheChart) GetMaxDelayOk() (*int32, bool) { + if o == nil || IsNil(o.MaxDelay) { + return nil, false + } + return o.MaxDelay, true +} + +// HasMaxDelay returns a boolean if a field has been set. +func (o *GeneralOptionsForTheChart) HasMaxDelay() bool { + if o != nil && !IsNil(o.MaxDelay) { + return true + } + + return false +} + +// SetMaxDelay gets a reference to the given int32 and assigns it to the MaxDelay field. +func (o *GeneralOptionsForTheChart) SetMaxDelay(v int32) { + o.MaxDelay = &v +} + +// GetMinimumResolution returns the MinimumResolution field value if set, zero value otherwise. +func (o *GeneralOptionsForTheChart) GetMinimumResolution() int32 { + if o == nil || IsNil(o.MinimumResolution) { + var ret int32 + return ret + } + return *o.MinimumResolution +} + +// GetMinimumResolutionOk returns a tuple with the MinimumResolution field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GeneralOptionsForTheChart) GetMinimumResolutionOk() (*int32, bool) { + if o == nil || IsNil(o.MinimumResolution) { + return nil, false + } + return o.MinimumResolution, true +} + +// HasMinimumResolution returns a boolean if a field has been set. +func (o *GeneralOptionsForTheChart) HasMinimumResolution() bool { + if o != nil && !IsNil(o.MinimumResolution) { + return true + } + + return false +} + +// SetMinimumResolution gets a reference to the given int32 and assigns it to the MinimumResolution field. +func (o *GeneralOptionsForTheChart) SetMinimumResolution(v int32) { + o.MinimumResolution = &v +} + +func (o GeneralOptionsForTheChart) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GeneralOptionsForTheChart) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.DisableSampling) { + toSerialize["disableSampling"] = o.DisableSampling + } + if !IsNil(o.MaxDelay) { + toSerialize["maxDelay"] = o.MaxDelay + } + if !IsNil(o.MinimumResolution) { + toSerialize["minimumResolution"] = o.MinimumResolution + } + return toSerialize, nil +} + +type NullableGeneralOptionsForTheChart struct { + value *GeneralOptionsForTheChart + isSet bool +} + +func (v NullableGeneralOptionsForTheChart) Get() *GeneralOptionsForTheChart { + return v.value +} + +func (v *NullableGeneralOptionsForTheChart) Set(val *GeneralOptionsForTheChart) { + v.value = val + v.isSet = true +} + +func (v NullableGeneralOptionsForTheChart) IsSet() bool { + return v.isSet +} + +func (v *NullableGeneralOptionsForTheChart) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGeneralOptionsForTheChart(val *GeneralOptionsForTheChart) *NullableGeneralOptionsForTheChart { + return &NullableGeneralOptionsForTheChart{value: val, isSet: true} +} + +func (v NullableGeneralOptionsForTheChart) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGeneralOptionsForTheChart) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigator_customizations_response.go b/navigator/model_get_navigator_customizations_response.go new file mode 100644 index 0000000..8bfcd34 --- /dev/null +++ b/navigator/model_get_navigator_customizations_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorCustomizationsResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorCustomizationsResponse{} + +// GetNavigatorCustomizationsResponse Retrieving navigator customizations by query endpoint response body +type GetNavigatorCustomizationsResponse struct { + // Number of matched navigators + Count *int32 `json:"count,omitempty"` + // List of navigators + Results []GetNavigatorCustomizationsResult `json:"results,omitempty"` +} + +// NewGetNavigatorCustomizationsResponse instantiates a new GetNavigatorCustomizationsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorCustomizationsResponse() *GetNavigatorCustomizationsResponse { + this := GetNavigatorCustomizationsResponse{} + return &this +} + +// NewGetNavigatorCustomizationsResponseWithDefaults instantiates a new GetNavigatorCustomizationsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorCustomizationsResponseWithDefaults() *GetNavigatorCustomizationsResponse { + this := GetNavigatorCustomizationsResponse{} + return &this +} + +// GetCount returns the Count field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResponse) GetCount() int32 { + if o == nil || IsNil(o.Count) { + var ret int32 + return ret + } + return *o.Count +} + +// GetCountOk returns a tuple with the Count field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResponse) GetCountOk() (*int32, bool) { + if o == nil || IsNil(o.Count) { + return nil, false + } + return o.Count, true +} + +// HasCount returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResponse) HasCount() bool { + if o != nil && !IsNil(o.Count) { + return true + } + + return false +} + +// SetCount gets a reference to the given int32 and assigns it to the Count field. +func (o *GetNavigatorCustomizationsResponse) SetCount(v int32) { + o.Count = &v +} + +// GetResults returns the Results field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResponse) GetResults() []GetNavigatorCustomizationsResult { + if o == nil || IsNil(o.Results) { + var ret []GetNavigatorCustomizationsResult + return ret + } + return o.Results +} + +// GetResultsOk returns a tuple with the Results field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResponse) GetResultsOk() ([]GetNavigatorCustomizationsResult, bool) { + if o == nil || IsNil(o.Results) { + return nil, false + } + return o.Results, true +} + +// HasResults returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResponse) HasResults() bool { + if o != nil && !IsNil(o.Results) { + return true + } + + return false +} + +// SetResults gets a reference to the given []GetNavigatorCustomizationsResult and assigns it to the Results field. +func (o *GetNavigatorCustomizationsResponse) SetResults(v []GetNavigatorCustomizationsResult) { + o.Results = v +} + +func (o GetNavigatorCustomizationsResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorCustomizationsResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Count) { + toSerialize["count"] = o.Count + } + if !IsNil(o.Results) { + toSerialize["results"] = o.Results + } + return toSerialize, nil +} + +type NullableGetNavigatorCustomizationsResponse struct { + value *GetNavigatorCustomizationsResponse + isSet bool +} + +func (v NullableGetNavigatorCustomizationsResponse) Get() *GetNavigatorCustomizationsResponse { + return v.value +} + +func (v *NullableGetNavigatorCustomizationsResponse) Set(val *GetNavigatorCustomizationsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorCustomizationsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorCustomizationsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorCustomizationsResponse(val *GetNavigatorCustomizationsResponse) *NullableGetNavigatorCustomizationsResponse { + return &NullableGetNavigatorCustomizationsResponse{value: val, isSet: true} +} + +func (v NullableGetNavigatorCustomizationsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorCustomizationsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigator_customizations_result.go b/navigator/model_get_navigator_customizations_result.go new file mode 100644 index 0000000..b3e1e53 --- /dev/null +++ b/navigator/model_get_navigator_customizations_result.go @@ -0,0 +1,423 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorCustomizationsResult type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorCustomizationsResult{} + +// GetNavigatorCustomizationsResult struct for GetNavigatorCustomizationsResult +type GetNavigatorCustomizationsResult struct { + // Navigator customization creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator customization + Creator *string `json:"creator,omitempty"` + // Time at which the navigator customization was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator customization + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // Navigator customization system ID + Id *string `json:"id,omitempty"` + // Navigator customization display name + Name *string `json:"name,omitempty"` + // Navigator system ID + NavigatorId *string `json:"navigatorId,omitempty"` + // Array of dashboard IDs to use for aggregate display. Specific to GET /navigator/{id}/navigatorcustomization. + AggregateDashboards []string `json:"aggregateDashboards,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator/{id}/navigatorcustomization. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` +} + +// NewGetNavigatorCustomizationsResult instantiates a new GetNavigatorCustomizationsResult object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorCustomizationsResult() *GetNavigatorCustomizationsResult { + this := GetNavigatorCustomizationsResult{} + return &this +} + +// NewGetNavigatorCustomizationsResultWithDefaults instantiates a new GetNavigatorCustomizationsResult object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorCustomizationsResultWithDefaults() *GetNavigatorCustomizationsResult { + this := GetNavigatorCustomizationsResult{} + return &this +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *GetNavigatorCustomizationsResult) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *GetNavigatorCustomizationsResult) SetCreator(v string) { + o.Creator = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *GetNavigatorCustomizationsResult) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *GetNavigatorCustomizationsResult) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *GetNavigatorCustomizationsResult) SetId(v string) { + o.Id = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *GetNavigatorCustomizationsResult) SetName(v string) { + o.Name = &v +} + +// GetNavigatorId returns the NavigatorId field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetNavigatorId() string { + if o == nil || IsNil(o.NavigatorId) { + var ret string + return ret + } + return *o.NavigatorId +} + +// GetNavigatorIdOk returns a tuple with the NavigatorId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetNavigatorIdOk() (*string, bool) { + if o == nil || IsNil(o.NavigatorId) { + return nil, false + } + return o.NavigatorId, true +} + +// HasNavigatorId returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasNavigatorId() bool { + if o != nil && !IsNil(o.NavigatorId) { + return true + } + + return false +} + +// SetNavigatorId gets a reference to the given string and assigns it to the NavigatorId field. +func (o *GetNavigatorCustomizationsResult) SetNavigatorId(v string) { + o.NavigatorId = &v +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetAggregateDashboards() []string { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []string + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetAggregateDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []string and assigns it to the AggregateDashboards field. +func (o *GetNavigatorCustomizationsResult) SetAggregateDashboards(v []string) { + o.AggregateDashboards = v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *GetNavigatorCustomizationsResult) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorCustomizationsResult) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *GetNavigatorCustomizationsResult) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *GetNavigatorCustomizationsResult) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +func (o GetNavigatorCustomizationsResult) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorCustomizationsResult) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.NavigatorId) { + toSerialize["navigatorId"] = o.NavigatorId + } + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + return toSerialize, nil +} + +type NullableGetNavigatorCustomizationsResult struct { + value *GetNavigatorCustomizationsResult + isSet bool +} + +func (v NullableGetNavigatorCustomizationsResult) Get() *GetNavigatorCustomizationsResult { + return v.value +} + +func (v *NullableGetNavigatorCustomizationsResult) Set(val *GetNavigatorCustomizationsResult) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorCustomizationsResult) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorCustomizationsResult) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorCustomizationsResult(val *GetNavigatorCustomizationsResult) *NullableGetNavigatorCustomizationsResult { + return &NullableGetNavigatorCustomizationsResult{value: val, isSet: true} +} + +func (v NullableGetNavigatorCustomizationsResult) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorCustomizationsResult) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigator_dashboards_response.go b/navigator/model_get_navigator_dashboards_response.go new file mode 100644 index 0000000..49220cc --- /dev/null +++ b/navigator/model_get_navigator_dashboards_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorDashboardsResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorDashboardsResponse{} + +// GetNavigatorDashboardsResponse Dashboards associated with a navigator +type GetNavigatorDashboardsResponse struct { + // Array of dashboard objects to use for aggregate display. Specific to GET /navigator/id/dashboards. + AggregateDashboards []AggregateDashboardsInner `json:"aggregateDashboards,omitempty"` + // List of instance dashboards associated with a navigator. Specific to GET /navigator/id/dashboards. + InstanceDashboards []AggregateDashboardsInner `json:"instanceDashboards,omitempty"` +} + +// NewGetNavigatorDashboardsResponse instantiates a new GetNavigatorDashboardsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorDashboardsResponse() *GetNavigatorDashboardsResponse { + this := GetNavigatorDashboardsResponse{} + return &this +} + +// NewGetNavigatorDashboardsResponseWithDefaults instantiates a new GetNavigatorDashboardsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorDashboardsResponseWithDefaults() *GetNavigatorDashboardsResponse { + this := GetNavigatorDashboardsResponse{} + return &this +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *GetNavigatorDashboardsResponse) GetAggregateDashboards() []AggregateDashboardsInner { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []AggregateDashboardsInner + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorDashboardsResponse) GetAggregateDashboardsOk() ([]AggregateDashboardsInner, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *GetNavigatorDashboardsResponse) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []AggregateDashboardsInner and assigns it to the AggregateDashboards field. +func (o *GetNavigatorDashboardsResponse) SetAggregateDashboards(v []AggregateDashboardsInner) { + o.AggregateDashboards = v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *GetNavigatorDashboardsResponse) GetInstanceDashboards() []AggregateDashboardsInner { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []AggregateDashboardsInner + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorDashboardsResponse) GetInstanceDashboardsOk() ([]AggregateDashboardsInner, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *GetNavigatorDashboardsResponse) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []AggregateDashboardsInner and assigns it to the InstanceDashboards field. +func (o *GetNavigatorDashboardsResponse) SetInstanceDashboards(v []AggregateDashboardsInner) { + o.InstanceDashboards = v +} + +func (o GetNavigatorDashboardsResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorDashboardsResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + return toSerialize, nil +} + +type NullableGetNavigatorDashboardsResponse struct { + value *GetNavigatorDashboardsResponse + isSet bool +} + +func (v NullableGetNavigatorDashboardsResponse) Get() *GetNavigatorDashboardsResponse { + return v.value +} + +func (v *NullableGetNavigatorDashboardsResponse) Set(val *GetNavigatorDashboardsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorDashboardsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorDashboardsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorDashboardsResponse(val *GetNavigatorDashboardsResponse) *NullableGetNavigatorDashboardsResponse { + return &NullableGetNavigatorDashboardsResponse{value: val, isSet: true} +} + +func (v NullableGetNavigatorDashboardsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorDashboardsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigator_response.go b/navigator/model_get_navigator_response.go new file mode 100644 index 0000000..e2709d6 --- /dev/null +++ b/navigator/model_get_navigator_response.go @@ -0,0 +1,940 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorResponse{} + +// GetNavigatorResponse Properties of an individual navigator +type GetNavigatorResponse struct { + // Array of dashboard IDs to use for aggregate display. Specific to GET /navigator. + AggregateDashboards []string `json:"aggregateDashboards,omitempty"` + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator + Creator *string `json:"creator,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // Time at which the navigator was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + // Navigator unique code + NavigatorCode *string `json:"navigatorCode,omitempty"` + OwnerScope *OwnerScope `json:"ownerScope,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewGetNavigatorResponse instantiates a new GetNavigatorResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorResponse() *GetNavigatorResponse { + this := GetNavigatorResponse{} + return &this +} + +// NewGetNavigatorResponseWithDefaults instantiates a new GetNavigatorResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorResponseWithDefaults() *GetNavigatorResponse { + this := GetNavigatorResponse{} + return &this +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetAggregateDashboards() []string { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []string + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetAggregateDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []string and assigns it to the AggregateDashboards field. +func (o *GetNavigatorResponse) SetAggregateDashboards(v []string) { + o.AggregateDashboards = v +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *GetNavigatorResponse) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *GetNavigatorResponse) SetCategories(v []Category) { + o.Categories = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *GetNavigatorResponse) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *GetNavigatorResponse) SetCreator(v string) { + o.Creator = &v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *GetNavigatorResponse) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *GetNavigatorResponse) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *GetNavigatorResponse) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *GetNavigatorResponse) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *GetNavigatorResponse) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *GetNavigatorResponse) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *GetNavigatorResponse) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *GetNavigatorResponse) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *GetNavigatorResponse) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *GetNavigatorResponse) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetNavigatorCode returns the NavigatorCode field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetNavigatorCode() string { + if o == nil || IsNil(o.NavigatorCode) { + var ret string + return ret + } + return *o.NavigatorCode +} + +// GetNavigatorCodeOk returns a tuple with the NavigatorCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetNavigatorCodeOk() (*string, bool) { + if o == nil || IsNil(o.NavigatorCode) { + return nil, false + } + return o.NavigatorCode, true +} + +// HasNavigatorCode returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasNavigatorCode() bool { + if o != nil && !IsNil(o.NavigatorCode) { + return true + } + + return false +} + +// SetNavigatorCode gets a reference to the given string and assigns it to the NavigatorCode field. +func (o *GetNavigatorResponse) SetNavigatorCode(v string) { + o.NavigatorCode = &v +} + +// GetOwnerScope returns the OwnerScope field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetOwnerScope() OwnerScope { + if o == nil || IsNil(o.OwnerScope) { + var ret OwnerScope + return ret + } + return *o.OwnerScope +} + +// GetOwnerScopeOk returns a tuple with the OwnerScope field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetOwnerScopeOk() (*OwnerScope, bool) { + if o == nil || IsNil(o.OwnerScope) { + return nil, false + } + return o.OwnerScope, true +} + +// HasOwnerScope returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasOwnerScope() bool { + if o != nil && !IsNil(o.OwnerScope) { + return true + } + + return false +} + +// SetOwnerScope gets a reference to the given OwnerScope and assigns it to the OwnerScope field. +func (o *GetNavigatorResponse) SetOwnerScope(v OwnerScope) { + o.OwnerScope = &v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *GetNavigatorResponse) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *GetNavigatorResponse) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *GetNavigatorResponse) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *GetNavigatorResponse) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *GetNavigatorResponse) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *GetNavigatorResponse) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorResponse) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *GetNavigatorResponse) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *GetNavigatorResponse) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o GetNavigatorResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.NavigatorCode) { + toSerialize["navigatorCode"] = o.NavigatorCode + } + if !IsNil(o.OwnerScope) { + toSerialize["ownerScope"] = o.OwnerScope + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableGetNavigatorResponse struct { + value *GetNavigatorResponse + isSet bool +} + +func (v NullableGetNavigatorResponse) Get() *GetNavigatorResponse { + return v.value +} + +func (v *NullableGetNavigatorResponse) Set(val *GetNavigatorResponse) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorResponse(val *GetNavigatorResponse) *NullableGetNavigatorResponse { + return &NullableGetNavigatorResponse{value: val, isSet: true} +} + +func (v NullableGetNavigatorResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigators_response.go b/navigator/model_get_navigators_response.go new file mode 100644 index 0000000..5ffef71 --- /dev/null +++ b/navigator/model_get_navigators_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorsResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorsResponse{} + +// GetNavigatorsResponse Retrieving navigators by query endpoint response body +type GetNavigatorsResponse struct { + // Number of matched navigators + Count *int32 `json:"count,omitempty"` + // List of navigators + Results []GetNavigatorsResult `json:"results,omitempty"` +} + +// NewGetNavigatorsResponse instantiates a new GetNavigatorsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorsResponse() *GetNavigatorsResponse { + this := GetNavigatorsResponse{} + return &this +} + +// NewGetNavigatorsResponseWithDefaults instantiates a new GetNavigatorsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorsResponseWithDefaults() *GetNavigatorsResponse { + this := GetNavigatorsResponse{} + return &this +} + +// GetCount returns the Count field value if set, zero value otherwise. +func (o *GetNavigatorsResponse) GetCount() int32 { + if o == nil || IsNil(o.Count) { + var ret int32 + return ret + } + return *o.Count +} + +// GetCountOk returns a tuple with the Count field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResponse) GetCountOk() (*int32, bool) { + if o == nil || IsNil(o.Count) { + return nil, false + } + return o.Count, true +} + +// HasCount returns a boolean if a field has been set. +func (o *GetNavigatorsResponse) HasCount() bool { + if o != nil && !IsNil(o.Count) { + return true + } + + return false +} + +// SetCount gets a reference to the given int32 and assigns it to the Count field. +func (o *GetNavigatorsResponse) SetCount(v int32) { + o.Count = &v +} + +// GetResults returns the Results field value if set, zero value otherwise. +func (o *GetNavigatorsResponse) GetResults() []GetNavigatorsResult { + if o == nil || IsNil(o.Results) { + var ret []GetNavigatorsResult + return ret + } + return o.Results +} + +// GetResultsOk returns a tuple with the Results field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResponse) GetResultsOk() ([]GetNavigatorsResult, bool) { + if o == nil || IsNil(o.Results) { + return nil, false + } + return o.Results, true +} + +// HasResults returns a boolean if a field has been set. +func (o *GetNavigatorsResponse) HasResults() bool { + if o != nil && !IsNil(o.Results) { + return true + } + + return false +} + +// SetResults gets a reference to the given []GetNavigatorsResult and assigns it to the Results field. +func (o *GetNavigatorsResponse) SetResults(v []GetNavigatorsResult) { + o.Results = v +} + +func (o GetNavigatorsResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorsResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Count) { + toSerialize["count"] = o.Count + } + if !IsNil(o.Results) { + toSerialize["results"] = o.Results + } + return toSerialize, nil +} + +type NullableGetNavigatorsResponse struct { + value *GetNavigatorsResponse + isSet bool +} + +func (v NullableGetNavigatorsResponse) Get() *GetNavigatorsResponse { + return v.value +} + +func (v *NullableGetNavigatorsResponse) Set(val *GetNavigatorsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorsResponse(val *GetNavigatorsResponse) *NullableGetNavigatorsResponse { + return &NullableGetNavigatorsResponse{value: val, isSet: true} +} + +func (v NullableGetNavigatorsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_get_navigators_result.go b/navigator/model_get_navigators_result.go new file mode 100644 index 0000000..0581aac --- /dev/null +++ b/navigator/model_get_navigators_result.go @@ -0,0 +1,940 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the GetNavigatorsResult type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetNavigatorsResult{} + +// GetNavigatorsResult struct for GetNavigatorsResult +type GetNavigatorsResult struct { + // Array of dashboard IDs to use for aggregate display. Specific to GET /navigator. + AggregateDashboards []string `json:"aggregateDashboards,omitempty"` + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator + Creator *string `json:"creator,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // Time at which the navigator was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + // Navigator unique code + NavigatorCode *string `json:"navigatorCode,omitempty"` + OwnerScope *OwnerScope `json:"ownerScope,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewGetNavigatorsResult instantiates a new GetNavigatorsResult object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewGetNavigatorsResult() *GetNavigatorsResult { + this := GetNavigatorsResult{} + return &this +} + +// NewGetNavigatorsResultWithDefaults instantiates a new GetNavigatorsResult object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewGetNavigatorsResultWithDefaults() *GetNavigatorsResult { + this := GetNavigatorsResult{} + return &this +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetAggregateDashboards() []string { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []string + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetAggregateDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []string and assigns it to the AggregateDashboards field. +func (o *GetNavigatorsResult) SetAggregateDashboards(v []string) { + o.AggregateDashboards = v +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *GetNavigatorsResult) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *GetNavigatorsResult) SetCategories(v []Category) { + o.Categories = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *GetNavigatorsResult) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *GetNavigatorsResult) SetCreator(v string) { + o.Creator = &v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *GetNavigatorsResult) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *GetNavigatorsResult) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *GetNavigatorsResult) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *GetNavigatorsResult) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *GetNavigatorsResult) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *GetNavigatorsResult) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *GetNavigatorsResult) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *GetNavigatorsResult) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *GetNavigatorsResult) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *GetNavigatorsResult) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetNavigatorCode returns the NavigatorCode field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetNavigatorCode() string { + if o == nil || IsNil(o.NavigatorCode) { + var ret string + return ret + } + return *o.NavigatorCode +} + +// GetNavigatorCodeOk returns a tuple with the NavigatorCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetNavigatorCodeOk() (*string, bool) { + if o == nil || IsNil(o.NavigatorCode) { + return nil, false + } + return o.NavigatorCode, true +} + +// HasNavigatorCode returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasNavigatorCode() bool { + if o != nil && !IsNil(o.NavigatorCode) { + return true + } + + return false +} + +// SetNavigatorCode gets a reference to the given string and assigns it to the NavigatorCode field. +func (o *GetNavigatorsResult) SetNavigatorCode(v string) { + o.NavigatorCode = &v +} + +// GetOwnerScope returns the OwnerScope field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetOwnerScope() OwnerScope { + if o == nil || IsNil(o.OwnerScope) { + var ret OwnerScope + return ret + } + return *o.OwnerScope +} + +// GetOwnerScopeOk returns a tuple with the OwnerScope field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetOwnerScopeOk() (*OwnerScope, bool) { + if o == nil || IsNil(o.OwnerScope) { + return nil, false + } + return o.OwnerScope, true +} + +// HasOwnerScope returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasOwnerScope() bool { + if o != nil && !IsNil(o.OwnerScope) { + return true + } + + return false +} + +// SetOwnerScope gets a reference to the given OwnerScope and assigns it to the OwnerScope field. +func (o *GetNavigatorsResult) SetOwnerScope(v OwnerScope) { + o.OwnerScope = &v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *GetNavigatorsResult) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *GetNavigatorsResult) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *GetNavigatorsResult) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *GetNavigatorsResult) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *GetNavigatorsResult) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *GetNavigatorsResult) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *GetNavigatorsResult) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *GetNavigatorsResult) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *GetNavigatorsResult) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o GetNavigatorsResult) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o GetNavigatorsResult) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.NavigatorCode) { + toSerialize["navigatorCode"] = o.NavigatorCode + } + if !IsNil(o.OwnerScope) { + toSerialize["ownerScope"] = o.OwnerScope + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableGetNavigatorsResult struct { + value *GetNavigatorsResult + isSet bool +} + +func (v NullableGetNavigatorsResult) Get() *GetNavigatorsResult { + return v.value +} + +func (v *NullableGetNavigatorsResult) Set(val *GetNavigatorsResult) { + v.value = val + v.isSet = true +} + +func (v NullableGetNavigatorsResult) IsSet() bool { + return v.isSet +} + +func (v *NullableGetNavigatorsResult) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetNavigatorsResult(val *GetNavigatorsResult) *NullableGetNavigatorsResult { + return &NullableGetNavigatorsResult{value: val, isSet: true} +} + +func (v NullableGetNavigatorsResult) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetNavigatorsResult) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_job.go b/navigator/model_job.go new file mode 100644 index 0000000..3efd168 --- /dev/null +++ b/navigator/model_job.go @@ -0,0 +1,254 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the Job type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Job{} + +// Job Metric job +type Job struct { + // Resolution of the job + Resolution int64 `json:"resolution"` + // SignalFlow template for the job + Template string `json:"template"` + // Variable name used in the template + VarName string `json:"varName"` + // List of filters for the job + Filters []JobFilter `json:"filters,omitempty"` +} + +type _Job Job + +// NewJob instantiates a new Job object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewJob(resolution int64, template string, varName string) *Job { + this := Job{} + this.Resolution = resolution + this.Template = template + this.VarName = varName + return &this +} + +// NewJobWithDefaults instantiates a new Job object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewJobWithDefaults() *Job { + this := Job{} + return &this +} + +// GetResolution returns the Resolution field value +func (o *Job) GetResolution() int64 { + if o == nil { + var ret int64 + return ret + } + + return o.Resolution +} + +// GetResolutionOk returns a tuple with the Resolution field value +// and a boolean to check if the value has been set. +func (o *Job) GetResolutionOk() (*int64, bool) { + if o == nil { + return nil, false + } + return &o.Resolution, true +} + +// SetResolution sets field value +func (o *Job) SetResolution(v int64) { + o.Resolution = v +} + +// GetTemplate returns the Template field value +func (o *Job) GetTemplate() string { + if o == nil { + var ret string + return ret + } + + return o.Template +} + +// GetTemplateOk returns a tuple with the Template field value +// and a boolean to check if the value has been set. +func (o *Job) GetTemplateOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Template, true +} + +// SetTemplate sets field value +func (o *Job) SetTemplate(v string) { + o.Template = v +} + +// GetVarName returns the VarName field value +func (o *Job) GetVarName() string { + if o == nil { + var ret string + return ret + } + + return o.VarName +} + +// GetVarNameOk returns a tuple with the VarName field value +// and a boolean to check if the value has been set. +func (o *Job) GetVarNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.VarName, true +} + +// SetVarName sets field value +func (o *Job) SetVarName(v string) { + o.VarName = v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *Job) GetFilters() []JobFilter { + if o == nil || IsNil(o.Filters) { + var ret []JobFilter + return ret + } + return o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Job) GetFiltersOk() ([]JobFilter, bool) { + if o == nil || IsNil(o.Filters) { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *Job) HasFilters() bool { + if o != nil && !IsNil(o.Filters) { + return true + } + + return false +} + +// SetFilters gets a reference to the given []JobFilter and assigns it to the Filters field. +func (o *Job) SetFilters(v []JobFilter) { + o.Filters = v +} + +func (o Job) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Job) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["resolution"] = o.Resolution + toSerialize["template"] = o.Template + toSerialize["varName"] = o.VarName + if !IsNil(o.Filters) { + toSerialize["filters"] = o.Filters + } + return toSerialize, nil +} + +func (o *Job) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "resolution", + "template", + "varName", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varJob := _Job{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varJob) + + if err != nil { + return err + } + + *o = Job(varJob) + + return err +} + +type NullableJob struct { + value *Job + isSet bool +} + +func (v NullableJob) Get() *Job { + return v.value +} + +func (v *NullableJob) Set(val *Job) { + v.value = val + v.isSet = true +} + +func (v NullableJob) IsSet() bool { + return v.isSet +} + +func (v *NullableJob) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableJob(val *Job) *NullableJob { + return &NullableJob{value: val, isSet: true} +} + +func (v NullableJob) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableJob) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_job_filter.go b/navigator/model_job_filter.go new file mode 100644 index 0000000..5a51f55 --- /dev/null +++ b/navigator/model_job_filter.go @@ -0,0 +1,273 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the JobFilter type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &JobFilter{} + +// JobFilter Filter for a metric job +type JobFilter struct { + // Custom property or dimension for which you want to filter + Property string `json:"property"` + PropertyValue *PropertyValuesToFilter `json:"propertyValue,omitempty"` + // Indicates whether you want the property to be included or excluded from the filter + Not *bool `json:"not,omitempty"` + // Property type + Type *string `json:"type,omitempty"` +} + +type _JobFilter JobFilter + +// NewJobFilter instantiates a new JobFilter object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewJobFilter(property string) *JobFilter { + this := JobFilter{} + this.Property = property + var not bool = false + this.Not = ¬ + return &this +} + +// NewJobFilterWithDefaults instantiates a new JobFilter object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewJobFilterWithDefaults() *JobFilter { + this := JobFilter{} + var not bool = false + this.Not = ¬ + return &this +} + +// GetProperty returns the Property field value +func (o *JobFilter) GetProperty() string { + if o == nil { + var ret string + return ret + } + + return o.Property +} + +// GetPropertyOk returns a tuple with the Property field value +// and a boolean to check if the value has been set. +func (o *JobFilter) GetPropertyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Property, true +} + +// SetProperty sets field value +func (o *JobFilter) SetProperty(v string) { + o.Property = v +} + +// GetPropertyValue returns the PropertyValue field value if set, zero value otherwise. +func (o *JobFilter) GetPropertyValue() PropertyValuesToFilter { + if o == nil || IsNil(o.PropertyValue) { + var ret PropertyValuesToFilter + return ret + } + return *o.PropertyValue +} + +// GetPropertyValueOk returns a tuple with the PropertyValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *JobFilter) GetPropertyValueOk() (*PropertyValuesToFilter, bool) { + if o == nil || IsNil(o.PropertyValue) { + return nil, false + } + return o.PropertyValue, true +} + +// HasPropertyValue returns a boolean if a field has been set. +func (o *JobFilter) HasPropertyValue() bool { + if o != nil && !IsNil(o.PropertyValue) { + return true + } + + return false +} + +// SetPropertyValue gets a reference to the given PropertyValuesToFilter and assigns it to the PropertyValue field. +func (o *JobFilter) SetPropertyValue(v PropertyValuesToFilter) { + o.PropertyValue = &v +} + +// GetNot returns the Not field value if set, zero value otherwise. +func (o *JobFilter) GetNot() bool { + if o == nil || IsNil(o.Not) { + var ret bool + return ret + } + return *o.Not +} + +// GetNotOk returns a tuple with the Not field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *JobFilter) GetNotOk() (*bool, bool) { + if o == nil || IsNil(o.Not) { + return nil, false + } + return o.Not, true +} + +// HasNot returns a boolean if a field has been set. +func (o *JobFilter) HasNot() bool { + if o != nil && !IsNil(o.Not) { + return true + } + + return false +} + +// SetNot gets a reference to the given bool and assigns it to the Not field. +func (o *JobFilter) SetNot(v bool) { + o.Not = &v +} + +// GetType returns the Type field value if set, zero value otherwise. +func (o *JobFilter) GetType() string { + if o == nil || IsNil(o.Type) { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *JobFilter) GetTypeOk() (*string, bool) { + if o == nil || IsNil(o.Type) { + return nil, false + } + return o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *JobFilter) HasType() bool { + if o != nil && !IsNil(o.Type) { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *JobFilter) SetType(v string) { + o.Type = &v +} + +func (o JobFilter) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o JobFilter) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["property"] = o.Property + if !IsNil(o.PropertyValue) { + toSerialize["propertyValue"] = o.PropertyValue + } + if !IsNil(o.Not) { + toSerialize["not"] = o.Not + } + if !IsNil(o.Type) { + toSerialize["type"] = o.Type + } + return toSerialize, nil +} + +func (o *JobFilter) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "property", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varJobFilter := _JobFilter{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varJobFilter) + + if err != nil { + return err + } + + *o = JobFilter(varJobFilter) + + return err +} + +type NullableJobFilter struct { + value *JobFilter + isSet bool +} + +func (v NullableJobFilter) Get() *JobFilter { + return v.value +} + +func (v *NullableJobFilter) Set(val *JobFilter) { + v.value = val + v.isSet = true +} + +func (v NullableJobFilter) IsSet() bool { + return v.isSet +} + +func (v *NullableJobFilter) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableJobFilter(val *JobFilter) *NullableJobFilter { + return &NullableJobFilter{value: val, isSet: true} +} + +func (v NullableJobFilter) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableJobFilter) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_list_column.go b/navigator/model_list_column.go new file mode 100644 index 0000000..41a7125 --- /dev/null +++ b/navigator/model_list_column.go @@ -0,0 +1,225 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the ListColumn type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ListColumn{} + +// ListColumn List column item +type ListColumn struct { + // Column display name + DisplayName string `json:"displayName"` + // Column format + Format *string `json:"format,omitempty"` + // Custom property or dimension + Property string `json:"property"` +} + +type _ListColumn ListColumn + +// NewListColumn instantiates a new ListColumn object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListColumn(displayName string, property string) *ListColumn { + this := ListColumn{} + this.DisplayName = displayName + this.Property = property + return &this +} + +// NewListColumnWithDefaults instantiates a new ListColumn object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListColumnWithDefaults() *ListColumn { + this := ListColumn{} + return &this +} + +// GetDisplayName returns the DisplayName field value +func (o *ListColumn) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *ListColumn) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *ListColumn) SetDisplayName(v string) { + o.DisplayName = v +} + +// GetFormat returns the Format field value if set, zero value otherwise. +func (o *ListColumn) GetFormat() string { + if o == nil || IsNil(o.Format) { + var ret string + return ret + } + return *o.Format +} + +// GetFormatOk returns a tuple with the Format field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListColumn) GetFormatOk() (*string, bool) { + if o == nil || IsNil(o.Format) { + return nil, false + } + return o.Format, true +} + +// HasFormat returns a boolean if a field has been set. +func (o *ListColumn) HasFormat() bool { + if o != nil && !IsNil(o.Format) { + return true + } + + return false +} + +// SetFormat gets a reference to the given string and assigns it to the Format field. +func (o *ListColumn) SetFormat(v string) { + o.Format = &v +} + +// GetProperty returns the Property field value +func (o *ListColumn) GetProperty() string { + if o == nil { + var ret string + return ret + } + + return o.Property +} + +// GetPropertyOk returns a tuple with the Property field value +// and a boolean to check if the value has been set. +func (o *ListColumn) GetPropertyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Property, true +} + +// SetProperty sets field value +func (o *ListColumn) SetProperty(v string) { + o.Property = v +} + +func (o ListColumn) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ListColumn) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName + if !IsNil(o.Format) { + toSerialize["format"] = o.Format + } + toSerialize["property"] = o.Property + return toSerialize, nil +} + +func (o *ListColumn) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "displayName", + "property", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varListColumn := _ListColumn{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varListColumn) + + if err != nil { + return err + } + + *o = ListColumn(varListColumn) + + return err +} + +type NullableListColumn struct { + value *ListColumn + isSet bool +} + +func (v NullableListColumn) Get() *ListColumn { + return v.value +} + +func (v *NullableListColumn) Set(val *ListColumn) { + v.value = val + v.isSet = true +} + +func (v NullableListColumn) IsSet() bool { + return v.isSet +} + +func (v *NullableListColumn) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListColumn(val *ListColumn) *NullableListColumn { + return &NullableListColumn{value: val, isSet: true} +} + +func (v NullableListColumn) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListColumn) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_list_of_table_settings_for_properties_in_the_chart_inner.go b/navigator/model_list_of_table_settings_for_properties_in_the_chart_inner.go new file mode 100644 index 0000000..5a16336 --- /dev/null +++ b/navigator/model_list_of_table_settings_for_properties_in_the_chart_inner.go @@ -0,0 +1,168 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the ListOfTableSettingsForPropertiesInTheChartInner type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ListOfTableSettingsForPropertiesInTheChartInner{} + +// ListOfTableSettingsForPropertiesInTheChartInner struct for ListOfTableSettingsForPropertiesInTheChartInner +type ListOfTableSettingsForPropertiesInTheChartInner struct { + // Controls the display of a property in the legend + Enabled *bool `json:"enabled,omitempty"` + // Property name to show or hide + Property *string `json:"property,omitempty"` +} + +// NewListOfTableSettingsForPropertiesInTheChartInner instantiates a new ListOfTableSettingsForPropertiesInTheChartInner object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewListOfTableSettingsForPropertiesInTheChartInner() *ListOfTableSettingsForPropertiesInTheChartInner { + this := ListOfTableSettingsForPropertiesInTheChartInner{} + var enabled bool = true + this.Enabled = &enabled + return &this +} + +// NewListOfTableSettingsForPropertiesInTheChartInnerWithDefaults instantiates a new ListOfTableSettingsForPropertiesInTheChartInner object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewListOfTableSettingsForPropertiesInTheChartInnerWithDefaults() *ListOfTableSettingsForPropertiesInTheChartInner { + this := ListOfTableSettingsForPropertiesInTheChartInner{} + var enabled bool = true + this.Enabled = &enabled + return &this +} + +// GetEnabled returns the Enabled field value if set, zero value otherwise. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) GetEnabled() bool { + if o == nil || IsNil(o.Enabled) { + var ret bool + return ret + } + return *o.Enabled +} + +// GetEnabledOk returns a tuple with the Enabled field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) GetEnabledOk() (*bool, bool) { + if o == nil || IsNil(o.Enabled) { + return nil, false + } + return o.Enabled, true +} + +// HasEnabled returns a boolean if a field has been set. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) HasEnabled() bool { + if o != nil && !IsNil(o.Enabled) { + return true + } + + return false +} + +// SetEnabled gets a reference to the given bool and assigns it to the Enabled field. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) SetEnabled(v bool) { + o.Enabled = &v +} + +// GetProperty returns the Property field value if set, zero value otherwise. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) GetProperty() string { + if o == nil || IsNil(o.Property) { + var ret string + return ret + } + return *o.Property +} + +// GetPropertyOk returns a tuple with the Property field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) GetPropertyOk() (*string, bool) { + if o == nil || IsNil(o.Property) { + return nil, false + } + return o.Property, true +} + +// HasProperty returns a boolean if a field has been set. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) HasProperty() bool { + if o != nil && !IsNil(o.Property) { + return true + } + + return false +} + +// SetProperty gets a reference to the given string and assigns it to the Property field. +func (o *ListOfTableSettingsForPropertiesInTheChartInner) SetProperty(v string) { + o.Property = &v +} + +func (o ListOfTableSettingsForPropertiesInTheChartInner) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ListOfTableSettingsForPropertiesInTheChartInner) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Enabled) { + toSerialize["enabled"] = o.Enabled + } + if !IsNil(o.Property) { + toSerialize["property"] = o.Property + } + return toSerialize, nil +} + +type NullableListOfTableSettingsForPropertiesInTheChartInner struct { + value *ListOfTableSettingsForPropertiesInTheChartInner + isSet bool +} + +func (v NullableListOfTableSettingsForPropertiesInTheChartInner) Get() *ListOfTableSettingsForPropertiesInTheChartInner { + return v.value +} + +func (v *NullableListOfTableSettingsForPropertiesInTheChartInner) Set(val *ListOfTableSettingsForPropertiesInTheChartInner) { + v.value = val + v.isSet = true +} + +func (v NullableListOfTableSettingsForPropertiesInTheChartInner) IsSet() bool { + return v.isSet +} + +func (v *NullableListOfTableSettingsForPropertiesInTheChartInner) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListOfTableSettingsForPropertiesInTheChartInner(val *ListOfTableSettingsForPropertiesInTheChartInner) *NullableListOfTableSettingsForPropertiesInTheChartInner { + return &NullableListOfTableSettingsForPropertiesInTheChartInner{value: val, isSet: true} +} + +func (v NullableListOfTableSettingsForPropertiesInTheChartInner) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListOfTableSettingsForPropertiesInTheChartInner) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_metric.go b/navigator/model_metric.go new file mode 100644 index 0000000..9bed091 --- /dev/null +++ b/navigator/model_metric.go @@ -0,0 +1,429 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the Metric type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Metric{} + +// Metric Metric to display on a navigator +type Metric struct { + ColoringScheme *ColoringScheme `json:"coloringScheme,omitempty"` + // Description of the metric + Description *string `json:"description,omitempty"` + // Metric display name + DisplayName *string `json:"displayName,omitempty"` + Job Job `json:"job"` + // Metric name + Id string `json:"id"` + // Metric type + Type string `json:"type"` + // Metric value label + ValueLabel *string `json:"valueLabel,omitempty"` + // Metric value format + ValueFormat *string `json:"valueFormat,omitempty"` + // List of metric selectors + MetricSelectors []string `json:"metricSelectors"` +} + +type _Metric Metric + +// NewMetric instantiates a new Metric object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewMetric(job Job, id string, type_ string, metricSelectors []string) *Metric { + this := Metric{} + this.Job = job + this.Id = id + this.Type = type_ + this.MetricSelectors = metricSelectors + return &this +} + +// NewMetricWithDefaults instantiates a new Metric object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewMetricWithDefaults() *Metric { + this := Metric{} + return &this +} + +// GetColoringScheme returns the ColoringScheme field value if set, zero value otherwise. +func (o *Metric) GetColoringScheme() ColoringScheme { + if o == nil || IsNil(o.ColoringScheme) { + var ret ColoringScheme + return ret + } + return *o.ColoringScheme +} + +// GetColoringSchemeOk returns a tuple with the ColoringScheme field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Metric) GetColoringSchemeOk() (*ColoringScheme, bool) { + if o == nil || IsNil(o.ColoringScheme) { + return nil, false + } + return o.ColoringScheme, true +} + +// HasColoringScheme returns a boolean if a field has been set. +func (o *Metric) HasColoringScheme() bool { + if o != nil && !IsNil(o.ColoringScheme) { + return true + } + + return false +} + +// SetColoringScheme gets a reference to the given ColoringScheme and assigns it to the ColoringScheme field. +func (o *Metric) SetColoringScheme(v ColoringScheme) { + o.ColoringScheme = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *Metric) GetDescription() string { + if o == nil || IsNil(o.Description) { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Metric) GetDescriptionOk() (*string, bool) { + if o == nil || IsNil(o.Description) { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *Metric) HasDescription() bool { + if o != nil && !IsNil(o.Description) { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *Metric) SetDescription(v string) { + o.Description = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *Metric) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Metric) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *Metric) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *Metric) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetJob returns the Job field value +func (o *Metric) GetJob() Job { + if o == nil { + var ret Job + return ret + } + + return o.Job +} + +// GetJobOk returns a tuple with the Job field value +// and a boolean to check if the value has been set. +func (o *Metric) GetJobOk() (*Job, bool) { + if o == nil { + return nil, false + } + return &o.Job, true +} + +// SetJob sets field value +func (o *Metric) SetJob(v Job) { + o.Job = v +} + +// GetId returns the Id field value +func (o *Metric) GetId() string { + if o == nil { + var ret string + return ret + } + + return o.Id +} + +// GetIdOk returns a tuple with the Id field value +// and a boolean to check if the value has been set. +func (o *Metric) GetIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Id, true +} + +// SetId sets field value +func (o *Metric) SetId(v string) { + o.Id = v +} + +// GetType returns the Type field value +func (o *Metric) GetType() string { + if o == nil { + var ret string + return ret + } + + return o.Type +} + +// GetTypeOk returns a tuple with the Type field value +// and a boolean to check if the value has been set. +func (o *Metric) GetTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Type, true +} + +// SetType sets field value +func (o *Metric) SetType(v string) { + o.Type = v +} + +// GetValueLabel returns the ValueLabel field value if set, zero value otherwise. +func (o *Metric) GetValueLabel() string { + if o == nil || IsNil(o.ValueLabel) { + var ret string + return ret + } + return *o.ValueLabel +} + +// GetValueLabelOk returns a tuple with the ValueLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Metric) GetValueLabelOk() (*string, bool) { + if o == nil || IsNil(o.ValueLabel) { + return nil, false + } + return o.ValueLabel, true +} + +// HasValueLabel returns a boolean if a field has been set. +func (o *Metric) HasValueLabel() bool { + if o != nil && !IsNil(o.ValueLabel) { + return true + } + + return false +} + +// SetValueLabel gets a reference to the given string and assigns it to the ValueLabel field. +func (o *Metric) SetValueLabel(v string) { + o.ValueLabel = &v +} + +// GetValueFormat returns the ValueFormat field value if set, zero value otherwise. +func (o *Metric) GetValueFormat() string { + if o == nil || IsNil(o.ValueFormat) { + var ret string + return ret + } + return *o.ValueFormat +} + +// GetValueFormatOk returns a tuple with the ValueFormat field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Metric) GetValueFormatOk() (*string, bool) { + if o == nil || IsNil(o.ValueFormat) { + return nil, false + } + return o.ValueFormat, true +} + +// HasValueFormat returns a boolean if a field has been set. +func (o *Metric) HasValueFormat() bool { + if o != nil && !IsNil(o.ValueFormat) { + return true + } + + return false +} + +// SetValueFormat gets a reference to the given string and assigns it to the ValueFormat field. +func (o *Metric) SetValueFormat(v string) { + o.ValueFormat = &v +} + +// GetMetricSelectors returns the MetricSelectors field value +func (o *Metric) GetMetricSelectors() []string { + if o == nil { + var ret []string + return ret + } + + return o.MetricSelectors +} + +// GetMetricSelectorsOk returns a tuple with the MetricSelectors field value +// and a boolean to check if the value has been set. +func (o *Metric) GetMetricSelectorsOk() ([]string, bool) { + if o == nil { + return nil, false + } + return o.MetricSelectors, true +} + +// SetMetricSelectors sets field value +func (o *Metric) SetMetricSelectors(v []string) { + o.MetricSelectors = v +} + +func (o Metric) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Metric) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ColoringScheme) { + toSerialize["coloringScheme"] = o.ColoringScheme + } + if !IsNil(o.Description) { + toSerialize["description"] = o.Description + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + toSerialize["job"] = o.Job + toSerialize["id"] = o.Id + toSerialize["type"] = o.Type + if !IsNil(o.ValueLabel) { + toSerialize["valueLabel"] = o.ValueLabel + } + if !IsNil(o.ValueFormat) { + toSerialize["valueFormat"] = o.ValueFormat + } + toSerialize["metricSelectors"] = o.MetricSelectors + return toSerialize, nil +} + +func (o *Metric) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "job", + "id", + "type", + "metricSelectors", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varMetric := _Metric{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varMetric) + + if err != nil { + return err + } + + *o = Metric(varMetric) + + return err +} + +type NullableMetric struct { + value *Metric + isSet bool +} + +func (v NullableMetric) Get() *Metric { + return v.value +} + +func (v *NullableMetric) Set(val *Metric) { + v.value = val + v.isSet = true +} + +func (v NullableMetric) IsSet() bool { + return v.isSet +} + +func (v *NullableMetric) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableMetric(val *Metric) *NullableMetric { + return &NullableMetric{value: val, isSet: true} +} + +func (v NullableMetric) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableMetric) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_navigator.go b/navigator/model_navigator.go new file mode 100644 index 0000000..698ff26 --- /dev/null +++ b/navigator/model_navigator.go @@ -0,0 +1,977 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the Navigator type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Navigator{} + +// Navigator Navigator properties +type Navigator struct { + // Array of dashboard IDs to use for aggregate display. Specific to GET /navigator. + AggregateDashboards []string `json:"aggregateDashboards,omitempty"` + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator + Creator *string `json:"creator,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // Time at which the navigator was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + // Navigator unique code + NavigatorCode *string `json:"navigatorCode,omitempty"` + OwnerScope *OwnerScope `json:"ownerScope,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Properties shared by all instances + RequiredProperties []string `json:"requiredProperties,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewNavigator instantiates a new Navigator object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewNavigator() *Navigator { + this := Navigator{} + return &this +} + +// NewNavigatorWithDefaults instantiates a new Navigator object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewNavigatorWithDefaults() *Navigator { + this := Navigator{} + return &this +} + +// GetAggregateDashboards returns the AggregateDashboards field value if set, zero value otherwise. +func (o *Navigator) GetAggregateDashboards() []string { + if o == nil || IsNil(o.AggregateDashboards) { + var ret []string + return ret + } + return o.AggregateDashboards +} + +// GetAggregateDashboardsOk returns a tuple with the AggregateDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetAggregateDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.AggregateDashboards) { + return nil, false + } + return o.AggregateDashboards, true +} + +// HasAggregateDashboards returns a boolean if a field has been set. +func (o *Navigator) HasAggregateDashboards() bool { + if o != nil && !IsNil(o.AggregateDashboards) { + return true + } + + return false +} + +// SetAggregateDashboards gets a reference to the given []string and assigns it to the AggregateDashboards field. +func (o *Navigator) SetAggregateDashboards(v []string) { + o.AggregateDashboards = v +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *Navigator) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *Navigator) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *Navigator) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *Navigator) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *Navigator) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *Navigator) SetCategories(v []Category) { + o.Categories = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *Navigator) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *Navigator) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *Navigator) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *Navigator) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *Navigator) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *Navigator) SetCreator(v string) { + o.Creator = &v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *Navigator) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *Navigator) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *Navigator) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *Navigator) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *Navigator) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *Navigator) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *Navigator) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *Navigator) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *Navigator) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *Navigator) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *Navigator) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *Navigator) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *Navigator) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *Navigator) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *Navigator) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *Navigator) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *Navigator) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *Navigator) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *Navigator) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *Navigator) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *Navigator) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *Navigator) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *Navigator) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *Navigator) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *Navigator) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *Navigator) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *Navigator) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *Navigator) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *Navigator) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *Navigator) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *Navigator) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *Navigator) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *Navigator) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetNavigatorCode returns the NavigatorCode field value if set, zero value otherwise. +func (o *Navigator) GetNavigatorCode() string { + if o == nil || IsNil(o.NavigatorCode) { + var ret string + return ret + } + return *o.NavigatorCode +} + +// GetNavigatorCodeOk returns a tuple with the NavigatorCode field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetNavigatorCodeOk() (*string, bool) { + if o == nil || IsNil(o.NavigatorCode) { + return nil, false + } + return o.NavigatorCode, true +} + +// HasNavigatorCode returns a boolean if a field has been set. +func (o *Navigator) HasNavigatorCode() bool { + if o != nil && !IsNil(o.NavigatorCode) { + return true + } + + return false +} + +// SetNavigatorCode gets a reference to the given string and assigns it to the NavigatorCode field. +func (o *Navigator) SetNavigatorCode(v string) { + o.NavigatorCode = &v +} + +// GetOwnerScope returns the OwnerScope field value if set, zero value otherwise. +func (o *Navigator) GetOwnerScope() OwnerScope { + if o == nil || IsNil(o.OwnerScope) { + var ret OwnerScope + return ret + } + return *o.OwnerScope +} + +// GetOwnerScopeOk returns a tuple with the OwnerScope field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetOwnerScopeOk() (*OwnerScope, bool) { + if o == nil || IsNil(o.OwnerScope) { + return nil, false + } + return o.OwnerScope, true +} + +// HasOwnerScope returns a boolean if a field has been set. +func (o *Navigator) HasOwnerScope() bool { + if o != nil && !IsNil(o.OwnerScope) { + return true + } + + return false +} + +// SetOwnerScope gets a reference to the given OwnerScope and assigns it to the OwnerScope field. +func (o *Navigator) SetOwnerScope(v OwnerScope) { + o.OwnerScope = &v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *Navigator) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *Navigator) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *Navigator) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetRequiredProperties returns the RequiredProperties field value if set, zero value otherwise. +func (o *Navigator) GetRequiredProperties() []string { + if o == nil || IsNil(o.RequiredProperties) { + var ret []string + return ret + } + return o.RequiredProperties +} + +// GetRequiredPropertiesOk returns a tuple with the RequiredProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetRequiredPropertiesOk() ([]string, bool) { + if o == nil || IsNil(o.RequiredProperties) { + return nil, false + } + return o.RequiredProperties, true +} + +// HasRequiredProperties returns a boolean if a field has been set. +func (o *Navigator) HasRequiredProperties() bool { + if o != nil && !IsNil(o.RequiredProperties) { + return true + } + + return false +} + +// SetRequiredProperties gets a reference to the given []string and assigns it to the RequiredProperties field. +func (o *Navigator) SetRequiredProperties(v []string) { + o.RequiredProperties = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *Navigator) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *Navigator) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *Navigator) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *Navigator) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *Navigator) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *Navigator) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *Navigator) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *Navigator) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *Navigator) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *Navigator) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *Navigator) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *Navigator) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *Navigator) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o Navigator) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o Navigator) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AggregateDashboards) { + toSerialize["aggregateDashboards"] = o.AggregateDashboards + } + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.NavigatorCode) { + toSerialize["navigatorCode"] = o.NavigatorCode + } + if !IsNil(o.OwnerScope) { + toSerialize["ownerScope"] = o.OwnerScope + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.RequiredProperties) { + toSerialize["requiredProperties"] = o.RequiredProperties + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableNavigator struct { + value *Navigator + isSet bool +} + +func (v NullableNavigator) Get() *Navigator { + return v.value +} + +func (v *NullableNavigator) Set(val *Navigator) { + v.value = val + v.isSet = true +} + +func (v NullableNavigator) IsSet() bool { + return v.isSet +} + +func (v *NullableNavigator) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableNavigator(val *Navigator) *NullableNavigator { + return &NullableNavigator{value: val, isSet: true} +} + +func (v NullableNavigator) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableNavigator) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_options_for_a_line_chart.go b/navigator/model_options_for_a_line_chart.go new file mode 100644 index 0000000..4ce4e38 --- /dev/null +++ b/navigator/model_options_for_a_line_chart.go @@ -0,0 +1,131 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the OptionsForALineChart type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &OptionsForALineChart{} + +// OptionsForALineChart Options for a line chart +type OptionsForALineChart struct { + // Controls appearance of markers for data arrival times + ShowDataMarkers *bool `json:"showDataMarkers,omitempty"` +} + +// NewOptionsForALineChart instantiates a new OptionsForALineChart object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewOptionsForALineChart() *OptionsForALineChart { + this := OptionsForALineChart{} + var showDataMarkers bool = false + this.ShowDataMarkers = &showDataMarkers + return &this +} + +// NewOptionsForALineChartWithDefaults instantiates a new OptionsForALineChart object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewOptionsForALineChartWithDefaults() *OptionsForALineChart { + this := OptionsForALineChart{} + var showDataMarkers bool = false + this.ShowDataMarkers = &showDataMarkers + return &this +} + +// GetShowDataMarkers returns the ShowDataMarkers field value if set, zero value otherwise. +func (o *OptionsForALineChart) GetShowDataMarkers() bool { + if o == nil || IsNil(o.ShowDataMarkers) { + var ret bool + return ret + } + return *o.ShowDataMarkers +} + +// GetShowDataMarkersOk returns a tuple with the ShowDataMarkers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OptionsForALineChart) GetShowDataMarkersOk() (*bool, bool) { + if o == nil || IsNil(o.ShowDataMarkers) { + return nil, false + } + return o.ShowDataMarkers, true +} + +// HasShowDataMarkers returns a boolean if a field has been set. +func (o *OptionsForALineChart) HasShowDataMarkers() bool { + if o != nil && !IsNil(o.ShowDataMarkers) { + return true + } + + return false +} + +// SetShowDataMarkers gets a reference to the given bool and assigns it to the ShowDataMarkers field. +func (o *OptionsForALineChart) SetShowDataMarkers(v bool) { + o.ShowDataMarkers = &v +} + +func (o OptionsForALineChart) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o OptionsForALineChart) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ShowDataMarkers) { + toSerialize["showDataMarkers"] = o.ShowDataMarkers + } + return toSerialize, nil +} + +type NullableOptionsForALineChart struct { + value *OptionsForALineChart + isSet bool +} + +func (v NullableOptionsForALineChart) Get() *OptionsForALineChart { + return v.value +} + +func (v *NullableOptionsForALineChart) Set(val *OptionsForALineChart) { + v.value = val + v.isSet = true +} + +func (v NullableOptionsForALineChart) IsSet() bool { + return v.isSet +} + +func (v *NullableOptionsForALineChart) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableOptionsForALineChart(val *OptionsForALineChart) *NullableOptionsForALineChart { + return &NullableOptionsForALineChart{value: val, isSet: true} +} + +func (v NullableOptionsForALineChart) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableOptionsForALineChart) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_options_for_the_time_displayed_in_a_chart.go b/navigator/model_options_for_the_time_displayed_in_a_chart.go new file mode 100644 index 0000000..01ef6d7 --- /dev/null +++ b/navigator/model_options_for_the_time_displayed_in_a_chart.go @@ -0,0 +1,246 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the OptionsForTheTimeDisplayedInAChart type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &OptionsForTheTimeDisplayedInAChart{} + +// OptionsForTheTimeDisplayedInAChart Time-related properties +type OptionsForTheTimeDisplayedInAChart struct { + // Last timestamp to display + End *int64 `json:"end,omitempty"` + // Number of milliseconds to display + Range *int64 `json:"range,omitempty"` + // First timestamp to display + Start *int64 `json:"start,omitempty"` + // Use explicit time range or show the last n milliseconds + Type *string `json:"type,omitempty"` +} + +// NewOptionsForTheTimeDisplayedInAChart instantiates a new OptionsForTheTimeDisplayedInAChart object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewOptionsForTheTimeDisplayedInAChart() *OptionsForTheTimeDisplayedInAChart { + this := OptionsForTheTimeDisplayedInAChart{} + var range_ int64 = 0 + this.Range = &range_ + var type_ string = "relative" + this.Type = &type_ + return &this +} + +// NewOptionsForTheTimeDisplayedInAChartWithDefaults instantiates a new OptionsForTheTimeDisplayedInAChart object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewOptionsForTheTimeDisplayedInAChartWithDefaults() *OptionsForTheTimeDisplayedInAChart { + this := OptionsForTheTimeDisplayedInAChart{} + var range_ int64 = 0 + this.Range = &range_ + var type_ string = "relative" + this.Type = &type_ + return &this +} + +// GetEnd returns the End field value if set, zero value otherwise. +func (o *OptionsForTheTimeDisplayedInAChart) GetEnd() int64 { + if o == nil || IsNil(o.End) { + var ret int64 + return ret + } + return *o.End +} + +// GetEndOk returns a tuple with the End field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OptionsForTheTimeDisplayedInAChart) GetEndOk() (*int64, bool) { + if o == nil || IsNil(o.End) { + return nil, false + } + return o.End, true +} + +// HasEnd returns a boolean if a field has been set. +func (o *OptionsForTheTimeDisplayedInAChart) HasEnd() bool { + if o != nil && !IsNil(o.End) { + return true + } + + return false +} + +// SetEnd gets a reference to the given int64 and assigns it to the End field. +func (o *OptionsForTheTimeDisplayedInAChart) SetEnd(v int64) { + o.End = &v +} + +// GetRange returns the Range field value if set, zero value otherwise. +func (o *OptionsForTheTimeDisplayedInAChart) GetRange() int64 { + if o == nil || IsNil(o.Range) { + var ret int64 + return ret + } + return *o.Range +} + +// GetRangeOk returns a tuple with the Range field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OptionsForTheTimeDisplayedInAChart) GetRangeOk() (*int64, bool) { + if o == nil || IsNil(o.Range) { + return nil, false + } + return o.Range, true +} + +// HasRange returns a boolean if a field has been set. +func (o *OptionsForTheTimeDisplayedInAChart) HasRange() bool { + if o != nil && !IsNil(o.Range) { + return true + } + + return false +} + +// SetRange gets a reference to the given int64 and assigns it to the Range field. +func (o *OptionsForTheTimeDisplayedInAChart) SetRange(v int64) { + o.Range = &v +} + +// GetStart returns the Start field value if set, zero value otherwise. +func (o *OptionsForTheTimeDisplayedInAChart) GetStart() int64 { + if o == nil || IsNil(o.Start) { + var ret int64 + return ret + } + return *o.Start +} + +// GetStartOk returns a tuple with the Start field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OptionsForTheTimeDisplayedInAChart) GetStartOk() (*int64, bool) { + if o == nil || IsNil(o.Start) { + return nil, false + } + return o.Start, true +} + +// HasStart returns a boolean if a field has been set. +func (o *OptionsForTheTimeDisplayedInAChart) HasStart() bool { + if o != nil && !IsNil(o.Start) { + return true + } + + return false +} + +// SetStart gets a reference to the given int64 and assigns it to the Start field. +func (o *OptionsForTheTimeDisplayedInAChart) SetStart(v int64) { + o.Start = &v +} + +// GetType returns the Type field value if set, zero value otherwise. +func (o *OptionsForTheTimeDisplayedInAChart) GetType() string { + if o == nil || IsNil(o.Type) { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *OptionsForTheTimeDisplayedInAChart) GetTypeOk() (*string, bool) { + if o == nil || IsNil(o.Type) { + return nil, false + } + return o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *OptionsForTheTimeDisplayedInAChart) HasType() bool { + if o != nil && !IsNil(o.Type) { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *OptionsForTheTimeDisplayedInAChart) SetType(v string) { + o.Type = &v +} + +func (o OptionsForTheTimeDisplayedInAChart) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o OptionsForTheTimeDisplayedInAChart) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.End) { + toSerialize["end"] = o.End + } + if !IsNil(o.Range) { + toSerialize["range"] = o.Range + } + if !IsNil(o.Start) { + toSerialize["start"] = o.Start + } + if !IsNil(o.Type) { + toSerialize["type"] = o.Type + } + return toSerialize, nil +} + +type NullableOptionsForTheTimeDisplayedInAChart struct { + value *OptionsForTheTimeDisplayedInAChart + isSet bool +} + +func (v NullableOptionsForTheTimeDisplayedInAChart) Get() *OptionsForTheTimeDisplayedInAChart { + return v.value +} + +func (v *NullableOptionsForTheTimeDisplayedInAChart) Set(val *OptionsForTheTimeDisplayedInAChart) { + v.value = val + v.isSet = true +} + +func (v NullableOptionsForTheTimeDisplayedInAChart) IsSet() bool { + return v.isSet +} + +func (v *NullableOptionsForTheTimeDisplayedInAChart) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableOptionsForTheTimeDisplayedInAChart(val *OptionsForTheTimeDisplayedInAChart) *NullableOptionsForTheTimeDisplayedInAChart { + return &NullableOptionsForTheTimeDisplayedInAChart{value: val, isSet: true} +} + +func (v NullableOptionsForTheTimeDisplayedInAChart) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableOptionsForTheTimeDisplayedInAChart) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_owner_scope.go b/navigator/model_owner_scope.go new file mode 100644 index 0000000..02e6d04 --- /dev/null +++ b/navigator/model_owner_scope.go @@ -0,0 +1,111 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "fmt" +) + +// OwnerScope Indicates how this navigator was created. +type OwnerScope string + +// List of OwnerScope +const ( + SPLUNK OwnerScope = "splunk" + ORGANIZATION OwnerScope = "organization" +) + +// All allowed values of OwnerScope enum +var AllowedOwnerScopeEnumValues = []OwnerScope{ + "splunk", + "organization", +} + +func (v *OwnerScope) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := OwnerScope(value) + for _, existing := range AllowedOwnerScopeEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + return fmt.Errorf("%+v is not a valid OwnerScope", value) +} + +// NewOwnerScopeFromValue returns a pointer to a valid OwnerScope +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewOwnerScopeFromValue(v string) (*OwnerScope, error) { + ev := OwnerScope(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for OwnerScope: valid values are %v", v, AllowedOwnerScopeEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v OwnerScope) IsValid() bool { + for _, existing := range AllowedOwnerScopeEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to OwnerScope value +func (v OwnerScope) Ptr() *OwnerScope { + return &v +} + +type NullableOwnerScope struct { + value *OwnerScope + isSet bool +} + +func (v NullableOwnerScope) Get() *OwnerScope { + return v.value +} + +func (v *NullableOwnerScope) Set(val *OwnerScope) { + v.value = val + v.isSet = true +} + +func (v NullableOwnerScope) IsSet() bool { + return v.isSet +} + +func (v *NullableOwnerScope) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableOwnerScope(val *OwnerScope) *NullableOwnerScope { + return &NullableOwnerScope{value: val, isSet: true} +} + +func (v NullableOwnerScope) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableOwnerScope) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + diff --git a/navigator/model_properties_for_area_charts.go b/navigator/model_properties_for_area_charts.go new file mode 100644 index 0000000..81a1870 --- /dev/null +++ b/navigator/model_properties_for_area_charts.go @@ -0,0 +1,131 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the PropertiesForAreaCharts type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &PropertiesForAreaCharts{} + +// PropertiesForAreaCharts struct for PropertiesForAreaCharts +type PropertiesForAreaCharts struct { + // Controls appearance of markers for data arrival times + ShowDataMarkers *bool `json:"showDataMarkers,omitempty"` +} + +// NewPropertiesForAreaCharts instantiates a new PropertiesForAreaCharts object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewPropertiesForAreaCharts() *PropertiesForAreaCharts { + this := PropertiesForAreaCharts{} + var showDataMarkers bool = false + this.ShowDataMarkers = &showDataMarkers + return &this +} + +// NewPropertiesForAreaChartsWithDefaults instantiates a new PropertiesForAreaCharts object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewPropertiesForAreaChartsWithDefaults() *PropertiesForAreaCharts { + this := PropertiesForAreaCharts{} + var showDataMarkers bool = false + this.ShowDataMarkers = &showDataMarkers + return &this +} + +// GetShowDataMarkers returns the ShowDataMarkers field value if set, zero value otherwise. +func (o *PropertiesForAreaCharts) GetShowDataMarkers() bool { + if o == nil || IsNil(o.ShowDataMarkers) { + var ret bool + return ret + } + return *o.ShowDataMarkers +} + +// GetShowDataMarkersOk returns a tuple with the ShowDataMarkers field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *PropertiesForAreaCharts) GetShowDataMarkersOk() (*bool, bool) { + if o == nil || IsNil(o.ShowDataMarkers) { + return nil, false + } + return o.ShowDataMarkers, true +} + +// HasShowDataMarkers returns a boolean if a field has been set. +func (o *PropertiesForAreaCharts) HasShowDataMarkers() bool { + if o != nil && !IsNil(o.ShowDataMarkers) { + return true + } + + return false +} + +// SetShowDataMarkers gets a reference to the given bool and assigns it to the ShowDataMarkers field. +func (o *PropertiesForAreaCharts) SetShowDataMarkers(v bool) { + o.ShowDataMarkers = &v +} + +func (o PropertiesForAreaCharts) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o PropertiesForAreaCharts) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ShowDataMarkers) { + toSerialize["showDataMarkers"] = o.ShowDataMarkers + } + return toSerialize, nil +} + +type NullablePropertiesForAreaCharts struct { + value *PropertiesForAreaCharts + isSet bool +} + +func (v NullablePropertiesForAreaCharts) Get() *PropertiesForAreaCharts { + return v.value +} + +func (v *NullablePropertiesForAreaCharts) Set(val *PropertiesForAreaCharts) { + v.value = val + v.isSet = true +} + +func (v NullablePropertiesForAreaCharts) IsSet() bool { + return v.isSet +} + +func (v *NullablePropertiesForAreaCharts) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePropertiesForAreaCharts(val *PropertiesForAreaCharts) *NullablePropertiesForAreaCharts { + return &NullablePropertiesForAreaCharts{value: val, isSet: true} +} + +func (v NullablePropertiesForAreaCharts) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePropertiesForAreaCharts) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_property_values_to_filter.go b/navigator/model_property_values_to_filter.go new file mode 100644 index 0000000..dddd33e --- /dev/null +++ b/navigator/model_property_values_to_filter.go @@ -0,0 +1,180 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "fmt" + "gopkg.in/validator.v2" +) + +// PropertyValuesToFilter - Property values to filter +type PropertyValuesToFilter struct { + ArrayOfString *[]string + String *string +} + +// []stringAsPropertyValuesToFilter is a convenience function that returns []string wrapped in PropertyValuesToFilter +func ArrayOfStringAsPropertyValuesToFilter(v *[]string) PropertyValuesToFilter { + return PropertyValuesToFilter{ + ArrayOfString: v, + } +} + +// stringAsPropertyValuesToFilter is a convenience function that returns string wrapped in PropertyValuesToFilter +func StringAsPropertyValuesToFilter(v *string) PropertyValuesToFilter { + return PropertyValuesToFilter{ + String: v, + } +} + + +// Unmarshal JSON data into one of the pointers in the struct +func (dst *PropertyValuesToFilter) UnmarshalJSON(data []byte) error { + var err error + match := 0 + // try to unmarshal data into ArrayOfString + err = newStrictDecoder(data).Decode(&dst.ArrayOfString) + if err == nil { + jsonArrayOfString, _ := json.Marshal(dst.ArrayOfString) + if string(jsonArrayOfString) == "{}" { // empty struct + dst.ArrayOfString = nil + } else { + if err = validator.Validate(dst.ArrayOfString); err != nil { + dst.ArrayOfString = nil + } else { + match++ + } + } + } else { + dst.ArrayOfString = nil + } + + // try to unmarshal data into String + err = newStrictDecoder(data).Decode(&dst.String) + if err == nil { + jsonString, _ := json.Marshal(dst.String) + if string(jsonString) == "{}" { // empty struct + dst.String = nil + } else { + if err = validator.Validate(dst.String); err != nil { + dst.String = nil + } else { + match++ + } + } + } else { + dst.String = nil + } + + if match > 1 { // more than 1 match + // reset to nil + dst.ArrayOfString = nil + dst.String = nil + + return fmt.Errorf("data matches more than one schema in oneOf(PropertyValuesToFilter)") + } else if match == 1 { + return nil // exactly one match + } else { // no match + if err != nil { + return fmt.Errorf("data failed to match schemas in oneOf(PropertyValuesToFilter): %v", err) + } else { + return fmt.Errorf("data failed to match schemas in oneOf(PropertyValuesToFilter)") + } + if err != nil { + return fmt.Errorf("data failed to match schemas in oneOf(PropertyValuesToFilter): %v", err) + } else { + return fmt.Errorf("data failed to match schemas in oneOf(PropertyValuesToFilter)") + } + } +} + +// Marshal data from the first non-nil pointers in the struct to JSON +func (src PropertyValuesToFilter) MarshalJSON() ([]byte, error) { + if src.ArrayOfString != nil { + return json.Marshal(&src.ArrayOfString) + } + + if src.String != nil { + return json.Marshal(&src.String) + } + + return nil, nil // no data in oneOf schemas +} + +// Get the actual instance +func (obj *PropertyValuesToFilter) GetActualInstance() (interface{}) { + if obj == nil { + return nil + } + if obj.ArrayOfString != nil { + return obj.ArrayOfString + } + + if obj.String != nil { + return obj.String + } + + // all schemas are nil + return nil +} + +// Get the actual instance value +func (obj PropertyValuesToFilter) GetActualInstanceValue() (interface{}) { + if obj.ArrayOfString != nil { + return *obj.ArrayOfString + } + + if obj.String != nil { + return *obj.String + } + + // all schemas are nil + return nil +} + +type NullablePropertyValuesToFilter struct { + value *PropertyValuesToFilter + isSet bool +} + +func (v NullablePropertyValuesToFilter) Get() *PropertyValuesToFilter { + return v.value +} + +func (v *NullablePropertyValuesToFilter) Set(val *PropertyValuesToFilter) { + v.value = val + v.isSet = true +} + +func (v NullablePropertyValuesToFilter) IsSet() bool { + return v.isSet +} + +func (v *NullablePropertyValuesToFilter) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullablePropertyValuesToFilter(val *PropertyValuesToFilter) *NullablePropertyValuesToFilter { + return &NullablePropertyValuesToFilter{value: val, isSet: true} +} + +func (v NullablePropertyValuesToFilter) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullablePropertyValuesToFilter) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_retrieve_navigator_id_404_response.go b/navigator/model_retrieve_navigator_id_404_response.go new file mode 100644 index 0000000..311a3ff --- /dev/null +++ b/navigator/model_retrieve_navigator_id_404_response.go @@ -0,0 +1,164 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the RetrieveNavigatorID404Response type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &RetrieveNavigatorID404Response{} + +// RetrieveNavigatorID404Response struct for RetrieveNavigatorID404Response +type RetrieveNavigatorID404Response struct { + // HTTP response code + Code *int32 `json:"code,omitempty"` + // Error explanation + Message *string `json:"message,omitempty"` +} + +// NewRetrieveNavigatorID404Response instantiates a new RetrieveNavigatorID404Response object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewRetrieveNavigatorID404Response() *RetrieveNavigatorID404Response { + this := RetrieveNavigatorID404Response{} + return &this +} + +// NewRetrieveNavigatorID404ResponseWithDefaults instantiates a new RetrieveNavigatorID404Response object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewRetrieveNavigatorID404ResponseWithDefaults() *RetrieveNavigatorID404Response { + this := RetrieveNavigatorID404Response{} + return &this +} + +// GetCode returns the Code field value if set, zero value otherwise. +func (o *RetrieveNavigatorID404Response) GetCode() int32 { + if o == nil || IsNil(o.Code) { + var ret int32 + return ret + } + return *o.Code +} + +// GetCodeOk returns a tuple with the Code field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RetrieveNavigatorID404Response) GetCodeOk() (*int32, bool) { + if o == nil || IsNil(o.Code) { + return nil, false + } + return o.Code, true +} + +// HasCode returns a boolean if a field has been set. +func (o *RetrieveNavigatorID404Response) HasCode() bool { + if o != nil && !IsNil(o.Code) { + return true + } + + return false +} + +// SetCode gets a reference to the given int32 and assigns it to the Code field. +func (o *RetrieveNavigatorID404Response) SetCode(v int32) { + o.Code = &v +} + +// GetMessage returns the Message field value if set, zero value otherwise. +func (o *RetrieveNavigatorID404Response) GetMessage() string { + if o == nil || IsNil(o.Message) { + var ret string + return ret + } + return *o.Message +} + +// GetMessageOk returns a tuple with the Message field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *RetrieveNavigatorID404Response) GetMessageOk() (*string, bool) { + if o == nil || IsNil(o.Message) { + return nil, false + } + return o.Message, true +} + +// HasMessage returns a boolean if a field has been set. +func (o *RetrieveNavigatorID404Response) HasMessage() bool { + if o != nil && !IsNil(o.Message) { + return true + } + + return false +} + +// SetMessage gets a reference to the given string and assigns it to the Message field. +func (o *RetrieveNavigatorID404Response) SetMessage(v string) { + o.Message = &v +} + +func (o RetrieveNavigatorID404Response) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o RetrieveNavigatorID404Response) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Code) { + toSerialize["code"] = o.Code + } + if !IsNil(o.Message) { + toSerialize["message"] = o.Message + } + return toSerialize, nil +} + +type NullableRetrieveNavigatorID404Response struct { + value *RetrieveNavigatorID404Response + isSet bool +} + +func (v NullableRetrieveNavigatorID404Response) Get() *RetrieveNavigatorID404Response { + return v.value +} + +func (v *NullableRetrieveNavigatorID404Response) Set(val *RetrieveNavigatorID404Response) { + v.value = val + v.isSet = true +} + +func (v NullableRetrieveNavigatorID404Response) IsSet() bool { + return v.isSet +} + +func (v *NullableRetrieveNavigatorID404Response) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableRetrieveNavigatorID404Response(val *RetrieveNavigatorID404Response) *NullableRetrieveNavigatorID404Response { + return &NullableRetrieveNavigatorID404Response{value: val, isSet: true} +} + +func (v NullableRetrieveNavigatorID404Response) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableRetrieveNavigatorID404Response) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_sets_table_options.go b/navigator/model_sets_table_options.go new file mode 100644 index 0000000..f9d8e45 --- /dev/null +++ b/navigator/model_sets_table_options.go @@ -0,0 +1,127 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the SetsTableOptions type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SetsTableOptions{} + +// SetsTableOptions Data table options +type SetsTableOptions struct { + // Settings for chart table + Fields []ListOfTableSettingsForPropertiesInTheChartInner `json:"fields,omitempty"` +} + +// NewSetsTableOptions instantiates a new SetsTableOptions object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSetsTableOptions() *SetsTableOptions { + this := SetsTableOptions{} + return &this +} + +// NewSetsTableOptionsWithDefaults instantiates a new SetsTableOptions object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSetsTableOptionsWithDefaults() *SetsTableOptions { + this := SetsTableOptions{} + return &this +} + +// GetFields returns the Fields field value if set, zero value otherwise. +func (o *SetsTableOptions) GetFields() []ListOfTableSettingsForPropertiesInTheChartInner { + if o == nil || IsNil(o.Fields) { + var ret []ListOfTableSettingsForPropertiesInTheChartInner + return ret + } + return o.Fields +} + +// GetFieldsOk returns a tuple with the Fields field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SetsTableOptions) GetFieldsOk() ([]ListOfTableSettingsForPropertiesInTheChartInner, bool) { + if o == nil || IsNil(o.Fields) { + return nil, false + } + return o.Fields, true +} + +// HasFields returns a boolean if a field has been set. +func (o *SetsTableOptions) HasFields() bool { + if o != nil && !IsNil(o.Fields) { + return true + } + + return false +} + +// SetFields gets a reference to the given []ListOfTableSettingsForPropertiesInTheChartInner and assigns it to the Fields field. +func (o *SetsTableOptions) SetFields(v []ListOfTableSettingsForPropertiesInTheChartInner) { + o.Fields = v +} + +func (o SetsTableOptions) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SetsTableOptions) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Fields) { + toSerialize["fields"] = o.Fields + } + return toSerialize, nil +} + +type NullableSetsTableOptions struct { + value *SetsTableOptions + isSet bool +} + +func (v NullableSetsTableOptions) Get() *SetsTableOptions { + return v.value +} + +func (v *NullableSetsTableOptions) Set(val *SetsTableOptions) { + v.value = val + v.isSet = true +} + +func (v NullableSetsTableOptions) IsSet() bool { + return v.isSet +} + +func (v *NullableSetsTableOptions) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSetsTableOptions(val *SetsTableOptions) *NullableSetsTableOptions { + return &NullableSetsTableOptions{value: val, isSet: true} +} + +func (v NullableSetsTableOptions) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSetsTableOptions) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_simple_dashboard_request_body_chart_object.go b/navigator/model_simple_dashboard_request_body_chart_object.go new file mode 100644 index 0000000..bab4f88 --- /dev/null +++ b/navigator/model_simple_dashboard_request_body_chart_object.go @@ -0,0 +1,386 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the SimpleDashboardRequestBodyChartObject type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SimpleDashboardRequestBodyChartObject{} + +// SimpleDashboardRequestBodyChartObject Simple dashboard request chart object +type SimpleDashboardRequestBodyChartObject struct { + // Metadata object + CustomProperties map[string]interface{} `json:"customProperties,omitempty"` + // Chart description + Description *string `json:"description,omitempty"` + // ID of an existing chart + ChartId interface{} `json:"chartId,omitempty"` + // Chart name + Name *string `json:"name,omitempty"` + Options *ChartOptions `json:"options,omitempty"` + // For internal use only. + PackageSpecifications *string `json:"packageSpecifications,omitempty"` + // SignalFlow program for chart data + ProgramText *string `json:"programText,omitempty"` + // Tags for chart + Tags []string `json:"tags,omitempty"` +} + +// NewSimpleDashboardRequestBodyChartObject instantiates a new SimpleDashboardRequestBodyChartObject object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSimpleDashboardRequestBodyChartObject() *SimpleDashboardRequestBodyChartObject { + this := SimpleDashboardRequestBodyChartObject{} + return &this +} + +// NewSimpleDashboardRequestBodyChartObjectWithDefaults instantiates a new SimpleDashboardRequestBodyChartObject object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSimpleDashboardRequestBodyChartObjectWithDefaults() *SimpleDashboardRequestBodyChartObject { + this := SimpleDashboardRequestBodyChartObject{} + return &this +} + +// GetCustomProperties returns the CustomProperties field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetCustomProperties() map[string]interface{} { + if o == nil || IsNil(o.CustomProperties) { + var ret map[string]interface{} + return ret + } + return o.CustomProperties +} + +// GetCustomPropertiesOk returns a tuple with the CustomProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetCustomPropertiesOk() (map[string]interface{}, bool) { + if o == nil || IsNil(o.CustomProperties) { + return map[string]interface{}{}, false + } + return o.CustomProperties, true +} + +// HasCustomProperties returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasCustomProperties() bool { + if o != nil && !IsNil(o.CustomProperties) { + return true + } + + return false +} + +// SetCustomProperties gets a reference to the given map[string]interface{} and assigns it to the CustomProperties field. +func (o *SimpleDashboardRequestBodyChartObject) SetCustomProperties(v map[string]interface{}) { + o.CustomProperties = v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetDescription() string { + if o == nil || IsNil(o.Description) { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetDescriptionOk() (*string, bool) { + if o == nil || IsNil(o.Description) { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasDescription() bool { + if o != nil && !IsNil(o.Description) { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *SimpleDashboardRequestBodyChartObject) SetDescription(v string) { + o.Description = &v +} + +// GetChartId returns the ChartId field value if set, zero value otherwise (both if not set or set to explicit null). +func (o *SimpleDashboardRequestBodyChartObject) GetChartId() interface{} { + if o == nil { + var ret interface{} + return ret + } + return o.ChartId +} + +// GetChartIdOk returns a tuple with the ChartId field value if set, nil otherwise +// and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *SimpleDashboardRequestBodyChartObject) GetChartIdOk() (*interface{}, bool) { + if o == nil || IsNil(o.ChartId) { + return nil, false + } + return &o.ChartId, true +} + +// HasChartId returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasChartId() bool { + if o != nil && !IsNil(o.ChartId) { + return true + } + + return false +} + +// SetChartId gets a reference to the given interface{} and assigns it to the ChartId field. +func (o *SimpleDashboardRequestBodyChartObject) SetChartId(v interface{}) { + o.ChartId = v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *SimpleDashboardRequestBodyChartObject) SetName(v string) { + o.Name = &v +} + +// GetOptions returns the Options field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetOptions() ChartOptions { + if o == nil || IsNil(o.Options) { + var ret ChartOptions + return ret + } + return *o.Options +} + +// GetOptionsOk returns a tuple with the Options field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetOptionsOk() (*ChartOptions, bool) { + if o == nil || IsNil(o.Options) { + return nil, false + } + return o.Options, true +} + +// HasOptions returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasOptions() bool { + if o != nil && !IsNil(o.Options) { + return true + } + + return false +} + +// SetOptions gets a reference to the given ChartOptions and assigns it to the Options field. +func (o *SimpleDashboardRequestBodyChartObject) SetOptions(v ChartOptions) { + o.Options = &v +} + +// GetPackageSpecifications returns the PackageSpecifications field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetPackageSpecifications() string { + if o == nil || IsNil(o.PackageSpecifications) { + var ret string + return ret + } + return *o.PackageSpecifications +} + +// GetPackageSpecificationsOk returns a tuple with the PackageSpecifications field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetPackageSpecificationsOk() (*string, bool) { + if o == nil || IsNil(o.PackageSpecifications) { + return nil, false + } + return o.PackageSpecifications, true +} + +// HasPackageSpecifications returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasPackageSpecifications() bool { + if o != nil && !IsNil(o.PackageSpecifications) { + return true + } + + return false +} + +// SetPackageSpecifications gets a reference to the given string and assigns it to the PackageSpecifications field. +func (o *SimpleDashboardRequestBodyChartObject) SetPackageSpecifications(v string) { + o.PackageSpecifications = &v +} + +// GetProgramText returns the ProgramText field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetProgramText() string { + if o == nil || IsNil(o.ProgramText) { + var ret string + return ret + } + return *o.ProgramText +} + +// GetProgramTextOk returns a tuple with the ProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.ProgramText) { + return nil, false + } + return o.ProgramText, true +} + +// HasProgramText returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasProgramText() bool { + if o != nil && !IsNil(o.ProgramText) { + return true + } + + return false +} + +// SetProgramText gets a reference to the given string and assigns it to the ProgramText field. +func (o *SimpleDashboardRequestBodyChartObject) SetProgramText(v string) { + o.ProgramText = &v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *SimpleDashboardRequestBodyChartObject) GetTags() []string { + if o == nil || IsNil(o.Tags) { + var ret []string + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardRequestBodyChartObject) GetTagsOk() ([]string, bool) { + if o == nil || IsNil(o.Tags) { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *SimpleDashboardRequestBodyChartObject) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *SimpleDashboardRequestBodyChartObject) SetTags(v []string) { + o.Tags = v +} + +func (o SimpleDashboardRequestBodyChartObject) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SimpleDashboardRequestBodyChartObject) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.CustomProperties) { + toSerialize["customProperties"] = o.CustomProperties + } + if !IsNil(o.Description) { + toSerialize["description"] = o.Description + } + if o.ChartId != nil { + toSerialize["chartId"] = o.ChartId + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.Options) { + toSerialize["options"] = o.Options + } + if !IsNil(o.PackageSpecifications) { + toSerialize["packageSpecifications"] = o.PackageSpecifications + } + if !IsNil(o.ProgramText) { + toSerialize["programText"] = o.ProgramText + } + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + return toSerialize, nil +} + +type NullableSimpleDashboardRequestBodyChartObject struct { + value *SimpleDashboardRequestBodyChartObject + isSet bool +} + +func (v NullableSimpleDashboardRequestBodyChartObject) Get() *SimpleDashboardRequestBodyChartObject { + return v.value +} + +func (v *NullableSimpleDashboardRequestBodyChartObject) Set(val *SimpleDashboardRequestBodyChartObject) { + v.value = val + v.isSet = true +} + +func (v NullableSimpleDashboardRequestBodyChartObject) IsSet() bool { + return v.isSet +} + +func (v *NullableSimpleDashboardRequestBodyChartObject) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSimpleDashboardRequestBodyChartObject(val *SimpleDashboardRequestBodyChartObject) *NullableSimpleDashboardRequestBodyChartObject { + return &NullableSimpleDashboardRequestBodyChartObject{value: val, isSet: true} +} + +func (v NullableSimpleDashboardRequestBodyChartObject) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSimpleDashboardRequestBodyChartObject) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_simple_dashboard_response_body.go b/navigator/model_simple_dashboard_response_body.go new file mode 100644 index 0000000..dc58ffa --- /dev/null +++ b/navigator/model_simple_dashboard_response_body.go @@ -0,0 +1,721 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the SimpleDashboardResponseBody type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SimpleDashboardResponseBody{} + +// SimpleDashboardResponseBody Dashboard object returned by `POST /v2/dashboard/simple` +type SimpleDashboardResponseBody struct { + ChartDensity *DashboardChartDensity `json:"chartDensity,omitempty"` + // List of chart IDs and settings for the charts associated with this dashboard + Charts []DashboardChartSettingsObject `json:"charts,omitempty"` + // Dashboard creation timestamp, in *nix time in milliseconds. Set by system. + Created *int64 `json:"created,omitempty"` + // User ID of dashboard creator. Set by system. + Creator *string `json:"creator,omitempty"` + // not used + CustomProperties *string `json:"customProperties,omitempty"` + // Dashboard description + Description *string `json:"description,omitempty"` + // Reserved for system use + DiscoveryOptions map[string]interface{} `json:"discoveryOptions,omitempty"` + // List of event overlays you can apply to charts in this dashboard + EventOverlays []DashboardEventOverlayFilter `json:"eventOverlays,omitempty"` + Filters *DashboardChartsFilters `json:"filters,omitempty"` + // ID of an existing dashboard group that you want to contain this dashboard + GroupId *string `json:"groupId,omitempty"` + // The ID of the dashboard. Set by system. + Id *string `json:"id,omitempty"` + // Dashboard last updated time, in *nix format in milliseconds. Set by system. + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of user who last updated the dashboard. Set by system. + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // In milliseconds, the time to wait for data points before ignoring them + MaxDelayOverride *int32 `json:"maxDelayOverride,omitempty"` + // Dashboard name in the user interface + Name *string `json:"name,omitempty"` + // List of active event overlays for charts in this dashboard + SelectedEventOverlays []DashboardChartEventOverlay `json:"selectedEventOverlays,omitempty"` + // not used + Tags []string `json:"tags,omitempty"` +} + +// NewSimpleDashboardResponseBody instantiates a new SimpleDashboardResponseBody object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSimpleDashboardResponseBody() *SimpleDashboardResponseBody { + this := SimpleDashboardResponseBody{} + var chartDensity DashboardChartDensity = DEFAULT + this.ChartDensity = &chartDensity + return &this +} + +// NewSimpleDashboardResponseBodyWithDefaults instantiates a new SimpleDashboardResponseBody object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSimpleDashboardResponseBodyWithDefaults() *SimpleDashboardResponseBody { + this := SimpleDashboardResponseBody{} + var chartDensity DashboardChartDensity = DEFAULT + this.ChartDensity = &chartDensity + return &this +} + +// GetChartDensity returns the ChartDensity field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetChartDensity() DashboardChartDensity { + if o == nil || IsNil(o.ChartDensity) { + var ret DashboardChartDensity + return ret + } + return *o.ChartDensity +} + +// GetChartDensityOk returns a tuple with the ChartDensity field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetChartDensityOk() (*DashboardChartDensity, bool) { + if o == nil || IsNil(o.ChartDensity) { + return nil, false + } + return o.ChartDensity, true +} + +// HasChartDensity returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasChartDensity() bool { + if o != nil && !IsNil(o.ChartDensity) { + return true + } + + return false +} + +// SetChartDensity gets a reference to the given DashboardChartDensity and assigns it to the ChartDensity field. +func (o *SimpleDashboardResponseBody) SetChartDensity(v DashboardChartDensity) { + o.ChartDensity = &v +} + +// GetCharts returns the Charts field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetCharts() []DashboardChartSettingsObject { + if o == nil || IsNil(o.Charts) { + var ret []DashboardChartSettingsObject + return ret + } + return o.Charts +} + +// GetChartsOk returns a tuple with the Charts field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetChartsOk() ([]DashboardChartSettingsObject, bool) { + if o == nil || IsNil(o.Charts) { + return nil, false + } + return o.Charts, true +} + +// HasCharts returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasCharts() bool { + if o != nil && !IsNil(o.Charts) { + return true + } + + return false +} + +// SetCharts gets a reference to the given []DashboardChartSettingsObject and assigns it to the Charts field. +func (o *SimpleDashboardResponseBody) SetCharts(v []DashboardChartSettingsObject) { + o.Charts = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *SimpleDashboardResponseBody) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *SimpleDashboardResponseBody) SetCreator(v string) { + o.Creator = &v +} + +// GetCustomProperties returns the CustomProperties field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetCustomProperties() string { + if o == nil || IsNil(o.CustomProperties) { + var ret string + return ret + } + return *o.CustomProperties +} + +// GetCustomPropertiesOk returns a tuple with the CustomProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetCustomPropertiesOk() (*string, bool) { + if o == nil || IsNil(o.CustomProperties) { + return nil, false + } + return o.CustomProperties, true +} + +// HasCustomProperties returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasCustomProperties() bool { + if o != nil && !IsNil(o.CustomProperties) { + return true + } + + return false +} + +// SetCustomProperties gets a reference to the given string and assigns it to the CustomProperties field. +func (o *SimpleDashboardResponseBody) SetCustomProperties(v string) { + o.CustomProperties = &v +} + +// GetDescription returns the Description field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetDescription() string { + if o == nil || IsNil(o.Description) { + var ret string + return ret + } + return *o.Description +} + +// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetDescriptionOk() (*string, bool) { + if o == nil || IsNil(o.Description) { + return nil, false + } + return o.Description, true +} + +// HasDescription returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasDescription() bool { + if o != nil && !IsNil(o.Description) { + return true + } + + return false +} + +// SetDescription gets a reference to the given string and assigns it to the Description field. +func (o *SimpleDashboardResponseBody) SetDescription(v string) { + o.Description = &v +} + +// GetDiscoveryOptions returns the DiscoveryOptions field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetDiscoveryOptions() map[string]interface{} { + if o == nil || IsNil(o.DiscoveryOptions) { + var ret map[string]interface{} + return ret + } + return o.DiscoveryOptions +} + +// GetDiscoveryOptionsOk returns a tuple with the DiscoveryOptions field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetDiscoveryOptionsOk() (map[string]interface{}, bool) { + if o == nil || IsNil(o.DiscoveryOptions) { + return map[string]interface{}{}, false + } + return o.DiscoveryOptions, true +} + +// HasDiscoveryOptions returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasDiscoveryOptions() bool { + if o != nil && !IsNil(o.DiscoveryOptions) { + return true + } + + return false +} + +// SetDiscoveryOptions gets a reference to the given map[string]interface{} and assigns it to the DiscoveryOptions field. +func (o *SimpleDashboardResponseBody) SetDiscoveryOptions(v map[string]interface{}) { + o.DiscoveryOptions = v +} + +// GetEventOverlays returns the EventOverlays field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetEventOverlays() []DashboardEventOverlayFilter { + if o == nil || IsNil(o.EventOverlays) { + var ret []DashboardEventOverlayFilter + return ret + } + return o.EventOverlays +} + +// GetEventOverlaysOk returns a tuple with the EventOverlays field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetEventOverlaysOk() ([]DashboardEventOverlayFilter, bool) { + if o == nil || IsNil(o.EventOverlays) { + return nil, false + } + return o.EventOverlays, true +} + +// HasEventOverlays returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasEventOverlays() bool { + if o != nil && !IsNil(o.EventOverlays) { + return true + } + + return false +} + +// SetEventOverlays gets a reference to the given []DashboardEventOverlayFilter and assigns it to the EventOverlays field. +func (o *SimpleDashboardResponseBody) SetEventOverlays(v []DashboardEventOverlayFilter) { + o.EventOverlays = v +} + +// GetFilters returns the Filters field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetFilters() DashboardChartsFilters { + if o == nil || IsNil(o.Filters) { + var ret DashboardChartsFilters + return ret + } + return *o.Filters +} + +// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetFiltersOk() (*DashboardChartsFilters, bool) { + if o == nil || IsNil(o.Filters) { + return nil, false + } + return o.Filters, true +} + +// HasFilters returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasFilters() bool { + if o != nil && !IsNil(o.Filters) { + return true + } + + return false +} + +// SetFilters gets a reference to the given DashboardChartsFilters and assigns it to the Filters field. +func (o *SimpleDashboardResponseBody) SetFilters(v DashboardChartsFilters) { + o.Filters = &v +} + +// GetGroupId returns the GroupId field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetGroupId() string { + if o == nil || IsNil(o.GroupId) { + var ret string + return ret + } + return *o.GroupId +} + +// GetGroupIdOk returns a tuple with the GroupId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetGroupIdOk() (*string, bool) { + if o == nil || IsNil(o.GroupId) { + return nil, false + } + return o.GroupId, true +} + +// HasGroupId returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasGroupId() bool { + if o != nil && !IsNil(o.GroupId) { + return true + } + + return false +} + +// SetGroupId gets a reference to the given string and assigns it to the GroupId field. +func (o *SimpleDashboardResponseBody) SetGroupId(v string) { + o.GroupId = &v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *SimpleDashboardResponseBody) SetId(v string) { + o.Id = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *SimpleDashboardResponseBody) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *SimpleDashboardResponseBody) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetMaxDelayOverride returns the MaxDelayOverride field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetMaxDelayOverride() int32 { + if o == nil || IsNil(o.MaxDelayOverride) { + var ret int32 + return ret + } + return *o.MaxDelayOverride +} + +// GetMaxDelayOverrideOk returns a tuple with the MaxDelayOverride field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetMaxDelayOverrideOk() (*int32, bool) { + if o == nil || IsNil(o.MaxDelayOverride) { + return nil, false + } + return o.MaxDelayOverride, true +} + +// HasMaxDelayOverride returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasMaxDelayOverride() bool { + if o != nil && !IsNil(o.MaxDelayOverride) { + return true + } + + return false +} + +// SetMaxDelayOverride gets a reference to the given int32 and assigns it to the MaxDelayOverride field. +func (o *SimpleDashboardResponseBody) SetMaxDelayOverride(v int32) { + o.MaxDelayOverride = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *SimpleDashboardResponseBody) SetName(v string) { + o.Name = &v +} + +// GetSelectedEventOverlays returns the SelectedEventOverlays field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetSelectedEventOverlays() []DashboardChartEventOverlay { + if o == nil || IsNil(o.SelectedEventOverlays) { + var ret []DashboardChartEventOverlay + return ret + } + return o.SelectedEventOverlays +} + +// GetSelectedEventOverlaysOk returns a tuple with the SelectedEventOverlays field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetSelectedEventOverlaysOk() ([]DashboardChartEventOverlay, bool) { + if o == nil || IsNil(o.SelectedEventOverlays) { + return nil, false + } + return o.SelectedEventOverlays, true +} + +// HasSelectedEventOverlays returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasSelectedEventOverlays() bool { + if o != nil && !IsNil(o.SelectedEventOverlays) { + return true + } + + return false +} + +// SetSelectedEventOverlays gets a reference to the given []DashboardChartEventOverlay and assigns it to the SelectedEventOverlays field. +func (o *SimpleDashboardResponseBody) SetSelectedEventOverlays(v []DashboardChartEventOverlay) { + o.SelectedEventOverlays = v +} + +// GetTags returns the Tags field value if set, zero value otherwise. +func (o *SimpleDashboardResponseBody) GetTags() []string { + if o == nil || IsNil(o.Tags) { + var ret []string + return ret + } + return o.Tags +} + +// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SimpleDashboardResponseBody) GetTagsOk() ([]string, bool) { + if o == nil || IsNil(o.Tags) { + return nil, false + } + return o.Tags, true +} + +// HasTags returns a boolean if a field has been set. +func (o *SimpleDashboardResponseBody) HasTags() bool { + if o != nil && !IsNil(o.Tags) { + return true + } + + return false +} + +// SetTags gets a reference to the given []string and assigns it to the Tags field. +func (o *SimpleDashboardResponseBody) SetTags(v []string) { + o.Tags = v +} + +func (o SimpleDashboardResponseBody) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SimpleDashboardResponseBody) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ChartDensity) { + toSerialize["chartDensity"] = o.ChartDensity + } + if !IsNil(o.Charts) { + toSerialize["charts"] = o.Charts + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.CustomProperties) { + toSerialize["customProperties"] = o.CustomProperties + } + if !IsNil(o.Description) { + toSerialize["description"] = o.Description + } + if !IsNil(o.DiscoveryOptions) { + toSerialize["discoveryOptions"] = o.DiscoveryOptions + } + if !IsNil(o.EventOverlays) { + toSerialize["eventOverlays"] = o.EventOverlays + } + if !IsNil(o.Filters) { + toSerialize["filters"] = o.Filters + } + if !IsNil(o.GroupId) { + toSerialize["groupId"] = o.GroupId + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.MaxDelayOverride) { + toSerialize["maxDelayOverride"] = o.MaxDelayOverride + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.SelectedEventOverlays) { + toSerialize["selectedEventOverlays"] = o.SelectedEventOverlays + } + if !IsNil(o.Tags) { + toSerialize["tags"] = o.Tags + } + return toSerialize, nil +} + +type NullableSimpleDashboardResponseBody struct { + value *SimpleDashboardResponseBody + isSet bool +} + +func (v NullableSimpleDashboardResponseBody) Get() *SimpleDashboardResponseBody { + return v.value +} + +func (v *NullableSimpleDashboardResponseBody) Set(val *SimpleDashboardResponseBody) { + v.value = val + v.isSet = true +} + +func (v NullableSimpleDashboardResponseBody) IsSet() bool { + return v.isSet +} + +func (v *NullableSimpleDashboardResponseBody) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSimpleDashboardResponseBody(val *SimpleDashboardResponseBody) *NullableSimpleDashboardResponseBody { + return &NullableSimpleDashboardResponseBody{value: val, isSet: true} +} + +func (v NullableSimpleDashboardResponseBody) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSimpleDashboardResponseBody) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_specifies_color_range_options_for_coloring_a_heatmap_chart.go b/navigator/model_specifies_color_range_options_for_coloring_a_heatmap_chart.go new file mode 100644 index 0000000..5ff4c96 --- /dev/null +++ b/navigator/model_specifies_color_range_options_for_coloring_a_heatmap_chart.go @@ -0,0 +1,201 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the SpecifiesColorRangeOptionsForColoringAHeatmapChart type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SpecifiesColorRangeOptionsForColoringAHeatmapChart{} + +// SpecifiesColorRangeOptionsForColoringAHeatmapChart Heatmap color range options +type SpecifiesColorRangeOptionsForColoringAHeatmapChart struct { + // Heatmap starting color + Color *string `json:"color,omitempty"` + // Color of largest data value + Max *string `json:"max,omitempty"` + // Color of smallest data value + Min *string `json:"min,omitempty"` +} + +// NewSpecifiesColorRangeOptionsForColoringAHeatmapChart instantiates a new SpecifiesColorRangeOptionsForColoringAHeatmapChart object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSpecifiesColorRangeOptionsForColoringAHeatmapChart() *SpecifiesColorRangeOptionsForColoringAHeatmapChart { + this := SpecifiesColorRangeOptionsForColoringAHeatmapChart{} + return &this +} + +// NewSpecifiesColorRangeOptionsForColoringAHeatmapChartWithDefaults instantiates a new SpecifiesColorRangeOptionsForColoringAHeatmapChart object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSpecifiesColorRangeOptionsForColoringAHeatmapChartWithDefaults() *SpecifiesColorRangeOptionsForColoringAHeatmapChart { + this := SpecifiesColorRangeOptionsForColoringAHeatmapChart{} + return &this +} + +// GetColor returns the Color field value if set, zero value otherwise. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetColor() string { + if o == nil || IsNil(o.Color) { + var ret string + return ret + } + return *o.Color +} + +// GetColorOk returns a tuple with the Color field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetColorOk() (*string, bool) { + if o == nil || IsNil(o.Color) { + return nil, false + } + return o.Color, true +} + +// HasColor returns a boolean if a field has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) HasColor() bool { + if o != nil && !IsNil(o.Color) { + return true + } + + return false +} + +// SetColor gets a reference to the given string and assigns it to the Color field. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) SetColor(v string) { + o.Color = &v +} + +// GetMax returns the Max field value if set, zero value otherwise. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetMax() string { + if o == nil || IsNil(o.Max) { + var ret string + return ret + } + return *o.Max +} + +// GetMaxOk returns a tuple with the Max field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetMaxOk() (*string, bool) { + if o == nil || IsNil(o.Max) { + return nil, false + } + return o.Max, true +} + +// HasMax returns a boolean if a field has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) HasMax() bool { + if o != nil && !IsNil(o.Max) { + return true + } + + return false +} + +// SetMax gets a reference to the given string and assigns it to the Max field. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) SetMax(v string) { + o.Max = &v +} + +// GetMin returns the Min field value if set, zero value otherwise. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetMin() string { + if o == nil || IsNil(o.Min) { + var ret string + return ret + } + return *o.Min +} + +// GetMinOk returns a tuple with the Min field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) GetMinOk() (*string, bool) { + if o == nil || IsNil(o.Min) { + return nil, false + } + return o.Min, true +} + +// HasMin returns a boolean if a field has been set. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) HasMin() bool { + if o != nil && !IsNil(o.Min) { + return true + } + + return false +} + +// SetMin gets a reference to the given string and assigns it to the Min field. +func (o *SpecifiesColorRangeOptionsForColoringAHeatmapChart) SetMin(v string) { + o.Min = &v +} + +func (o SpecifiesColorRangeOptionsForColoringAHeatmapChart) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SpecifiesColorRangeOptionsForColoringAHeatmapChart) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Color) { + toSerialize["color"] = o.Color + } + if !IsNil(o.Max) { + toSerialize["max"] = o.Max + } + if !IsNil(o.Min) { + toSerialize["min"] = o.Min + } + return toSerialize, nil +} + +type NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart struct { + value *SpecifiesColorRangeOptionsForColoringAHeatmapChart + isSet bool +} + +func (v NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) Get() *SpecifiesColorRangeOptionsForColoringAHeatmapChart { + return v.value +} + +func (v *NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) Set(val *SpecifiesColorRangeOptionsForColoringAHeatmapChart) { + v.value = val + v.isSet = true +} + +func (v NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) IsSet() bool { + return v.isSet +} + +func (v *NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSpecifiesColorRangeOptionsForColoringAHeatmapChart(val *SpecifiesColorRangeOptionsForColoringAHeatmapChart) *NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart { + return &NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart{value: val, isSet: true} +} + +func (v NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSpecifiesColorRangeOptionsForColoringAHeatmapChart) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_specifies_how_to_apply_the_range_of_specified_color_values_to_data_in_a_heatmap_chart_.go b/navigator/model_specifies_how_to_apply_the_range_of_specified_color_values_to_data_in_a_heatmap_chart_.go new file mode 100644 index 0000000..16c0df2 --- /dev/null +++ b/navigator/model_specifies_how_to_apply_the_range_of_specified_color_values_to_data_in_a_heatmap_chart_.go @@ -0,0 +1,168 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart{} + +// SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart Range limits for Heatmap color ranges +type SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart struct { + // Controls how colors apply to Heatmap values + Inverted *bool `json:"inverted,omitempty"` + // Data values that map to color gradient values + Thresholds []float32 `json:"thresholds,omitempty"` +} + +// NewSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart instantiates a new SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart() *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart { + this := SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart{} + var inverted bool = false + this.Inverted = &inverted + return &this +} + +// NewSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChartWithDefaults instantiates a new SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChartWithDefaults() *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart { + this := SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart{} + var inverted bool = false + this.Inverted = &inverted + return &this +} + +// GetInverted returns the Inverted field value if set, zero value otherwise. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) GetInverted() bool { + if o == nil || IsNil(o.Inverted) { + var ret bool + return ret + } + return *o.Inverted +} + +// GetInvertedOk returns a tuple with the Inverted field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) GetInvertedOk() (*bool, bool) { + if o == nil || IsNil(o.Inverted) { + return nil, false + } + return o.Inverted, true +} + +// HasInverted returns a boolean if a field has been set. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) HasInverted() bool { + if o != nil && !IsNil(o.Inverted) { + return true + } + + return false +} + +// SetInverted gets a reference to the given bool and assigns it to the Inverted field. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) SetInverted(v bool) { + o.Inverted = &v +} + +// GetThresholds returns the Thresholds field value if set, zero value otherwise. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) GetThresholds() []float32 { + if o == nil || IsNil(o.Thresholds) { + var ret []float32 + return ret + } + return o.Thresholds +} + +// GetThresholdsOk returns a tuple with the Thresholds field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) GetThresholdsOk() ([]float32, bool) { + if o == nil || IsNil(o.Thresholds) { + return nil, false + } + return o.Thresholds, true +} + +// HasThresholds returns a boolean if a field has been set. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) HasThresholds() bool { + if o != nil && !IsNil(o.Thresholds) { + return true + } + + return false +} + +// SetThresholds gets a reference to the given []float32 and assigns it to the Thresholds field. +func (o *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) SetThresholds(v []float32) { + o.Thresholds = v +} + +func (o SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Inverted) { + toSerialize["inverted"] = o.Inverted + } + if !IsNil(o.Thresholds) { + toSerialize["thresholds"] = o.Thresholds + } + return toSerialize, nil +} + +type NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart struct { + value *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart + isSet bool +} + +func (v NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) Get() *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart { + return v.value +} + +func (v *NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) Set(val *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) { + v.value = val + v.isSet = true +} + +func (v NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) IsSet() bool { + return v.isSet +} + +func (v *NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart(val *SpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) *NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart { + return &NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart{value: val, isSet: true} +} + +func (v NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableSpecifiesHowToApplyTheRangeOfSpecifiedColorValuesToDataInAHeatmapChart) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_tooltip_key.go b/navigator/model_tooltip_key.go new file mode 100644 index 0000000..3a3ec2f --- /dev/null +++ b/navigator/model_tooltip_key.go @@ -0,0 +1,225 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" + "bytes" + "fmt" +) + +// checks if the TooltipKey type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &TooltipKey{} + +// TooltipKey Tooltip key properties +type TooltipKey struct { + // Tooltip key display name + DisplayName string `json:"displayName"` + // Tooltip key format + Format *string `json:"format,omitempty"` + // Custom property or dimension + Property string `json:"property"` +} + +type _TooltipKey TooltipKey + +// NewTooltipKey instantiates a new TooltipKey object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewTooltipKey(displayName string, property string) *TooltipKey { + this := TooltipKey{} + this.DisplayName = displayName + this.Property = property + return &this +} + +// NewTooltipKeyWithDefaults instantiates a new TooltipKey object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewTooltipKeyWithDefaults() *TooltipKey { + this := TooltipKey{} + return &this +} + +// GetDisplayName returns the DisplayName field value +func (o *TooltipKey) GetDisplayName() string { + if o == nil { + var ret string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *TooltipKey) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *TooltipKey) SetDisplayName(v string) { + o.DisplayName = v +} + +// GetFormat returns the Format field value if set, zero value otherwise. +func (o *TooltipKey) GetFormat() string { + if o == nil || IsNil(o.Format) { + var ret string + return ret + } + return *o.Format +} + +// GetFormatOk returns a tuple with the Format field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *TooltipKey) GetFormatOk() (*string, bool) { + if o == nil || IsNil(o.Format) { + return nil, false + } + return o.Format, true +} + +// HasFormat returns a boolean if a field has been set. +func (o *TooltipKey) HasFormat() bool { + if o != nil && !IsNil(o.Format) { + return true + } + + return false +} + +// SetFormat gets a reference to the given string and assigns it to the Format field. +func (o *TooltipKey) SetFormat(v string) { + o.Format = &v +} + +// GetProperty returns the Property field value +func (o *TooltipKey) GetProperty() string { + if o == nil { + var ret string + return ret + } + + return o.Property +} + +// GetPropertyOk returns a tuple with the Property field value +// and a boolean to check if the value has been set. +func (o *TooltipKey) GetPropertyOk() (*string, bool) { + if o == nil { + return nil, false + } + return &o.Property, true +} + +// SetProperty sets field value +func (o *TooltipKey) SetProperty(v string) { + o.Property = v +} + +func (o TooltipKey) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o TooltipKey) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName + if !IsNil(o.Format) { + toSerialize["format"] = o.Format + } + toSerialize["property"] = o.Property + return toSerialize, nil +} + +func (o *TooltipKey) UnmarshalJSON(data []byte) (err error) { + // This validates that all required properties are included in the JSON object + // by unmarshalling the object into a generic map with string keys and checking + // that every required field exists as a key in the generic map. + requiredProperties := []string{ + "displayName", + "property", + } + + allProperties := make(map[string]interface{}) + + err = json.Unmarshal(data, &allProperties) + + if err != nil { + return err; + } + + for _, requiredProperty := range(requiredProperties) { + if _, exists := allProperties[requiredProperty]; !exists { + return fmt.Errorf("no value given for required property %v", requiredProperty) + } + } + + varTooltipKey := _TooltipKey{} + + decoder := json.NewDecoder(bytes.NewReader(data)) + decoder.DisallowUnknownFields() + err = decoder.Decode(&varTooltipKey) + + if err != nil { + return err + } + + *o = TooltipKey(varTooltipKey) + + return err +} + +type NullableTooltipKey struct { + value *TooltipKey + isSet bool +} + +func (v NullableTooltipKey) Get() *TooltipKey { + return v.value +} + +func (v *NullableTooltipKey) Set(val *TooltipKey) { + v.value = val + v.isSet = true +} + +func (v NullableTooltipKey) IsSet() bool { + return v.isSet +} + +func (v *NullableTooltipKey) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTooltipKey(val *TooltipKey) *NullableTooltipKey { + return &NullableTooltipKey{value: val, isSet: true} +} + +func (v NullableTooltipKey) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTooltipKey) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_update_navigator_request.go b/navigator/model_update_navigator_request.go new file mode 100644 index 0000000..516aa07 --- /dev/null +++ b/navigator/model_update_navigator_request.go @@ -0,0 +1,719 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the UpdateNavigatorRequest type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &UpdateNavigatorRequest{} + +// UpdateNavigatorRequest Properties you can overwrite in an Update Navigator request +type UpdateNavigatorRequest struct { + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Properties shared by all instances + RequiredProperties []string `json:"requiredProperties,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewUpdateNavigatorRequest instantiates a new UpdateNavigatorRequest object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNavigatorRequest() *UpdateNavigatorRequest { + this := UpdateNavigatorRequest{} + return &this +} + +// NewUpdateNavigatorRequestWithDefaults instantiates a new UpdateNavigatorRequest object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNavigatorRequestWithDefaults() *UpdateNavigatorRequest { + this := UpdateNavigatorRequest{} + return &this +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *UpdateNavigatorRequest) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *UpdateNavigatorRequest) SetCategories(v []Category) { + o.Categories = v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *UpdateNavigatorRequest) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *UpdateNavigatorRequest) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *UpdateNavigatorRequest) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *UpdateNavigatorRequest) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *UpdateNavigatorRequest) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *UpdateNavigatorRequest) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *UpdateNavigatorRequest) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *UpdateNavigatorRequest) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *UpdateNavigatorRequest) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *UpdateNavigatorRequest) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetRequiredProperties returns the RequiredProperties field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetRequiredProperties() []string { + if o == nil || IsNil(o.RequiredProperties) { + var ret []string + return ret + } + return o.RequiredProperties +} + +// GetRequiredPropertiesOk returns a tuple with the RequiredProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetRequiredPropertiesOk() ([]string, bool) { + if o == nil || IsNil(o.RequiredProperties) { + return nil, false + } + return o.RequiredProperties, true +} + +// HasRequiredProperties returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasRequiredProperties() bool { + if o != nil && !IsNil(o.RequiredProperties) { + return true + } + + return false +} + +// SetRequiredProperties gets a reference to the given []string and assigns it to the RequiredProperties field. +func (o *UpdateNavigatorRequest) SetRequiredProperties(v []string) { + o.RequiredProperties = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *UpdateNavigatorRequest) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *UpdateNavigatorRequest) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *UpdateNavigatorRequest) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *UpdateNavigatorRequest) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorRequest) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *UpdateNavigatorRequest) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *UpdateNavigatorRequest) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o UpdateNavigatorRequest) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o UpdateNavigatorRequest) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.RequiredProperties) { + toSerialize["requiredProperties"] = o.RequiredProperties + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableUpdateNavigatorRequest struct { + value *UpdateNavigatorRequest + isSet bool +} + +func (v NullableUpdateNavigatorRequest) Get() *UpdateNavigatorRequest { + return v.value +} + +func (v *NullableUpdateNavigatorRequest) Set(val *UpdateNavigatorRequest) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNavigatorRequest) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNavigatorRequest) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNavigatorRequest(val *UpdateNavigatorRequest) *NullableUpdateNavigatorRequest { + return &NullableUpdateNavigatorRequest{value: val, isSet: true} +} + +func (v NullableUpdateNavigatorRequest) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNavigatorRequest) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/model_update_navigator_response.go b/navigator/model_update_navigator_response.go new file mode 100644 index 0000000..447093a --- /dev/null +++ b/navigator/model_update_navigator_response.go @@ -0,0 +1,903 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "encoding/json" +) + +// checks if the UpdateNavigatorResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &UpdateNavigatorResponse{} + +// UpdateNavigatorResponse Response body returned by Update Navigator +type UpdateNavigatorResponse struct { + // Navigator alert query + AlertQuery *string `json:"alertQuery,omitempty"` + // Navigator categories list + Categories []Category `json:"categories,omitempty"` + // Navigator creation time + Created *int64 `json:"created,omitempty"` + // User ID of the user who created this navigator + Creator *string `json:"creator,omitempty"` + // Navigator default group by + DefaultGroupBy *string `json:"defaultGroupBy,omitempty"` + // Navigator display name + DisplayName *string `json:"displayName,omitempty"` + // Navigator metrics information + EntityMetrics []Metric `json:"entityMetrics,omitempty"` + // Navigator system ID + Id *string `json:"id,omitempty"` + // Navigator ID display name + IdDisplayName *string `json:"idDisplayName,omitempty"` + // Array of dashboard IDs to use for instance display. Specific to GET /navigator. + InstanceDashboards []string `json:"instanceDashboards,omitempty"` + // Instance description to display + InstanceDisplayText *string `json:"instanceDisplayText,omitempty"` + // Navigator instance label + InstanceLabel *string `json:"instanceLabel,omitempty"` + // Time at which the navigator was last updated + LastUpdated *int64 `json:"lastUpdated,omitempty"` + // ID of the user who last updated this navigator + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty"` + // List of columns in navigator + ListColumns []ListColumn `json:"listColumns,omitempty"` + OwnerScope *OwnerScope `json:"ownerScope,omitempty"` + // Template for ID construction + PropertyIdentifierTemplate *string `json:"propertyIdentifierTemplate,omitempty"` + // Properties shared by all instances + RequiredProperties []string `json:"requiredProperties,omitempty"` + // Navigator system type identifiers + SystemTypes []string `json:"systemTypes,omitempty"` + // Label for a summary metric + SummaryMetricLabel *string `json:"summaryMetricLabel,omitempty"` + // SignalFlow program for summary metric + SummaryMetricProgramText *string `json:"summaryMetricProgramText,omitempty"` + // A list of keys that appears in the tooltip + TooltipKeyList []TooltipKey `json:"tooltipKeyList,omitempty"` +} + +// NewUpdateNavigatorResponse instantiates a new UpdateNavigatorResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUpdateNavigatorResponse() *UpdateNavigatorResponse { + this := UpdateNavigatorResponse{} + return &this +} + +// NewUpdateNavigatorResponseWithDefaults instantiates a new UpdateNavigatorResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUpdateNavigatorResponseWithDefaults() *UpdateNavigatorResponse { + this := UpdateNavigatorResponse{} + return &this +} + +// GetAlertQuery returns the AlertQuery field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetAlertQuery() string { + if o == nil || IsNil(o.AlertQuery) { + var ret string + return ret + } + return *o.AlertQuery +} + +// GetAlertQueryOk returns a tuple with the AlertQuery field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetAlertQueryOk() (*string, bool) { + if o == nil || IsNil(o.AlertQuery) { + return nil, false + } + return o.AlertQuery, true +} + +// HasAlertQuery returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasAlertQuery() bool { + if o != nil && !IsNil(o.AlertQuery) { + return true + } + + return false +} + +// SetAlertQuery gets a reference to the given string and assigns it to the AlertQuery field. +func (o *UpdateNavigatorResponse) SetAlertQuery(v string) { + o.AlertQuery = &v +} + +// GetCategories returns the Categories field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetCategories() []Category { + if o == nil || IsNil(o.Categories) { + var ret []Category + return ret + } + return o.Categories +} + +// GetCategoriesOk returns a tuple with the Categories field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetCategoriesOk() ([]Category, bool) { + if o == nil || IsNil(o.Categories) { + return nil, false + } + return o.Categories, true +} + +// HasCategories returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasCategories() bool { + if o != nil && !IsNil(o.Categories) { + return true + } + + return false +} + +// SetCategories gets a reference to the given []Category and assigns it to the Categories field. +func (o *UpdateNavigatorResponse) SetCategories(v []Category) { + o.Categories = v +} + +// GetCreated returns the Created field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetCreated() int64 { + if o == nil || IsNil(o.Created) { + var ret int64 + return ret + } + return *o.Created +} + +// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetCreatedOk() (*int64, bool) { + if o == nil || IsNil(o.Created) { + return nil, false + } + return o.Created, true +} + +// HasCreated returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasCreated() bool { + if o != nil && !IsNil(o.Created) { + return true + } + + return false +} + +// SetCreated gets a reference to the given int64 and assigns it to the Created field. +func (o *UpdateNavigatorResponse) SetCreated(v int64) { + o.Created = &v +} + +// GetCreator returns the Creator field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetCreator() string { + if o == nil || IsNil(o.Creator) { + var ret string + return ret + } + return *o.Creator +} + +// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetCreatorOk() (*string, bool) { + if o == nil || IsNil(o.Creator) { + return nil, false + } + return o.Creator, true +} + +// HasCreator returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasCreator() bool { + if o != nil && !IsNil(o.Creator) { + return true + } + + return false +} + +// SetCreator gets a reference to the given string and assigns it to the Creator field. +func (o *UpdateNavigatorResponse) SetCreator(v string) { + o.Creator = &v +} + +// GetDefaultGroupBy returns the DefaultGroupBy field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetDefaultGroupBy() string { + if o == nil || IsNil(o.DefaultGroupBy) { + var ret string + return ret + } + return *o.DefaultGroupBy +} + +// GetDefaultGroupByOk returns a tuple with the DefaultGroupBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetDefaultGroupByOk() (*string, bool) { + if o == nil || IsNil(o.DefaultGroupBy) { + return nil, false + } + return o.DefaultGroupBy, true +} + +// HasDefaultGroupBy returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasDefaultGroupBy() bool { + if o != nil && !IsNil(o.DefaultGroupBy) { + return true + } + + return false +} + +// SetDefaultGroupBy gets a reference to the given string and assigns it to the DefaultGroupBy field. +func (o *UpdateNavigatorResponse) SetDefaultGroupBy(v string) { + o.DefaultGroupBy = &v +} + +// GetDisplayName returns the DisplayName field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetDisplayName() string { + if o == nil || IsNil(o.DisplayName) { + var ret string + return ret + } + return *o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.DisplayName) { + return nil, false + } + return o.DisplayName, true +} + +// HasDisplayName returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasDisplayName() bool { + if o != nil && !IsNil(o.DisplayName) { + return true + } + + return false +} + +// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. +func (o *UpdateNavigatorResponse) SetDisplayName(v string) { + o.DisplayName = &v +} + +// GetEntityMetrics returns the EntityMetrics field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetEntityMetrics() []Metric { + if o == nil || IsNil(o.EntityMetrics) { + var ret []Metric + return ret + } + return o.EntityMetrics +} + +// GetEntityMetricsOk returns a tuple with the EntityMetrics field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetEntityMetricsOk() ([]Metric, bool) { + if o == nil || IsNil(o.EntityMetrics) { + return nil, false + } + return o.EntityMetrics, true +} + +// HasEntityMetrics returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasEntityMetrics() bool { + if o != nil && !IsNil(o.EntityMetrics) { + return true + } + + return false +} + +// SetEntityMetrics gets a reference to the given []Metric and assigns it to the EntityMetrics field. +func (o *UpdateNavigatorResponse) SetEntityMetrics(v []Metric) { + o.EntityMetrics = v +} + +// GetId returns the Id field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetId() string { + if o == nil || IsNil(o.Id) { + var ret string + return ret + } + return *o.Id +} + +// GetIdOk returns a tuple with the Id field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetIdOk() (*string, bool) { + if o == nil || IsNil(o.Id) { + return nil, false + } + return o.Id, true +} + +// HasId returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasId() bool { + if o != nil && !IsNil(o.Id) { + return true + } + + return false +} + +// SetId gets a reference to the given string and assigns it to the Id field. +func (o *UpdateNavigatorResponse) SetId(v string) { + o.Id = &v +} + +// GetIdDisplayName returns the IdDisplayName field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetIdDisplayName() string { + if o == nil || IsNil(o.IdDisplayName) { + var ret string + return ret + } + return *o.IdDisplayName +} + +// GetIdDisplayNameOk returns a tuple with the IdDisplayName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetIdDisplayNameOk() (*string, bool) { + if o == nil || IsNil(o.IdDisplayName) { + return nil, false + } + return o.IdDisplayName, true +} + +// HasIdDisplayName returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasIdDisplayName() bool { + if o != nil && !IsNil(o.IdDisplayName) { + return true + } + + return false +} + +// SetIdDisplayName gets a reference to the given string and assigns it to the IdDisplayName field. +func (o *UpdateNavigatorResponse) SetIdDisplayName(v string) { + o.IdDisplayName = &v +} + +// GetInstanceDashboards returns the InstanceDashboards field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetInstanceDashboards() []string { + if o == nil || IsNil(o.InstanceDashboards) { + var ret []string + return ret + } + return o.InstanceDashboards +} + +// GetInstanceDashboardsOk returns a tuple with the InstanceDashboards field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetInstanceDashboardsOk() ([]string, bool) { + if o == nil || IsNil(o.InstanceDashboards) { + return nil, false + } + return o.InstanceDashboards, true +} + +// HasInstanceDashboards returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasInstanceDashboards() bool { + if o != nil && !IsNil(o.InstanceDashboards) { + return true + } + + return false +} + +// SetInstanceDashboards gets a reference to the given []string and assigns it to the InstanceDashboards field. +func (o *UpdateNavigatorResponse) SetInstanceDashboards(v []string) { + o.InstanceDashboards = v +} + +// GetInstanceDisplayText returns the InstanceDisplayText field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetInstanceDisplayText() string { + if o == nil || IsNil(o.InstanceDisplayText) { + var ret string + return ret + } + return *o.InstanceDisplayText +} + +// GetInstanceDisplayTextOk returns a tuple with the InstanceDisplayText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetInstanceDisplayTextOk() (*string, bool) { + if o == nil || IsNil(o.InstanceDisplayText) { + return nil, false + } + return o.InstanceDisplayText, true +} + +// HasInstanceDisplayText returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasInstanceDisplayText() bool { + if o != nil && !IsNil(o.InstanceDisplayText) { + return true + } + + return false +} + +// SetInstanceDisplayText gets a reference to the given string and assigns it to the InstanceDisplayText field. +func (o *UpdateNavigatorResponse) SetInstanceDisplayText(v string) { + o.InstanceDisplayText = &v +} + +// GetInstanceLabel returns the InstanceLabel field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetInstanceLabel() string { + if o == nil || IsNil(o.InstanceLabel) { + var ret string + return ret + } + return *o.InstanceLabel +} + +// GetInstanceLabelOk returns a tuple with the InstanceLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetInstanceLabelOk() (*string, bool) { + if o == nil || IsNil(o.InstanceLabel) { + return nil, false + } + return o.InstanceLabel, true +} + +// HasInstanceLabel returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasInstanceLabel() bool { + if o != nil && !IsNil(o.InstanceLabel) { + return true + } + + return false +} + +// SetInstanceLabel gets a reference to the given string and assigns it to the InstanceLabel field. +func (o *UpdateNavigatorResponse) SetInstanceLabel(v string) { + o.InstanceLabel = &v +} + +// GetLastUpdated returns the LastUpdated field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetLastUpdated() int64 { + if o == nil || IsNil(o.LastUpdated) { + var ret int64 + return ret + } + return *o.LastUpdated +} + +// GetLastUpdatedOk returns a tuple with the LastUpdated field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetLastUpdatedOk() (*int64, bool) { + if o == nil || IsNil(o.LastUpdated) { + return nil, false + } + return o.LastUpdated, true +} + +// HasLastUpdated returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasLastUpdated() bool { + if o != nil && !IsNil(o.LastUpdated) { + return true + } + + return false +} + +// SetLastUpdated gets a reference to the given int64 and assigns it to the LastUpdated field. +func (o *UpdateNavigatorResponse) SetLastUpdated(v int64) { + o.LastUpdated = &v +} + +// GetLastUpdatedBy returns the LastUpdatedBy field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetLastUpdatedBy() string { + if o == nil || IsNil(o.LastUpdatedBy) { + var ret string + return ret + } + return *o.LastUpdatedBy +} + +// GetLastUpdatedByOk returns a tuple with the LastUpdatedBy field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetLastUpdatedByOk() (*string, bool) { + if o == nil || IsNil(o.LastUpdatedBy) { + return nil, false + } + return o.LastUpdatedBy, true +} + +// HasLastUpdatedBy returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasLastUpdatedBy() bool { + if o != nil && !IsNil(o.LastUpdatedBy) { + return true + } + + return false +} + +// SetLastUpdatedBy gets a reference to the given string and assigns it to the LastUpdatedBy field. +func (o *UpdateNavigatorResponse) SetLastUpdatedBy(v string) { + o.LastUpdatedBy = &v +} + +// GetListColumns returns the ListColumns field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetListColumns() []ListColumn { + if o == nil || IsNil(o.ListColumns) { + var ret []ListColumn + return ret + } + return o.ListColumns +} + +// GetListColumnsOk returns a tuple with the ListColumns field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetListColumnsOk() ([]ListColumn, bool) { + if o == nil || IsNil(o.ListColumns) { + return nil, false + } + return o.ListColumns, true +} + +// HasListColumns returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasListColumns() bool { + if o != nil && !IsNil(o.ListColumns) { + return true + } + + return false +} + +// SetListColumns gets a reference to the given []ListColumn and assigns it to the ListColumns field. +func (o *UpdateNavigatorResponse) SetListColumns(v []ListColumn) { + o.ListColumns = v +} + +// GetOwnerScope returns the OwnerScope field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetOwnerScope() OwnerScope { + if o == nil || IsNil(o.OwnerScope) { + var ret OwnerScope + return ret + } + return *o.OwnerScope +} + +// GetOwnerScopeOk returns a tuple with the OwnerScope field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetOwnerScopeOk() (*OwnerScope, bool) { + if o == nil || IsNil(o.OwnerScope) { + return nil, false + } + return o.OwnerScope, true +} + +// HasOwnerScope returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasOwnerScope() bool { + if o != nil && !IsNil(o.OwnerScope) { + return true + } + + return false +} + +// SetOwnerScope gets a reference to the given OwnerScope and assigns it to the OwnerScope field. +func (o *UpdateNavigatorResponse) SetOwnerScope(v OwnerScope) { + o.OwnerScope = &v +} + +// GetPropertyIdentifierTemplate returns the PropertyIdentifierTemplate field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetPropertyIdentifierTemplate() string { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + var ret string + return ret + } + return *o.PropertyIdentifierTemplate +} + +// GetPropertyIdentifierTemplateOk returns a tuple with the PropertyIdentifierTemplate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetPropertyIdentifierTemplateOk() (*string, bool) { + if o == nil || IsNil(o.PropertyIdentifierTemplate) { + return nil, false + } + return o.PropertyIdentifierTemplate, true +} + +// HasPropertyIdentifierTemplate returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasPropertyIdentifierTemplate() bool { + if o != nil && !IsNil(o.PropertyIdentifierTemplate) { + return true + } + + return false +} + +// SetPropertyIdentifierTemplate gets a reference to the given string and assigns it to the PropertyIdentifierTemplate field. +func (o *UpdateNavigatorResponse) SetPropertyIdentifierTemplate(v string) { + o.PropertyIdentifierTemplate = &v +} + +// GetRequiredProperties returns the RequiredProperties field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetRequiredProperties() []string { + if o == nil || IsNil(o.RequiredProperties) { + var ret []string + return ret + } + return o.RequiredProperties +} + +// GetRequiredPropertiesOk returns a tuple with the RequiredProperties field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetRequiredPropertiesOk() ([]string, bool) { + if o == nil || IsNil(o.RequiredProperties) { + return nil, false + } + return o.RequiredProperties, true +} + +// HasRequiredProperties returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasRequiredProperties() bool { + if o != nil && !IsNil(o.RequiredProperties) { + return true + } + + return false +} + +// SetRequiredProperties gets a reference to the given []string and assigns it to the RequiredProperties field. +func (o *UpdateNavigatorResponse) SetRequiredProperties(v []string) { + o.RequiredProperties = v +} + +// GetSystemTypes returns the SystemTypes field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetSystemTypes() []string { + if o == nil || IsNil(o.SystemTypes) { + var ret []string + return ret + } + return o.SystemTypes +} + +// GetSystemTypesOk returns a tuple with the SystemTypes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetSystemTypesOk() ([]string, bool) { + if o == nil || IsNil(o.SystemTypes) { + return nil, false + } + return o.SystemTypes, true +} + +// HasSystemTypes returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasSystemTypes() bool { + if o != nil && !IsNil(o.SystemTypes) { + return true + } + + return false +} + +// SetSystemTypes gets a reference to the given []string and assigns it to the SystemTypes field. +func (o *UpdateNavigatorResponse) SetSystemTypes(v []string) { + o.SystemTypes = v +} + +// GetSummaryMetricLabel returns the SummaryMetricLabel field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetSummaryMetricLabel() string { + if o == nil || IsNil(o.SummaryMetricLabel) { + var ret string + return ret + } + return *o.SummaryMetricLabel +} + +// GetSummaryMetricLabelOk returns a tuple with the SummaryMetricLabel field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetSummaryMetricLabelOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricLabel) { + return nil, false + } + return o.SummaryMetricLabel, true +} + +// HasSummaryMetricLabel returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasSummaryMetricLabel() bool { + if o != nil && !IsNil(o.SummaryMetricLabel) { + return true + } + + return false +} + +// SetSummaryMetricLabel gets a reference to the given string and assigns it to the SummaryMetricLabel field. +func (o *UpdateNavigatorResponse) SetSummaryMetricLabel(v string) { + o.SummaryMetricLabel = &v +} + +// GetSummaryMetricProgramText returns the SummaryMetricProgramText field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetSummaryMetricProgramText() string { + if o == nil || IsNil(o.SummaryMetricProgramText) { + var ret string + return ret + } + return *o.SummaryMetricProgramText +} + +// GetSummaryMetricProgramTextOk returns a tuple with the SummaryMetricProgramText field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetSummaryMetricProgramTextOk() (*string, bool) { + if o == nil || IsNil(o.SummaryMetricProgramText) { + return nil, false + } + return o.SummaryMetricProgramText, true +} + +// HasSummaryMetricProgramText returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasSummaryMetricProgramText() bool { + if o != nil && !IsNil(o.SummaryMetricProgramText) { + return true + } + + return false +} + +// SetSummaryMetricProgramText gets a reference to the given string and assigns it to the SummaryMetricProgramText field. +func (o *UpdateNavigatorResponse) SetSummaryMetricProgramText(v string) { + o.SummaryMetricProgramText = &v +} + +// GetTooltipKeyList returns the TooltipKeyList field value if set, zero value otherwise. +func (o *UpdateNavigatorResponse) GetTooltipKeyList() []TooltipKey { + if o == nil || IsNil(o.TooltipKeyList) { + var ret []TooltipKey + return ret + } + return o.TooltipKeyList +} + +// GetTooltipKeyListOk returns a tuple with the TooltipKeyList field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UpdateNavigatorResponse) GetTooltipKeyListOk() ([]TooltipKey, bool) { + if o == nil || IsNil(o.TooltipKeyList) { + return nil, false + } + return o.TooltipKeyList, true +} + +// HasTooltipKeyList returns a boolean if a field has been set. +func (o *UpdateNavigatorResponse) HasTooltipKeyList() bool { + if o != nil && !IsNil(o.TooltipKeyList) { + return true + } + + return false +} + +// SetTooltipKeyList gets a reference to the given []TooltipKey and assigns it to the TooltipKeyList field. +func (o *UpdateNavigatorResponse) SetTooltipKeyList(v []TooltipKey) { + o.TooltipKeyList = v +} + +func (o UpdateNavigatorResponse) MarshalJSON() ([]byte, error) { + toSerialize,err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o UpdateNavigatorResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.AlertQuery) { + toSerialize["alertQuery"] = o.AlertQuery + } + if !IsNil(o.Categories) { + toSerialize["categories"] = o.Categories + } + if !IsNil(o.Created) { + toSerialize["created"] = o.Created + } + if !IsNil(o.Creator) { + toSerialize["creator"] = o.Creator + } + if !IsNil(o.DefaultGroupBy) { + toSerialize["defaultGroupBy"] = o.DefaultGroupBy + } + if !IsNil(o.DisplayName) { + toSerialize["displayName"] = o.DisplayName + } + if !IsNil(o.EntityMetrics) { + toSerialize["entityMetrics"] = o.EntityMetrics + } + if !IsNil(o.Id) { + toSerialize["id"] = o.Id + } + if !IsNil(o.IdDisplayName) { + toSerialize["idDisplayName"] = o.IdDisplayName + } + if !IsNil(o.InstanceDashboards) { + toSerialize["instanceDashboards"] = o.InstanceDashboards + } + if !IsNil(o.InstanceDisplayText) { + toSerialize["instanceDisplayText"] = o.InstanceDisplayText + } + if !IsNil(o.InstanceLabel) { + toSerialize["instanceLabel"] = o.InstanceLabel + } + if !IsNil(o.LastUpdated) { + toSerialize["lastUpdated"] = o.LastUpdated + } + if !IsNil(o.LastUpdatedBy) { + toSerialize["lastUpdatedBy"] = o.LastUpdatedBy + } + if !IsNil(o.ListColumns) { + toSerialize["listColumns"] = o.ListColumns + } + if !IsNil(o.OwnerScope) { + toSerialize["ownerScope"] = o.OwnerScope + } + if !IsNil(o.PropertyIdentifierTemplate) { + toSerialize["propertyIdentifierTemplate"] = o.PropertyIdentifierTemplate + } + if !IsNil(o.RequiredProperties) { + toSerialize["requiredProperties"] = o.RequiredProperties + } + if !IsNil(o.SystemTypes) { + toSerialize["systemTypes"] = o.SystemTypes + } + if !IsNil(o.SummaryMetricLabel) { + toSerialize["summaryMetricLabel"] = o.SummaryMetricLabel + } + if !IsNil(o.SummaryMetricProgramText) { + toSerialize["summaryMetricProgramText"] = o.SummaryMetricProgramText + } + if !IsNil(o.TooltipKeyList) { + toSerialize["tooltipKeyList"] = o.TooltipKeyList + } + return toSerialize, nil +} + +type NullableUpdateNavigatorResponse struct { + value *UpdateNavigatorResponse + isSet bool +} + +func (v NullableUpdateNavigatorResponse) Get() *UpdateNavigatorResponse { + return v.value +} + +func (v *NullableUpdateNavigatorResponse) Set(val *UpdateNavigatorResponse) { + v.value = val + v.isSet = true +} + +func (v NullableUpdateNavigatorResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableUpdateNavigatorResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUpdateNavigatorResponse(val *UpdateNavigatorResponse) *NullableUpdateNavigatorResponse { + return &NullableUpdateNavigatorResponse{value: val, isSet: true} +} + +func (v NullableUpdateNavigatorResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableUpdateNavigatorResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + + diff --git a/navigator/response.go b/navigator/response.go new file mode 100644 index 0000000..baf8a2b --- /dev/null +++ b/navigator/response.go @@ -0,0 +1,47 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "net/http" +) + +// APIResponse stores the API response returned by the server. +type APIResponse struct { + *http.Response `json:"-"` + Message string `json:"message,omitempty"` + // Operation is the name of the OpenAPI operation. + Operation string `json:"operation,omitempty"` + // RequestURL is the request URL. This value is always available, even if the + // embedded *http.Response is nil. + RequestURL string `json:"url,omitempty"` + // Method is the HTTP method used for the request. This value is always + // available, even if the embedded *http.Response is nil. + Method string `json:"method,omitempty"` + // Payload holds the contents of the response body (which may be nil or empty). + // This is provided here as the raw response.Body() reader will have already + // been drained. + Payload []byte `json:"-"` +} + +// NewAPIResponse returns a new APIResponse object. +func NewAPIResponse(r *http.Response) *APIResponse { + + response := &APIResponse{Response: r} + return response +} + +// NewAPIResponseWithError returns a new APIResponse object with the provided error message. +func NewAPIResponseWithError(errorMessage string) *APIResponse { + + response := &APIResponse{Message: errorMessage} + return response +} diff --git a/navigator/utils.go b/navigator/utils.go new file mode 100644 index 0000000..529900c --- /dev/null +++ b/navigator/utils.go @@ -0,0 +1,361 @@ +/* +Navigators API + +API for creating, updating, retrieving, and deleting custom navigators. ## Requirements * You must have an organization access token with the API permission or a session token to use the API. * You have to have the Splunk Observability Cloud admin role to use the `POST /navigator`, `PUT /navigator/{id}`, `DELETE /navigator/{id}`, `POST /navigator/{id}/navigatorcustomization`, `PUT /navigator/{id}/navigatorcustomization/{customizationId}`, and `DELETE /navigator/{id}/navigatorcustomization/{customizationId}` operations. * You have to have the Splunk Observability Cloud admin, power, or read_only role to use the `GET /navigator`, `GET /navigator/{id}`, `GET /navigator/{id}/dashboards`, `GET /navigator/{id}/navigatorcustomization`, and `GET /navigator/{id}/navigatorcustomization/{customizationId}` operations. + +API version: 3.0.1 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package navigator + +import ( + "bytes" + "encoding/json" + "fmt" + "reflect" + "time" +) + +// PtrBool is a helper routine that returns a pointer to given boolean value. +func PtrBool(v bool) *bool { return &v } + +// PtrInt is a helper routine that returns a pointer to given integer value. +func PtrInt(v int) *int { return &v } + +// PtrInt32 is a helper routine that returns a pointer to given integer value. +func PtrInt32(v int32) *int32 { return &v } + +// PtrInt64 is a helper routine that returns a pointer to given integer value. +func PtrInt64(v int64) *int64 { return &v } + +// PtrFloat32 is a helper routine that returns a pointer to given float value. +func PtrFloat32(v float32) *float32 { return &v } + +// PtrFloat64 is a helper routine that returns a pointer to given float value. +func PtrFloat64(v float64) *float64 { return &v } + +// PtrString is a helper routine that returns a pointer to given string value. +func PtrString(v string) *string { return &v } + +// PtrTime is helper routine that returns a pointer to given Time value. +func PtrTime(v time.Time) *time.Time { return &v } + +type NullableBool struct { + value *bool + isSet bool +} + +func (v NullableBool) Get() *bool { + return v.value +} + +func (v *NullableBool) Set(val *bool) { + v.value = val + v.isSet = true +} + +func (v NullableBool) IsSet() bool { + return v.isSet +} + +func (v *NullableBool) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBool(val *bool) *NullableBool { + return &NullableBool{value: val, isSet: true} +} + +func (v NullableBool) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBool) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt struct { + value *int + isSet bool +} + +func (v NullableInt) Get() *int { + return v.value +} + +func (v *NullableInt) Set(val *int) { + v.value = val + v.isSet = true +} + +func (v NullableInt) IsSet() bool { + return v.isSet +} + +func (v *NullableInt) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt(val *int) *NullableInt { + return &NullableInt{value: val, isSet: true} +} + +func (v NullableInt) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt32 struct { + value *int32 + isSet bool +} + +func (v NullableInt32) Get() *int32 { + return v.value +} + +func (v *NullableInt32) Set(val *int32) { + v.value = val + v.isSet = true +} + +func (v NullableInt32) IsSet() bool { + return v.isSet +} + +func (v *NullableInt32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt32(val *int32) *NullableInt32 { + return &NullableInt32{value: val, isSet: true} +} + +func (v NullableInt32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableInt64 struct { + value *int64 + isSet bool +} + +func (v NullableInt64) Get() *int64 { + return v.value +} + +func (v *NullableInt64) Set(val *int64) { + v.value = val + v.isSet = true +} + +func (v NullableInt64) IsSet() bool { + return v.isSet +} + +func (v *NullableInt64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableInt64(val *int64) *NullableInt64 { + return &NullableInt64{value: val, isSet: true} +} + +func (v NullableInt64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableInt64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableFloat32 struct { + value *float32 + isSet bool +} + +func (v NullableFloat32) Get() *float32 { + return v.value +} + +func (v *NullableFloat32) Set(val *float32) { + v.value = val + v.isSet = true +} + +func (v NullableFloat32) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat32) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat32(val *float32) *NullableFloat32 { + return &NullableFloat32{value: val, isSet: true} +} + +func (v NullableFloat32) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat32) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableFloat64 struct { + value *float64 + isSet bool +} + +func (v NullableFloat64) Get() *float64 { + return v.value +} + +func (v *NullableFloat64) Set(val *float64) { + v.value = val + v.isSet = true +} + +func (v NullableFloat64) IsSet() bool { + return v.isSet +} + +func (v *NullableFloat64) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFloat64(val *float64) *NullableFloat64 { + return &NullableFloat64{value: val, isSet: true} +} + +func (v NullableFloat64) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableFloat64) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableString struct { + value *string + isSet bool +} + +func (v NullableString) Get() *string { + return v.value +} + +func (v *NullableString) Set(val *string) { + v.value = val + v.isSet = true +} + +func (v NullableString) IsSet() bool { + return v.isSet +} + +func (v *NullableString) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableString(val *string) *NullableString { + return &NullableString{value: val, isSet: true} +} + +func (v NullableString) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableString) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +type NullableTime struct { + value *time.Time + isSet bool +} + +func (v NullableTime) Get() *time.Time { + return v.value +} + +func (v *NullableTime) Set(val *time.Time) { + v.value = val + v.isSet = true +} + +func (v NullableTime) IsSet() bool { + return v.isSet +} + +func (v *NullableTime) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTime(val *time.Time) *NullableTime { + return &NullableTime{value: val, isSet: true} +} + +func (v NullableTime) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTime) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} + +// IsNil checks if an input is nil +func IsNil(i interface{}) bool { + if i == nil { + return true + } + switch reflect.TypeOf(i).Kind() { + case reflect.Chan, reflect.Func, reflect.Map, reflect.Ptr, reflect.UnsafePointer, reflect.Interface, reflect.Slice: + return reflect.ValueOf(i).IsNil() + case reflect.Array: + return reflect.ValueOf(i).IsZero() + } + return false +} + +type MappedNullable interface { + ToMap() (map[string]interface{}, error) +} + +// A wrapper for strict JSON decoding +func newStrictDecoder(data []byte) *json.Decoder { + dec := json.NewDecoder(bytes.NewBuffer(data)) + dec.DisallowUnknownFields() + return dec +} + +// Prevent trying to import "fmt" +func reportError(format string, a ...interface{}) error { + return fmt.Errorf(format, a...) +} \ No newline at end of file