mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
839 lines
24 KiB
Go
839 lines
24 KiB
Go
/*
|
|
Hanzo Cloud API
|
|
|
|
The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
|
|
|
|
API version: v1
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package hanzoai
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the ProviderProviderView type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &ProviderProviderView{}
|
|
|
|
// ProviderProviderView struct for ProviderProviderView
|
|
type ProviderProviderView struct {
|
|
// Accounts is every account this org has connected for the provider, each with its own platform id. Tokens never appear here.
|
|
Accounts []ProviderConnectionView `json:"accounts,omitempty"`
|
|
// Actions are what the connector can be asked to do, by a flow step or an agent (POST /v1/provider/{provider}/run when Runnable).
|
|
Actions []ProviderOpView `json:"actions,omitempty"`
|
|
// App names the OAuth app registration its sign-in uses (\"GOOGLE\"), for a connector whose sign-in awaits one.
|
|
App *string `json:"app,omitempty"`
|
|
// Available is whether THIS DEPLOYMENT has the provider's app credentials, so connect can succeed. False renders the card without a working Connect button.
|
|
Available *bool `json:"available,omitempty"`
|
|
// Category groups the card (\"Communication\", \"Developer\", \"Marketing\").
|
|
Category *string `json:"category,omitempty"`
|
|
// Checks is whether a pasted credential is checked with the provider before it is stored. False means it is sealed on its shape and checked on use.
|
|
Checks *bool `json:"checks,omitempty"`
|
|
// Connected is whether this org has a live connection to the provider.
|
|
Connected *bool `json:"connected,omitempty"`
|
|
// Connection is the connected account's non-secret detail. Absent when the org has no connection; tokens NEVER appear here (they live only in KMS). When the org holds several accounts, this is the first and Accounts is every one of them.
|
|
Connection *ProviderConnectionView `json:"connection,omitempty"`
|
|
// Description is the one-line pitch the console card shows.
|
|
Description *string `json:"description,omitempty"`
|
|
// Fields is the form a credential connector asks for. Absent otherwise.
|
|
Fields []ProviderField `json:"fields,omitempty"`
|
|
// ID is the provider's registry id and the :provider path segment (\"slack\").
|
|
Id *string `json:"id,omitempty"`
|
|
// Kind is how a reader connects it NOW: \"oauth\" (send the browser to the provider), \"credential\" (fill in Fields), \"device\" (enter a code), or \"none\" (nothing to connect — ready, or not connectable here; Note says).
|
|
Kind *string `json:"kind,omitempty"`
|
|
// Logo is where the connector's logo is served. Absent when it has none.
|
|
Logo *string `json:"logo,omitempty"`
|
|
// Modes are the ways this provider can be connected, derived from what it actually declares — \"managed\", \"oauth\", \"apikey\", \"device\", \"mcp\". One console page renders every card from this field rather than carrying a table of its own, which is how a provider added here shows up there without a second edit.
|
|
Modes []string `json:"modes,omitempty"`
|
|
// Name is the provider's display name (\"Slack\").
|
|
Name *string `json:"name,omitempty"`
|
|
// Note says why the connector cannot be connected here, when it cannot.
|
|
Note *string `json:"note,omitempty"`
|
|
// Runnable is whether its actions run on this deployment.
|
|
Runnable *bool `json:"runnable,omitempty"`
|
|
// Scopes are the permissions a connection will ask for. Never null.
|
|
Scopes []string `json:"scopes,omitempty"`
|
|
// Triggers are the events a flow can start on.
|
|
Triggers []ProviderOpView `json:"triggers,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _ProviderProviderView ProviderProviderView
|
|
|
|
// NewProviderProviderView instantiates a new ProviderProviderView 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 NewProviderProviderView() *ProviderProviderView {
|
|
this := ProviderProviderView{}
|
|
return &this
|
|
}
|
|
|
|
// NewProviderProviderViewWithDefaults instantiates a new ProviderProviderView 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 NewProviderProviderViewWithDefaults() *ProviderProviderView {
|
|
this := ProviderProviderView{}
|
|
return &this
|
|
}
|
|
|
|
// GetAccounts returns the Accounts field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetAccounts() []ProviderConnectionView {
|
|
if o == nil || IsNil(o.Accounts) {
|
|
var ret []ProviderConnectionView
|
|
return ret
|
|
}
|
|
return o.Accounts
|
|
}
|
|
|
|
// GetAccountsOk returns a tuple with the Accounts field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetAccountsOk() ([]ProviderConnectionView, bool) {
|
|
if o == nil || IsNil(o.Accounts) {
|
|
return nil, false
|
|
}
|
|
return o.Accounts, true
|
|
}
|
|
|
|
// HasAccounts returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasAccounts() bool {
|
|
if o != nil && !IsNil(o.Accounts) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAccounts gets a reference to the given []ProviderConnectionView and assigns it to the Accounts field.
|
|
func (o *ProviderProviderView) SetAccounts(v []ProviderConnectionView) {
|
|
o.Accounts = v
|
|
}
|
|
|
|
// GetActions returns the Actions field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetActions() []ProviderOpView {
|
|
if o == nil || IsNil(o.Actions) {
|
|
var ret []ProviderOpView
|
|
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 *ProviderProviderView) GetActionsOk() ([]ProviderOpView, 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 *ProviderProviderView) HasActions() bool {
|
|
if o != nil && !IsNil(o.Actions) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetActions gets a reference to the given []ProviderOpView and assigns it to the Actions field.
|
|
func (o *ProviderProviderView) SetActions(v []ProviderOpView) {
|
|
o.Actions = v
|
|
}
|
|
|
|
// GetApp returns the App field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetApp() string {
|
|
if o == nil || IsNil(o.App) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.App
|
|
}
|
|
|
|
// GetAppOk returns a tuple with the App field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetAppOk() (*string, bool) {
|
|
if o == nil || IsNil(o.App) {
|
|
return nil, false
|
|
}
|
|
return o.App, true
|
|
}
|
|
|
|
// HasApp returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasApp() bool {
|
|
if o != nil && !IsNil(o.App) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetApp gets a reference to the given string and assigns it to the App field.
|
|
func (o *ProviderProviderView) SetApp(v string) {
|
|
o.App = &v
|
|
}
|
|
|
|
// GetAvailable returns the Available field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetAvailable() bool {
|
|
if o == nil || IsNil(o.Available) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.Available
|
|
}
|
|
|
|
// GetAvailableOk returns a tuple with the Available field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetAvailableOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.Available) {
|
|
return nil, false
|
|
}
|
|
return o.Available, true
|
|
}
|
|
|
|
// HasAvailable returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasAvailable() bool {
|
|
if o != nil && !IsNil(o.Available) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAvailable gets a reference to the given bool and assigns it to the Available field.
|
|
func (o *ProviderProviderView) SetAvailable(v bool) {
|
|
o.Available = &v
|
|
}
|
|
|
|
// GetCategory returns the Category field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetCategory() string {
|
|
if o == nil || IsNil(o.Category) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Category
|
|
}
|
|
|
|
// GetCategoryOk returns a tuple with the Category field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetCategoryOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Category) {
|
|
return nil, false
|
|
}
|
|
return o.Category, true
|
|
}
|
|
|
|
// HasCategory returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasCategory() bool {
|
|
if o != nil && !IsNil(o.Category) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCategory gets a reference to the given string and assigns it to the Category field.
|
|
func (o *ProviderProviderView) SetCategory(v string) {
|
|
o.Category = &v
|
|
}
|
|
|
|
// GetChecks returns the Checks field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetChecks() bool {
|
|
if o == nil || IsNil(o.Checks) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.Checks
|
|
}
|
|
|
|
// GetChecksOk returns a tuple with the Checks field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetChecksOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.Checks) {
|
|
return nil, false
|
|
}
|
|
return o.Checks, true
|
|
}
|
|
|
|
// HasChecks returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasChecks() bool {
|
|
if o != nil && !IsNil(o.Checks) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetChecks gets a reference to the given bool and assigns it to the Checks field.
|
|
func (o *ProviderProviderView) SetChecks(v bool) {
|
|
o.Checks = &v
|
|
}
|
|
|
|
// GetConnected returns the Connected field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetConnected() bool {
|
|
if o == nil || IsNil(o.Connected) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.Connected
|
|
}
|
|
|
|
// GetConnectedOk returns a tuple with the Connected field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetConnectedOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.Connected) {
|
|
return nil, false
|
|
}
|
|
return o.Connected, true
|
|
}
|
|
|
|
// HasConnected returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasConnected() bool {
|
|
if o != nil && !IsNil(o.Connected) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetConnected gets a reference to the given bool and assigns it to the Connected field.
|
|
func (o *ProviderProviderView) SetConnected(v bool) {
|
|
o.Connected = &v
|
|
}
|
|
|
|
// GetConnection returns the Connection field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetConnection() ProviderConnectionView {
|
|
if o == nil || IsNil(o.Connection) {
|
|
var ret ProviderConnectionView
|
|
return ret
|
|
}
|
|
return *o.Connection
|
|
}
|
|
|
|
// GetConnectionOk returns a tuple with the Connection field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetConnectionOk() (*ProviderConnectionView, bool) {
|
|
if o == nil || IsNil(o.Connection) {
|
|
return nil, false
|
|
}
|
|
return o.Connection, true
|
|
}
|
|
|
|
// HasConnection returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasConnection() bool {
|
|
if o != nil && !IsNil(o.Connection) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetConnection gets a reference to the given ProviderConnectionView and assigns it to the Connection field.
|
|
func (o *ProviderProviderView) SetConnection(v ProviderConnectionView) {
|
|
o.Connection = &v
|
|
}
|
|
|
|
// GetDescription returns the Description field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) SetDescription(v string) {
|
|
o.Description = &v
|
|
}
|
|
|
|
// GetFields returns the Fields field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetFields() []ProviderField {
|
|
if o == nil || IsNil(o.Fields) {
|
|
var ret []ProviderField
|
|
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 *ProviderProviderView) GetFieldsOk() ([]ProviderField, 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 *ProviderProviderView) HasFields() bool {
|
|
if o != nil && !IsNil(o.Fields) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetFields gets a reference to the given []ProviderField and assigns it to the Fields field.
|
|
func (o *ProviderProviderView) SetFields(v []ProviderField) {
|
|
o.Fields = v
|
|
}
|
|
|
|
// GetId returns the Id field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) SetId(v string) {
|
|
o.Id = &v
|
|
}
|
|
|
|
// GetKind returns the Kind field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetKind() string {
|
|
if o == nil || IsNil(o.Kind) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Kind
|
|
}
|
|
|
|
// GetKindOk returns a tuple with the Kind field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetKindOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Kind) {
|
|
return nil, false
|
|
}
|
|
return o.Kind, true
|
|
}
|
|
|
|
// HasKind returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasKind() bool {
|
|
if o != nil && !IsNil(o.Kind) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetKind gets a reference to the given string and assigns it to the Kind field.
|
|
func (o *ProviderProviderView) SetKind(v string) {
|
|
o.Kind = &v
|
|
}
|
|
|
|
// GetLogo returns the Logo field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetLogo() string {
|
|
if o == nil || IsNil(o.Logo) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Logo
|
|
}
|
|
|
|
// GetLogoOk returns a tuple with the Logo field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetLogoOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Logo) {
|
|
return nil, false
|
|
}
|
|
return o.Logo, true
|
|
}
|
|
|
|
// HasLogo returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasLogo() bool {
|
|
if o != nil && !IsNil(o.Logo) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetLogo gets a reference to the given string and assigns it to the Logo field.
|
|
func (o *ProviderProviderView) SetLogo(v string) {
|
|
o.Logo = &v
|
|
}
|
|
|
|
// GetModes returns the Modes field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetModes() []string {
|
|
if o == nil || IsNil(o.Modes) {
|
|
var ret []string
|
|
return ret
|
|
}
|
|
return o.Modes
|
|
}
|
|
|
|
// GetModesOk returns a tuple with the Modes field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetModesOk() ([]string, bool) {
|
|
if o == nil || IsNil(o.Modes) {
|
|
return nil, false
|
|
}
|
|
return o.Modes, true
|
|
}
|
|
|
|
// HasModes returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasModes() bool {
|
|
if o != nil && !IsNil(o.Modes) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetModes gets a reference to the given []string and assigns it to the Modes field.
|
|
func (o *ProviderProviderView) SetModes(v []string) {
|
|
o.Modes = v
|
|
}
|
|
|
|
// GetName returns the Name field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) 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 *ProviderProviderView) SetName(v string) {
|
|
o.Name = &v
|
|
}
|
|
|
|
// GetNote returns the Note field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetNote() string {
|
|
if o == nil || IsNil(o.Note) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Note
|
|
}
|
|
|
|
// GetNoteOk returns a tuple with the Note field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetNoteOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Note) {
|
|
return nil, false
|
|
}
|
|
return o.Note, true
|
|
}
|
|
|
|
// HasNote returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasNote() bool {
|
|
if o != nil && !IsNil(o.Note) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetNote gets a reference to the given string and assigns it to the Note field.
|
|
func (o *ProviderProviderView) SetNote(v string) {
|
|
o.Note = &v
|
|
}
|
|
|
|
// GetRunnable returns the Runnable field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetRunnable() bool {
|
|
if o == nil || IsNil(o.Runnable) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.Runnable
|
|
}
|
|
|
|
// GetRunnableOk returns a tuple with the Runnable field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetRunnableOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.Runnable) {
|
|
return nil, false
|
|
}
|
|
return o.Runnable, true
|
|
}
|
|
|
|
// HasRunnable returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasRunnable() bool {
|
|
if o != nil && !IsNil(o.Runnable) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetRunnable gets a reference to the given bool and assigns it to the Runnable field.
|
|
func (o *ProviderProviderView) SetRunnable(v bool) {
|
|
o.Runnable = &v
|
|
}
|
|
|
|
// GetScopes returns the Scopes field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetScopes() []string {
|
|
if o == nil || IsNil(o.Scopes) {
|
|
var ret []string
|
|
return ret
|
|
}
|
|
return o.Scopes
|
|
}
|
|
|
|
// GetScopesOk returns a tuple with the Scopes field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetScopesOk() ([]string, bool) {
|
|
if o == nil || IsNil(o.Scopes) {
|
|
return nil, false
|
|
}
|
|
return o.Scopes, true
|
|
}
|
|
|
|
// HasScopes returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasScopes() bool {
|
|
if o != nil && !IsNil(o.Scopes) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetScopes gets a reference to the given []string and assigns it to the Scopes field.
|
|
func (o *ProviderProviderView) SetScopes(v []string) {
|
|
o.Scopes = v
|
|
}
|
|
|
|
// GetTriggers returns the Triggers field value if set, zero value otherwise.
|
|
func (o *ProviderProviderView) GetTriggers() []ProviderOpView {
|
|
if o == nil || IsNil(o.Triggers) {
|
|
var ret []ProviderOpView
|
|
return ret
|
|
}
|
|
return o.Triggers
|
|
}
|
|
|
|
// GetTriggersOk returns a tuple with the Triggers field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProviderProviderView) GetTriggersOk() ([]ProviderOpView, bool) {
|
|
if o == nil || IsNil(o.Triggers) {
|
|
return nil, false
|
|
}
|
|
return o.Triggers, true
|
|
}
|
|
|
|
// HasTriggers returns a boolean if a field has been set.
|
|
func (o *ProviderProviderView) HasTriggers() bool {
|
|
if o != nil && !IsNil(o.Triggers) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTriggers gets a reference to the given []ProviderOpView and assigns it to the Triggers field.
|
|
func (o *ProviderProviderView) SetTriggers(v []ProviderOpView) {
|
|
o.Triggers = v
|
|
}
|
|
|
|
func (o ProviderProviderView) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o ProviderProviderView) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.Accounts) {
|
|
toSerialize["accounts"] = o.Accounts
|
|
}
|
|
if !IsNil(o.Actions) {
|
|
toSerialize["actions"] = o.Actions
|
|
}
|
|
if !IsNil(o.App) {
|
|
toSerialize["app"] = o.App
|
|
}
|
|
if !IsNil(o.Available) {
|
|
toSerialize["available"] = o.Available
|
|
}
|
|
if !IsNil(o.Category) {
|
|
toSerialize["category"] = o.Category
|
|
}
|
|
if !IsNil(o.Checks) {
|
|
toSerialize["checks"] = o.Checks
|
|
}
|
|
if !IsNil(o.Connected) {
|
|
toSerialize["connected"] = o.Connected
|
|
}
|
|
if !IsNil(o.Connection) {
|
|
toSerialize["connection"] = o.Connection
|
|
}
|
|
if !IsNil(o.Description) {
|
|
toSerialize["description"] = o.Description
|
|
}
|
|
if !IsNil(o.Fields) {
|
|
toSerialize["fields"] = o.Fields
|
|
}
|
|
if !IsNil(o.Id) {
|
|
toSerialize["id"] = o.Id
|
|
}
|
|
if !IsNil(o.Kind) {
|
|
toSerialize["kind"] = o.Kind
|
|
}
|
|
if !IsNil(o.Logo) {
|
|
toSerialize["logo"] = o.Logo
|
|
}
|
|
if !IsNil(o.Modes) {
|
|
toSerialize["modes"] = o.Modes
|
|
}
|
|
if !IsNil(o.Name) {
|
|
toSerialize["name"] = o.Name
|
|
}
|
|
if !IsNil(o.Note) {
|
|
toSerialize["note"] = o.Note
|
|
}
|
|
if !IsNil(o.Runnable) {
|
|
toSerialize["runnable"] = o.Runnable
|
|
}
|
|
if !IsNil(o.Scopes) {
|
|
toSerialize["scopes"] = o.Scopes
|
|
}
|
|
if !IsNil(o.Triggers) {
|
|
toSerialize["triggers"] = o.Triggers
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *ProviderProviderView) UnmarshalJSON(data []byte) (err error) {
|
|
varProviderProviderView := _ProviderProviderView{}
|
|
|
|
err = json.Unmarshal(data, &varProviderProviderView)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = ProviderProviderView(varProviderProviderView)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "accounts")
|
|
delete(additionalProperties, "actions")
|
|
delete(additionalProperties, "app")
|
|
delete(additionalProperties, "available")
|
|
delete(additionalProperties, "category")
|
|
delete(additionalProperties, "checks")
|
|
delete(additionalProperties, "connected")
|
|
delete(additionalProperties, "connection")
|
|
delete(additionalProperties, "description")
|
|
delete(additionalProperties, "fields")
|
|
delete(additionalProperties, "id")
|
|
delete(additionalProperties, "kind")
|
|
delete(additionalProperties, "logo")
|
|
delete(additionalProperties, "modes")
|
|
delete(additionalProperties, "name")
|
|
delete(additionalProperties, "note")
|
|
delete(additionalProperties, "runnable")
|
|
delete(additionalProperties, "scopes")
|
|
delete(additionalProperties, "triggers")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableProviderProviderView struct {
|
|
value *ProviderProviderView
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableProviderProviderView) Get() *ProviderProviderView {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableProviderProviderView) Set(val *ProviderProviderView) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableProviderProviderView) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableProviderProviderView) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableProviderProviderView(val *ProviderProviderView) *NullableProviderProviderView {
|
|
return &NullableProviderProviderView{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableProviderProviderView) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableProviderProviderView) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|